diff --git a/scripts/_common.sh b/scripts/_common.sh index 2bccbe6..1f9ef1e 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # dependencies used by the app -pkg_dependencies="postgresql postgresql-contrib python3-venv libpq-dev" +pkg_dependencies="postgresql postgresql-contrib python3-venv libpq-dev docker-compose" #================================================= # PERSONAL HELPERS diff --git a/scripts/upgrade b/scripts/upgrade index 9fb54e3..ab13e68 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -107,9 +107,12 @@ $final_path/venv/bin/pip3 install -r "$final_path/requirements.txt" #================================================= ynh_script_progression --message="Upgrading database..." --weight=1 -$final_path/venv/bin/python3 "$final_path/manage.py" migrate -$final_path/venv/bin/python3 "$final_path/manage.py" collectstatic --no-input -$final_path/venv/bin/python3 "$final_path/manage.py" populate_streams +pushd "$final_path" + docker-compose build + $final_path/venv/bin/python3 "$final_path/manage.py" migrate + $final_path/venv/bin/python3 "$final_path/manage.py" collectstatic --no-input + $final_path/venv/bin/python3 "$final_path/manage.py" populate_streams +popd #================================================= # SET PERMISSIONS ON BOOKWYRM DIRECTORY