-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #187 from bounswe/docker
Apply changes in docker to fixed backend code
- Loading branch information
Showing
5 changed files
with
50 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
FROM python:3.6 | ||
|
||
ADD requirements.txt . | ||
RUN pip install --upgrade pip | ||
RUN pip install -r requirements.txt | ||
|
||
ADD . / | ||
WORKDIR / | ||
|
||
CMD python manage.py makemigrations authentication eventposts | ||
CMD python manage.py migrate authentication eventposts | ||
CMD gunicorn --bind 0.0.0.0:9000 -w 1 app.wsgi | ||
|
||
EXPOSE 9000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
django | ||
gunicorn | ||
psycopg2 | ||
djangorestframework | ||
djangorestframework-jsonapi | ||
djangorestframework_simplejwt | ||
django_rest_passwordreset |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
POSTGRES_USER=rebound_user | ||
POSTGRES_PASSWORD=-#My6o0dPa33W0rd#- | ||
POSTGRES_DB=rebound_db |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
version: "3" | ||
services: | ||
backend: | ||
build: backend | ||
ports: | ||
- "9000:9000" | ||
environment: | ||
WAIT_HOSTS: database:5432 | ||
DEBUG: 'False' | ||
env_file: | ||
- database.env | ||
database: | ||
image: "postgres:latest" | ||
env_file: | ||
- database.env | ||
ports: | ||
- "5432:5432" | ||
volumes: | ||
- database-data:/var/lib/postgresql/data/ | ||
|
||
volumes: | ||
database-data: |