Skip to content

Commit

Permalink
Migrate default database in migrate_logger.sh
Browse files Browse the repository at this point in the history
Migrating the logger database before migrating the default database
can lead to errors. So even though we drop the database and recreate
with empty tables later, still run the migrate command for the default
DB before we migrate the logger DB.
  • Loading branch information
michaeljcollinsuk committed May 18, 2022
1 parent 5db5651 commit a4684c2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions deployscripts/migrate_logger.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
set -xeE

source /var/www/wcivf/env/bin/activate
# "default" database has to be migrated first to avoid errors migrating logger
python /var/www/wcivf/code/manage.py migrate --noinput
python /var/www/wcivf/code/manage.py migrate --database=logger --noinput

0 comments on commit a4684c2

Please sign in to comment.