1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/taskboard_ynh.git synced 2024-09-03 20:26:27 +02:00
This commit is contained in:
ericgaspar 2020-12-17 23:05:41 +01:00
parent 09855d39d1
commit f71b51d51c
No known key found for this signature in database
GPG key ID: 574F281483054D44
4 changed files with 33 additions and 9 deletions

View file

@ -85,7 +85,7 @@ ynh_script_progression --message="Configuring PHP-FPM..." --weight=3
# Create a dedicated PHP-FPM config
ynh_add_fpm_config --package="$extra_php_dependencies"
phpversion=$(ynh_app_setting_get --app="$app" --key=phpversion)
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
# GENERIC FINALIZATION
@ -95,7 +95,14 @@ phpversion=$(ynh_app_setting_get --app="$app" --key=phpversion)
# Set permissions to app files
chown -R $app: $final_path
chmod -R 777 $final_path/api
chmod -R 755 $final_path/api
#=================================================
# INTEGRATE SERVICE IN YUNOHOST
#=================================================
ynh_script_progression --message="Integrating service in YunoHost..." --time --weight=1
yunohost service add $app --description "A short description of the app" --log "/var/log/$app/$app.log"
#=================================================
# SETUP SSOWAT

View file

@ -22,12 +22,15 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
#=================================================
# STANDARD REMOVE
#=================================================
# STOP AND REMOVE SERVICE
# REMOVE SERVICE INTEGRATION IN YUNOHOST
#=================================================
ynh_script_progression --message="Stopping and removing the systemd service" --weight=1
# Remove the dedicated systemd config
ynh_remove_systemd_config
# Remove the service from the list of services known by Yunohost (added from `yunohost service add`)
if ynh_exec_warn_less yunohost service status $app >/dev/null
then
ynh_script_progression --message="Removing $app service integration..." --time --weight=1
yunohost service remove $app
fi
#=================================================
# REMOVE APP MAIN DIR

View file

@ -66,7 +66,7 @@ ynh_system_user_create --username=$app
# Restore permissions on app files
chown -R $app: $final_path
chmod -R 777 $final_path/api
chmod -R 755 $final_path/api
#=================================================
# REINSTALL DEPENDENCIES
@ -86,6 +86,13 @@ ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
# Recreate a dedicated PHP-FPM config
ynh_add_fpm_config --package="$extra_php_dependencies"
#=================================================
# INTEGRATE SERVICE IN YUNOHOST
#=================================================
ynh_script_progression --message="Integrating service in YunoHost..." --time --weight=1
yunohost service add $app --description "A short description of the app" --log "/var/log/$app/$app.log"
#=================================================
# GENERIC FINALIZATION
#=================================================

View file

@ -20,7 +20,7 @@ domain=$(ynh_app_setting_get --app=$app --key=domain)
path_url=$(ynh_app_setting_get --app=$app --key=path)
is_public=$(ynh_app_setting_get --app=$app --key=is_public)
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
phpversion=$(ynh_app_setting_get --app="$app" --key=phpversion)
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
# CHECK VERSION
@ -111,7 +111,14 @@ ynh_add_fpm_config --package="$extra_php_dependencies"
# Set permissions to app files
chown -R $app: $final_path
chmod -R 777 $final_path/api
chmod -R 755 $final_path/api
#=================================================
# INTEGRATE SERVICE IN YUNOHOST
#=================================================
ynh_script_progression --message="Integrating service in YunoHost..." --time --weight=1
yunohost service add $app --description "A short description of the app" --log "/var/log/$app/$app.log"
#=================================================
# RELOAD NGINX