Update Django entrypoint to include collectstatic command
This commit is contained in:
@@ -8,7 +8,7 @@ services:
|
|||||||
# Development: run Django's autoreloading development server instead of
|
# Development: run Django's autoreloading development server instead of
|
||||||
# the production entrypoint/gunicorn. Mount the repository into the
|
# the production entrypoint/gunicorn. Mount the repository into the
|
||||||
# container so code edits on the host trigger Django's autoreload.
|
# container so code edits on the host trigger Django's autoreload.
|
||||||
entrypoint: ["python", "manage.py", "runserver", "0.0.0.0:8000", "--nothreading"]
|
entrypoint: ["sh", "-c", "python manage.py collectstatic --noinput && python manage.py runserver 0.0.0.0:8000 --nothreading"]
|
||||||
# Clear any command set by the prod compose file (which would be passed
|
# Clear any command set by the prod compose file (which would be passed
|
||||||
# as an extra argument to manage.py). Setting an empty command prevents
|
# as an extra argument to manage.py). Setting an empty command prevents
|
||||||
# the image `command` from being appended to the entrypoint.
|
# the image `command` from being appended to the entrypoint.
|
||||||
|
|||||||
Reference in New Issue
Block a user