Working Dockerfile and Compose.yml, makefile docker cmd

This commit is contained in:
DarkCat09 2023-02-17 15:55:52 +04:00
parent 13f10ab255
commit bd4c0987c2
3 changed files with 7 additions and 2 deletions

View file

@ -1,5 +1,7 @@
FROM python:3-alpine
RUN apk update && apk upgrade && apk add python3-pip
RUN apk update && apk upgrade && apk add py-pip make
WORKDIR /app
COPY . .
RUN pip install -r requirements.txt
CMD make prod
EXPOSE 8000

View file

@ -11,6 +11,9 @@ check:
python3 -m mypy flaskapp/
python3 -m pylint flaskapp/
docker:
docker build -t ${REPO_OWNER}/${REPO_OWNER_SNAKE} .
clean:
rm -rf flaskapp/__pycache__
rm -rf __pycache__

View file

@ -2,7 +2,7 @@ version: "3"
services:
${REPO_NAME_SNAKE}:
image: ${REPO_NAME_SNAKE}:latest
image: ${REPO_OWNER}/${REPO_NAME_SNAKE}:latest
container_name: ${REPO_NAME_SNAKE}
restart: unless-stopped
ports: