mirror of
https://github.com/YunoHost-Apps/pytition_ynh.git
synced 2024-09-03 20:16:08 +02:00
Move the uwsgi config file to the final_path instead of /etc
This commit is contained in:
parent
8b458e9102
commit
6cc0d6361f
5 changed files with 5 additions and 18 deletions
|
@ -9,7 +9,7 @@ User=__APP__
|
|||
Group=__APP__
|
||||
WorkingDirectory=__FINALPATH__
|
||||
RuntimeDirectory=__APP__
|
||||
ExecStart=uwsgi --yaml /etc/uwsgi/apps-available/__APP__.yaml --die-on-term
|
||||
ExecStart=uwsgi --yaml __FINALPATH__/uwsgi.yaml --die-on-term
|
||||
|
||||
StandardOutput=append:/var/log/__APP__/__APP__.log
|
||||
StandardError=inherit
|
||||
|
|
|
@ -72,12 +72,6 @@ ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
|||
|
||||
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
||||
|
||||
#=================================================
|
||||
# BACKUP VARIOUS FILES
|
||||
#=================================================
|
||||
|
||||
ynh_backup --src_path="/etc/uwsgi/apps-available/$app.yaml"
|
||||
|
||||
#=================================================
|
||||
# BACKUP THE MYSQL DATABASE
|
||||
#=================================================
|
||||
|
|
|
@ -113,7 +113,7 @@ fi
|
|||
ynh_script_progression --message="Updating app's configuration..." --time --weight=1
|
||||
|
||||
ynh_add_config --template="../conf/config.py" --destination="$final_path/pytition/pytition/pytition/settings/config.py"
|
||||
ynh_add_config --template="../conf/uwsgi.yaml" --destination="/etc/uwsgi/apps-available/$app.yaml"
|
||||
ynh_add_config --template="../conf/uwsgi.yaml" --destination="$final_path/uwsgi.yaml"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALISATION
|
||||
|
|
|
@ -164,9 +164,9 @@ ynh_add_config --template="../conf/config.py" --destination="$config_path"
|
|||
chmod 400 "$config_path"
|
||||
chown $app:$app "$config_path"
|
||||
|
||||
ynh_add_config --template="../conf/uwsgi.yaml" --destination="/etc/uwsgi/apps-available/$app.yaml"
|
||||
chmod 400 "/etc/uwsgi/apps-available/$app.yaml"
|
||||
chown $app:$app "/etc/uwsgi/apps-available/$app.yaml"
|
||||
ynh_add_config --template="../conf/uwsgi.yaml" --destination="$final_path/uwsgi.yaml"
|
||||
chmod 400 "$final_path/uwsgi.yaml"
|
||||
chown $app:$app "$final_path/uwsgi.yaml"
|
||||
|
||||
#=================================================
|
||||
# Run app configuration
|
||||
|
|
|
@ -97,13 +97,6 @@ db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd)
|
|||
ynh_mysql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd
|
||||
ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql
|
||||
|
||||
#=================================================
|
||||
# RESTORE VARIOUS FILES
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring various files..." --time --weight=1
|
||||
|
||||
ynh_restore_file --origin_path="/etc/uwsgi/apps-available/$app.yaml"
|
||||
|
||||
#=================================================
|
||||
# RESTORE SYSTEMD
|
||||
#=================================================
|
||||
|
|
Loading…
Reference in a new issue