Skip to content

Change the way docker setup work

Created by: RemiDesgrange

  • bump the version of some dep to work with python 3.8
  • use some standard to run entrypoint and rename entrypoint to convention.
  • add a CMD in the dockerfile ("override-able" by the docker-compose). Generally speaking, we try be as declarative as possible in a Dockerfile and follow KISS.
  • GIT_BRANCH arg seems not used.

In a normal setup, collectstatic should happened at build time (but migration should stay at startup time).

As you can see the setup is quite complex. It could be simpler if you have a config project (not config_sample) and everything in the settings.py is override-able by env var (https://12factor.net/fr/) Django-environ could you do that, it could reduce the size of the shell script and the dramatically reduce the size of the Dockerfile. A practical example: django-cookiecutter

Merge request reports

Loading