From 04fa60f1026051d7ba22893932b2686ff3363a2e Mon Sep 17 00:00:00 2001 From: Eric Wagoner Date: Thu, 29 Dec 2022 17:06:31 -0500 Subject: [PATCH] initialize db --- scripts/install | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/install b/scripts/install index 4be76a6..6947c7d 100755 --- a/scripts/install +++ b/scripts/install @@ -131,6 +131,15 @@ mkdir "$final_path/venv" python3 -m venv "$final_path/venv" $final_path/venv/bin/pip3 install -r "$final_path/requirements.txt" +#================================================= +# INITIALIZE DATABASE +#================================================= +ynh_script_progression --message="Initializing database..." --weight=1 + +$final_path/venv/bin/python3 "$final_path/manage.py" migrate +$final_path/venv/bin/python3 "$final_path/manage.py" initdb +$final_path/venv/bin/python3 "$final_path/manage.py" collectstatic --no-input + #================================================= # NGINX CONFIGURATION #=================================================