]> git.ipfire.org Git - thirdparty/patchwork.git/commit
docker: Further refine logic to apply migrations
authorStephen Finucane <stephen@that.guru>
Fri, 25 Mar 2022 11:57:33 +0000 (11:57 +0000)
committerStephen Finucane <stephen@that.guru>
Fri, 25 Mar 2022 11:59:13 +0000 (11:59 +0000)
commit7186d2a6fe9d5cf976a7cf9029b465153d6ae126
treedf0262687cf92765524a6ed91a1198c7ed6183f1
parentc3d5733c232894c601ca3e0ad883e26b35447e80
docker: Further refine logic to apply migrations

We don't want to apply migrations by default since this will cause WIP
migrations to be applied if someone runs e.g. 'docker-compose run'. What
we really want to check is "are there any migrations currently applied?"
and skip if so, but Django doesn't provide an easy way to do this, so we
instead check for a random Django application.

Signed-off-by: Stephen Finucane <stephen@that.guru>
tools/docker/entrypoint.sh