mirror of
https://github.com/status-im/cabot.git
synced 2025-02-24 02:18:08 +00:00
Add comment for wait_for_migrations hack
This commit is contained in:
parent
f59d02926a
commit
86b41dcfd1
@ -22,6 +22,8 @@ function wait_for_database {(
|
||||
function wait_for_migrations {(
|
||||
set +e
|
||||
for try in {1..60} ; do
|
||||
# Kind of ugly but not sure if there's another way to determine if migrations haven't run
|
||||
# migrate --list returns a checkbox list of migrations, empty checkboxes mean they haven't been run
|
||||
python manage.py migrate --list | grep "\[ \]" &> /dev/null || break
|
||||
echo "Waiting for database migrations to be run..."
|
||||
sleep 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user