diff options
| author | arnoldyahad <arnoldyahad@gmail.com> | 2023-07-11 12:31:28 +0300 |
|---|---|---|
| committer | arnoldyahad <arnoldyahad@gmail.com> | 2023-07-11 12:31:28 +0300 |
| commit | 145ea7f2bd37e84f53660b4eb3b14ffd4d16806c (patch) | |
| tree | 2e558a98d66ea78ff35ead4ca9ef5ae470e1e1f3 | |
| parent | ca545cd6610808c81dc8c4663f445512ea894f7b (diff) | |
Docker directory for specific clouds
| -rw-r--r-- | docker/README.md | 12 | ||||
| -rw-r--r-- | docker/aws.Dockerfile | 28 |
2 files changed, 40 insertions, 0 deletions
diff --git a/docker/README.md b/docker/README.md new file mode 100644 index 0000000..a1bf1da --- /dev/null +++ b/docker/README.md @@ -0,0 +1,12 @@ +# Dockerfiles for specific clouds + +This directory will include Dockerfiles for various cloud providers. + +## AWS + +For the usage of `krr` container we need the Dockerfile to have `awscli` installed on it. +The `aws.Dockerfile` is a modified `krr` dockerfile which includes: + - installation of curl & zip + - installation of awscli + + diff --git a/docker/aws.Dockerfile b/docker/aws.Dockerfile new file mode 100644 index 0000000..13d79b8 --- /dev/null +++ b/docker/aws.Dockerfile @@ -0,0 +1,28 @@ +# Use the official Python 3.9 slim image as the base image +FROM python:3.9-slim as builder + +# Set the working directory +WORKDIR /app + +# Install system dependencies required for Poetry +RUN apt-get update && \ + dpkg --add-architecture arm64 + +COPY ./requirements.txt requirements.txt + +# Install the project dependencies +RUN pip install -r requirements.txt + +# Install curl and unzip for awscli +RUN apt-get -y update; apt-get -y install curl; apt-get -y install unzip + +# Download awscli and unzip it +RUN curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" && \ + unzip awscliv2.zip && \ + ./aws/install + +# Copy the rest of the application code +COPY . . + +# Run the application using 'poetry run krr simple' +ENTRYPOINT ["python", "krr.py", "simple"] |
