10884-dockerify #6

Merged
mravi merged 14 commits from 10884-dockerify into master 2022-09-19 08:27:32 +00:00
2 changed files with 33 additions and 0 deletions
Showing only changes of commit c5bfc46e33 - Show all commits

7
Dockerfile Normal file
View file

@ -0,0 +1,7 @@
FROM python:3
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1
WORKDIR /code
COPY requirements.txt /code/
RUN pip install -r requirements.txt
COPY . /code/

26
docker-compose.yml Normal file
View file

@ -0,0 +1,26 @@
version: "3.9"
services:
db:
image: postgres
volumes:
- ./data/db:/var/lib/postgresql/data
environment:
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
web:
build: .
command: python manage.py runserver 0.0.0.0:8000
volumes:
- .:/code
ports:
- "8000:8000"
environment:
- POSTGRES_NAME=app
- POSTGRES_USER=app
- POSTGRES_PASSWORD=
depends_on:
- db