Skip to content

Commit

Permalink
Merge pull request #113 from gerosecurity/development
Browse files Browse the repository at this point in the history
Migrate Database on Initialization
  • Loading branch information
VGR6479 authored Nov 20, 2024
2 parents ad0a077 + 75f882c commit 3c2b39e
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions gerobug_web/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,23 @@

sleep 60

echo "[LOG] Making migrations ..."
while ! python manage.py makemigrations dashboards 2>&1; do
echo "[LOG] Made migrations"
sleep 3
done

echo "[LOG] Migrate the Database ..."
while ! python manage.py migrate 2>&1; do
echo "[LOG] Migration is in progress status 0"
sleep 3
done

while ! python manage.py migrate dashboards 2>&1; do
echo "[LOG] Migration is in progress status 1"
sleep 3
done

echo "[LOG] GEROBUG-WEB is fully configured successfully."

exec "$@"

0 comments on commit 3c2b39e

Please sign in to comment.