Skip to content

Commit

Permalink
issue #183 Dockerize
Browse files Browse the repository at this point in the history
  • Loading branch information
amschaal committed May 3, 2022
1 parent c4fa285 commit c143c9d
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM python:3.9

RUN apt-get update \
&& apt-get install -y --no-install-recommends \
postgresql \
postgresql-client \
&& rm -rf /var/lib/apt/lists/*



WORKDIR /usr/src/app
COPY requirements.txt ./
RUN pip install -r requirements.txt
COPY . .

#EXPOSE 8000
#CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"]
18 changes: 18 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: "3.9"
services:
web:
build: .
ports:
- "8000:8000"
command: python manage.py runserver 0.0.0.0:8000
volumes:
- .:/usr/src/app
db:
image: postgres:13
volumes:
- postgres_data:/var/lib/postgresql/data/
environment:
- "POSTGRES_HOST_AUTH_METHOD=trust"

volumes:
postgres_data:

0 comments on commit c143c9d

Please sign in to comment.