From 80a3d9c89de72434fe3f9be0ba81b3fe7ee7d3f1 Mon Sep 17 00:00:00 2001 From: "Vladimir (vapronva)" Date: Fri, 30 Sep 2022 02:23:18 +0300 Subject: [PATCH] =?UTF-8?q?add:=20`dockerignore`;=20change:=20df=20layers?= =?UTF-8?q?=20handling=20(=F0=9F=A4=93)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .dockerignore | 5 +++++ Dockerfile | 9 +++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..41e2c30 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,5 @@ +.git +.gitignore +config.ini +README.md +TODO diff --git a/Dockerfile b/Dockerfile index a4e68e4..922ba6c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,11 @@ FROM python:3.10-alpine -COPY . /app + WORKDIR /app -RUN pip install -r /app/requirements.txt + +COPY requirements.txt /app/requirements.txt + +RUN pip install -r /app/requirements.txt && rm /app/requirements.txt + +COPY . /app CMD ["python3", "-m", "mastoposter", "/config.ini"]