-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[story/EDROP-14] #15
base: develop
Are you sure you want to change the base?
[story/EDROP-14] #15
Conversation
…ner initialization
docker-compose.yml
Outdated
@@ -2,7 +2,7 @@ version: "3.9" | |||
|
|||
services: | |||
db: | |||
image: postgres | |||
image: postgres:14 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
while we should have a postgres version here, let's use the latest (16 I believe)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's create a separate docker compose file for production and leave this the way it was
Dockerfile-prod
Outdated
|
||
COPY edrop-gunicorn.sh /edrop/edrop-gunicorn.sh | ||
|
||
RUN ["chmod", "+x", "/edrop/edrop-gunicorn.sh"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we want supervisor to manage gunicorn, so this should not be necessary. instead just make sure supervisor is running.
Dockerfile-prod
Outdated
|
||
RUN ["chmod", "+x", "/edrop/edrop-gunicorn.sh"] | ||
|
||
ENTRYPOINT ["./edrop-gunicorn.sh"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
neither should this
edrop-gunicorn.sh
Outdated
python -m pip install -r requirements.txt | ||
python manage.py migrate | ||
python manage.py collectstatic --noinput | ||
service supervisor start |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should not be needed here (and would actually lead to an infinite loop of starting supervisor (or error out maybe), since this is the script that supervisor runs to start gunicorn.
edrop-gunicorn.sh
Outdated
--workers $NUM_WORKERS \ | ||
--bind=0.0.0.0:8000 \ | ||
--log-level=info \ | ||
--log-file=- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
needs to log to files not stdout
…lementation, added log file to gunicorn exec, created second docker compose file, updated README, etc...
implemented supervisor and gunicorn in docker container initialization
Guidelines for Pull Requests
If you haven't yet read our code review guidelines, please do so, You can find them here.
Please confirm the following by adding an x for each item (turn
[ ]
into[x]
).Please provide a brief description of your ticket
Add supervisor and gunicorn to docker setup
GitHub Issue Link
Are there any other pull requests that this one depends on?
Anything else the reviewer needs to know?