From 83dcebe850b07be9ee822794c4467c96d5c74d70 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Holcroft Date: Thu, 14 Sep 2017 15:41:27 +0200 Subject: [PATCH] corrected service name and added debug echo --- scripts/install | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/scripts/install b/scripts/install index 39a47de..a81e4f8 100755 --- a/scripts/install +++ b/scripts/install @@ -140,18 +140,17 @@ systemctl enable $app.uwsgi.service systemctl restart $app.uwsgi.service # Add weblate.uwsgi as a service -yunohost service add $app.service +yunohost service add $app.uwsgi.service #================================================= # SPECIFIC SETUP settings.py # https://docs.weblate.org/en/latest/admin/install.html#installation #================================================= - +echo "SPECIFIC SETUP settings.py" db_pwd=$(ynh_app_setting_get $app mysqlpwd) admin_mail="$(ynh_user_get_info $admin mail)" key=$(ynh_string_random 64) -cp $final_path/weblate/settings_example.py $final_path/weblate/settings.py cp ../conf/settings.py $final_path/weblate/settings.py ynh_replace_string "__NAME__" "$app" $final_path/weblate/settings.py @@ -166,16 +165,16 @@ ynh_replace_string "__KEY__" "$key" $final_path/weblate/settings.py # SPECIFIC SETUP Filling up the database # https://docs.weblate.org/en/latest/admin/install.html#filling-up-the-database #========================================== - +echo "SPECIFIC SETUP Filling up the database" # set up database -$final_path/manage.py migrate --noinput +source ${final_path}/venv/bin/activate && $final_path/manage.py migrate --noinput # generate static files -$final_path/manage.py collectstatic --noinput +source ${final_path}/venv/bin/activate && $final_path/manage.py collectstatic --noinput #================================================= # SETUP CRON #================================================= - +echo "SETUP CRON" cp ../conf/cron_weblate /etc/cron.d/$app ynh_replace_string "__FINALPATH__" "$final_path/" /etc/cron.d/$app @@ -202,7 +201,6 @@ chown -R root: $final_path # Use logrotate to manage application logfile(s) ynh_use_logrotate - #================================================= # SETUP SSOWAT #=================================================