Commit feca6657 authored by BERJON Matthieu's avatar BERJON Matthieu
Browse files

Update for deployement compliance

In order to perform the deployement I updated few things. All python
commands are replaced with python3 to force the use of them.
I updated as well the SQL migration path to ensure that it will be run
wherever the script is executed.

Signed-off-by: BERJON Matthieu's avatarMatthieu Berjon <>
parent 8281538a
......@@ -9,6 +9,7 @@ DJANGO_TABLES="dj_docker_os dj_webapps dj_webapp_parameters dj_webapp_versions \
auth_group_permissions auth_permission auth_user auth_user_groups \
auth_user_user_permissions django_admin_log django_content_type \
django_migrations django_session"
CUR_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
ParseArgs () {
......@@ -54,12 +55,12 @@ LoadDb () {
rm -rf poc/migrations
# Apply the migration
mysql -u $USER $PASS -h $HOST $DB< tools/migration2django.sql
mysql -u $USER $PASS -h $HOST $DB< $CUR_DIR/migration2django.sql
# Tell Django to use the current status of the database and start the migrations
# from that point
python makemigrations auth poc
python migrate --fake
python3 makemigrations auth poc
python3 migrate --fake
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment