1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/framaforms_ynh.git synced 2024-09-03 18:36:12 +02:00

Remove all RemoveMe

Brute force, need to clean and check it…
This commit is contained in:
lapineige 2023-08-13 11:08:31 +02:00 committed by GitHub
parent f7d407f872
commit e27d4428e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 160 additions and 160 deletions

View file

@ -4,9 +4,9 @@
# COMMON VARIABLES # COMMON VARIABLES
#================================================= #=================================================
#REMOVEME? YNH_PHP_VERSION="7.3"
#REMOVEME? pkg_dependencies="postgresql curl libzip-dev php${YNH_PHP_VERSION}-fpm php${YNH_PHP_VERSION}-cli php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-ldap php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-pgsql"
YNH_COMPOSER_VERSION="1.10.17" YNH_COMPOSER_VERSION="1.10.17"

View file

@ -15,20 +15,20 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
#REMOVEME? ynh_abort_if_errors
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
#REMOVEME? ynh_print_info --message="Loading installation settings..."
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir)
#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain)
#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name)
#REMOVEME? phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#REMOVEME? data_dir=$(ynh_app_setting_get --app=$app --key=data_dir)
#================================================= #=================================================
# DECLARE DATA AND CONF FILES TO BACKUP # DECLARE DATA AND CONF FILES TO BACKUP

View file

@ -13,55 +13,55 @@ source /usr/share/yunohost/helpers
# RETRIEVE ARGUMENTS # RETRIEVE ARGUMENTS
#================================================= #=================================================
#REMOVEME? old_domain=$YNH_APP_OLD_DOMAIN
#REMOVEME? old_path=$YNH_APP_OLD_PATH
#REMOVEME? new_domain=$YNH_APP_NEW_DOMAIN
#REMOVEME? new_path=$YNH_APP_NEW_PATH
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Loading installation settings..." --weight=1
#REMOVEME? # Needed for helper "ynh_add_nginx_config"
#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir)
# Add settings here as needed by your application # Add settings here as needed by your application
#================================================= #=================================================
# BACKUP BEFORE CHANGE URL THEN ACTIVE TRAP # BACKUP BEFORE CHANGE URL THEN ACTIVE TRAP
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..."
# Backup the current version of the app # Backup the current version of the app
#REMOVEME? ynh_backup_before_upgrade
#REMOVEME? ynh_clean_setup () {
# Remove the new domain config file, the remove script won't do it as it doesn't know yet its location. # Remove the new domain config file, the remove script won't do it as it doesn't know yet its location.
#REMOVEME? ynh_secure_remove --file="/etc/nginx/conf.d/$new_domain.d/$app.conf"
# Restore it if the upgrade fails # Restore it if the upgrade fails
#REMOVEME? ynh_restore_upgradebackup
} }
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
#REMOVEME? ynh_abort_if_errors
#================================================= #=================================================
# CHECK WHICH PARTS SHOULD BE CHANGED # CHECK WHICH PARTS SHOULD BE CHANGED
#================================================= #=================================================
#REMOVEME? change_domain=0
#REMOVEME? if [ "$old_domain" != "$new_domain" ]
then then
#REMOVEME? change_domain=1
fi fi
#REMOVEME? change_path=0
#REMOVEME? if [ "$old_path" != "$new_path" ]
then then
#REMOVEME? change_path=1
fi fi
#================================================= #=================================================
@ -73,28 +73,28 @@ ynh_script_progression --message="Updating NGINX web server configuration..." --
ynh_change_url_nginx_config ynh_change_url_nginx_config
#REMOVEME? nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf
# Change the path in the NGINX config file # Change the path in the NGINX config file
if [ $change_path -eq 1 ] if [ $change_path -eq 1 ]
then then
# Make a backup of the original NGINX config file if modified # Make a backup of the original NGINX config file if modified
#REMOVEME? ynh_backup_if_checksum_is_different --file="$nginx_conf_path"
# Set global variables for NGINX helper # Set global variables for NGINX helper
#REMOVEME? domain="$old_domain"
#REMOVEME? path="$new_path"
# Create a dedicated NGINX config # Create a dedicated NGINX config
#REMOVEME? ynh_add_nginx_config
fi fi
# Change the domain for NGINX # Change the domain for NGINX
if [ $change_domain -eq 1 ] if [ $change_domain -eq 1 ]
then then
# Delete file checksum for the old conf file location # Delete file checksum for the old conf file location
#REMOVEME? ynh_delete_file_checksum --file="$nginx_conf_path"
#REMOVEME? mv $nginx_conf_path /etc/nginx/conf.d/$new_domain.d/$app.conf
# Store file checksum for the new config file location # Store file checksum for the new config file location
#REMOVEME? ynh_store_file_checksum --file="/etc/nginx/conf.d/$new_domain.d/$app.conf"
fi fi
#================================================= #=================================================
@ -103,7 +103,7 @@ fi
# UPDATE DRUSH ALIAS # UPDATE DRUSH ALIAS
#================================================= #=================================================
ynh_script_progression --message="Updating Drush alias..." --weight=1 ynh_script_progression --message="Updating Drush alias..." --weight=1
#REMOVEME?
domain="$new_domain" domain="$new_domain"
path="$new_path" path="$new_path"
@ -114,9 +114,9 @@ ynh_add_config --template="../conf/yoursite.aliases.drushrc.php" --destination="
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." --weight=1
#REMOVEME? #REMOVEME? ynh_systemd_action --service_name=nginx --action=reload
#================================================= #=================================================
# END OF SCRIPT # END OF SCRIPT

View file

@ -14,46 +14,46 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
#REMOVEME? ynh_abort_if_errors
#================================================= #=================================================
# RETRIEVE ARGUMENTS FROM THE MANIFEST # RETRIEVE ARGUMENTS FROM THE MANIFEST
#================================================= #=================================================
#REMOVEME? domain=$YNH_APP_ARG_DOMAIN
#REMOVEME? path=$YNH_APP_ARG_PATH
#REMOVEME? is_public=$YNH_APP_ARG_IS_PUBLIC
#REMOVEME? language=$YNH_APP_ARG_LANGUAGE
#REMOVEME? admin=$YNH_APP_ARG_ADMIN
#REMOVEME? password=$YNH_APP_ARG_PASSWORD
#REMOVEME? expiration=$YNH_APP_ARG_EXPIRATION
#REMOVEME? deletion=$YNH_APP_ARG_DELETION
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
admin_mail=$(ynh_user_get_info --username=$admin --key=mail) admin_mail=$(ynh_user_get_info --username=$admin --key=mail)
#================================================= #=================================================
# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS # CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Validating installation parameters..." --weight=1
#REMOVEME? install_dir=/var/www/$app
#REMOVEME? test ! -e "$install_dir" || ynh_die --message="This path already contains a folder"
# Register (book) web path # Register (book) web path
#REMOVEME? ynh_webpath_register --app=$app --domain=$domain --path=$path
#================================================= #=================================================
# STORE SETTINGS FROM MANIFEST # STORE SETTINGS FROM MANIFEST
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Storing installation settings..." --weight=1
#REMOVEME? ynh_app_setting_set --app=$app --key=domain --value=$domain
#REMOVEME? ynh_app_setting_set --app=$app --key=path --value=$path
ynh_app_setting_set --app=$app --key=language --value=$language ynh_app_setting_set --app=$app --key=language --value=$language
#REMOVEME? ynh_app_setting_set --app=$app --key=admin --value=$admin
#REMOVEME? ynh_app_setting_set --app=$app --key=password --value=$password
ynh_app_setting_set --app=$app --key=expiration --value=$expiration ynh_app_setting_set --app=$app --key=expiration --value=$expiration
ynh_app_setting_set --app=$app --key=deletion --value=$deletion ynh_app_setting_set --app=$app --key=deletion --value=$deletion
@ -62,36 +62,36 @@ ynh_app_setting_set --app=$app --key=deletion --value=$deletion
#================================================= #=================================================
# INSTALL DEPENDENCIES # INSTALL DEPENDENCIES
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Installing dependencies..." --weight=7
#REMOVEME? ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
#================================================= #=================================================
# CREATE DEDICATED USER # CREATE DEDICATED USER
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Configuring system user..." --weight=3
# Create a system user # Create a system user
#REMOVEME? ynh_system_user_create --username=$app --home_dir=$install_dir
#================================================= #=================================================
# CREATE A POSTGRESQL DATABASE # CREATE A POSTGRESQL DATABASE
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Creating a PostgreSQL database..." --weight=2
#REMOVEME? ynh_psql_test_if_first_run
#REMOVEME? db_name=$(ynh_sanitize_dbid --db_name=$app)
#REMOVEME? db_user=$db_name
#REMOVEME? ynh_app_setting_set --app=$app --key=db_name --value=$db_name
#REMOVEME? ynh_psql_setup_db --db_user=$db_user --db_name=$db_name
#================================================= #=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE # DOWNLOAD, CHECK AND UNPACK SOURCE
#================================================= #=================================================
ynh_script_progression --message="Setting up source files..." --weight=9 ynh_script_progression --message="Setting up source files..." --weight=9
#REMOVEME? ynh_app_setting_set --app=$app --key=install_dir --value=$install_dir
# Download, check integrity, uncompress and patch the source from app.src # Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$install_dir/app" ynh_setup_source --dest_dir="$install_dir/app"
@ -106,7 +106,7 @@ ynh_script_progression --message="Configuring PHP-FPM..." --weight=1
# Create a dedicated PHP-FPM config # Create a dedicated PHP-FPM config
ynh_add_fpm_config --usage=low --footprint=low ynh_add_fpm_config --usage=low --footprint=low
#REMOVEME? phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#================================================= #=================================================
# NGINX CONFIGURATION # NGINX CONFIGURATION
@ -162,8 +162,8 @@ chmod 2775 "$install_dir/app/sites/default/files"
#================================================= #=================================================
ynh_script_progression --message="Creating a data directory..." ynh_script_progression --message="Creating a data directory..."
#REMOVEME? data_dir=/home/yunohost.app/$app
#REMOVEME? ynh_app_setting_set --app=$app --key=data_dir --value=$data_dir
mkdir -p $data_dir mkdir -p $data_dir
@ -250,25 +250,25 @@ ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/$app"
#================================================= #=================================================
# SETUP SSOWAT # SETUP SSOWAT
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Configuring permissions..." --weight=1
# Make app public if necessary # Make app public if necessary
#REMOVEME? if [ $is_public -eq 1 ]
then then
# Everyone can access the app. # Everyone can access the app.
# The "main" permission is automatically created before the install script. # The "main" permission is automatically created before the install script.
#REMOVEME? ynh_permission_update --permission="main" --add="visitors"
fi fi
# Only the admin can access the admin panel of the app (if the app has an admin panel) # Only the admin can access the admin panel of the app (if the app has an admin panel)
#REMOVEME? ynh_permission_create --permission="admin" --url="/admin" --allowed=$admin
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." --weight=1
#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload
#================================================= #=================================================
# END OF SCRIPT # END OF SCRIPT

View file

@ -12,33 +12,33 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Loading installation settings..." --weight=1
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain)
#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name)
#REMOVEME? db_user=$db_name
#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir)
#REMOVEME? data_dir=$(ynh_app_setting_get --app=$app --key=data_dir)
#================================================= #=================================================
# STANDARD REMOVE # STANDARD REMOVE
#================================================= #=================================================
# REMOVE THE POSTGRESQL DATABASE # REMOVE THE POSTGRESQL DATABASE
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Removing the PostgreSQL database..." --weight=1
# Remove a database if it exists, along with the associated user # Remove a database if it exists, along with the associated user
#REMOVEME? ynh_psql_remove_db --db_user=$db_user --db_name=$db_name
#================================================= #=================================================
# REMOVE APP MAIN DIR # REMOVE APP MAIN DIR
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Removing app main directory..." --weight=1
# Remove the app directory securely # Remove the app directory securely
#REMOVEME? ynh_secure_remove --file="$install_dir"
#================================================= #=================================================
# REMOVE DATA DIR # REMOVE DATA DIR
@ -48,7 +48,7 @@ source /usr/share/yunohost/helpers
if [ "${YNH_APP_PURGE:-0}" -eq 1 ] if [ "${YNH_APP_PURGE:-0}" -eq 1 ]
then then
ynh_script_progression --message="Removing app data directory..." ynh_script_progression --message="Removing app data directory..."
#REMOVEME? ynh_secure_remove --file="$data_dir"
fi fi
#================================================= #=================================================
@ -70,10 +70,10 @@ ynh_remove_fpm_config
#================================================= #=================================================
# REMOVE DEPENDENCIES # REMOVE DEPENDENCIES
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Removing dependencies..." --weight=7
# Remove metapackage and its dependencies # Remove metapackage and its dependencies
#REMOVEME? ynh_remove_app_dependencies
#================================================= #=================================================
# SPECIFIC REMOVE # SPECIFIC REMOVE
@ -90,10 +90,10 @@ ynh_secure_remove --file="/etc/cron.d/$app"
#================================================= #=================================================
# REMOVE DEDICATED USER # REMOVE DEDICATED USER
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Removing the dedicated system user..." --weight=1
# Delete a system user # Delete a system user
#REMOVEME? ynh_system_user_delete --username=$app
#================================================= #=================================================
# END OF SCRIPT # END OF SCRIPT

View file

@ -15,29 +15,29 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
#REMOVEME? ynh_abort_if_errors
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Loading installation settings..." --weight=1
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain)
#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path)
#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir)
#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name)
#REMOVEME? db_user=$db_name
#REMOVEME? phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#REMOVEME? data_dir=$(ynh_app_setting_get --app=$app --key=data_dir)
#================================================= #=================================================
# CHECK IF THE APP CAN BE RESTORED # CHECK IF THE APP CAN BE RESTORED
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Validating restoration parameters..." --weight=1
#REMOVEME? test ! -d $install_dir \
|| ynh_die --message="There is already a directory: $install_dir " || ynh_die --message="There is already a directory: $install_dir "
#================================================= #=================================================
@ -45,10 +45,10 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# RECREATE THE DEDICATED USER # RECREATE THE DEDICATED USER
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Recreating the dedicated system user..." --weight=1
# Create the dedicated user (if not existing) # Create the dedicated user (if not existing)
#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir"
#================================================= #=================================================
# RESTORE THE APP MAIN DIR # RESTORE THE APP MAIN DIR
@ -81,10 +81,10 @@ chown -R $app:www-data "$data_dir"
#================================================= #=================================================
# REINSTALL DEPENDENCIES # REINSTALL DEPENDENCIES
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Reinstalling dependencies..." --weight=1
# Define and install dependencies # Define and install dependencies
#REMOVEME? ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
#================================================= #=================================================
# RESTORE THE PHP-FPM CONFIGURATION # RESTORE THE PHP-FPM CONFIGURATION
@ -96,7 +96,7 @@ ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
# Recreate a dedicated php-fpm config # Recreate a dedicated php-fpm config
ynh_add_fpm_config --usage=low --footprint=low ynh_add_fpm_config --usage=low --footprint=low
#REMOVEME? phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#================================================= #=================================================
# RESTORE THE NGINX CONFIGURATION # RESTORE THE NGINX CONFIGURATION
@ -108,11 +108,11 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
#================================================= #=================================================
# RESTORE THE POSTGRESQL DATABASE # RESTORE THE POSTGRESQL DATABASE
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Restoring the PostgreSQL database..." --weight=2
#REMOVEME? ynh_psql_test_if_first_run
#REMOVEME? db_pwd=$(ynh_app_setting_get --app=$app --key=psqlpwd)
#REMOVEME? ynh_psql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd
ynh_psql_execute_file_as_root --database=$db_name --file="./db.sql" ynh_psql_execute_file_as_root --database=$db_name --file="./db.sql"
#================================================= #=================================================

View file

@ -12,17 +12,17 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Loading installation settings..." --weight=2
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain)
#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path)
#REMOVEME? admin=$(ynh_app_setting_get --app=$app --key=admin)
#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir)
#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name)
#REMOVEME? phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#REMOVEME? data_dir=$(ynh_app_setting_get --app=$app --key=data_dir)
#================================================= #=================================================
# CHECK VERSION # CHECK VERSION
@ -34,16 +34,16 @@ upgrade_type=$(ynh_check_app_version_changed)
#================================================= #=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP # BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." --weight=21
# Backup the current version of the app # Backup the current version of the app
#REMOVEME? ynh_backup_before_upgrade
#REMOVEME? ynh_clean_setup () {
# Restore it if the upgrade fails # Restore it if the upgrade fails
#REMOVEME? ynh_restore_upgradebackup
} }
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
#REMOVEME? ynh_abort_if_errors
#================================================= #=================================================
# STANDARD UPGRADE STEPS # STANDARD UPGRADE STEPS
@ -53,50 +53,50 @@ upgrade_type=$(ynh_check_app_version_changed)
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
# Cleaning legacy permissions # Cleaning legacy permissions
#REMOVEME? if ynh_legacy_permissions_exists; then
#REMOVEME? ynh_legacy_permissions_delete_all
ynh_app_setting_delete --app=$app --key=is_public ynh_app_setting_delete --app=$app --key=is_public
fi fi
#REMOVEME? if ! ynh_permission_exists --permission="admin"; then
# Create the required permissions # Create the required permissions
#REMOVEME? ynh_permission_create --permission="admin" --url="/admin" --allowed=$admin
fi fi
# If db_name doesn't exist, create it # If db_name doesn't exist, create it
if [ -z "$db_name" ]; then if [ -z "$db_name" ]; then
db_name=$(ynh_sanitize_dbid --db_name=$app) db_name=$(ynh_sanitize_dbid --db_name=$app)
#REMOVEME? ynh_app_setting_set --app=$app --key=db_name --value=$db_name
fi fi
# If install_dir doesn't exist, create it # If install_dir doesn't exist, create it
if [ -z "$install_dir" ]; then if [ -z "$install_dir" ]; then
#REMOVEME? install_dir=/var/www/$app
#REMOVEME? ynh_app_setting_set --app=$app --key=install_dir --value=$install_dir
fi fi
# If data_dir doesn't exist, create it # If data_dir doesn't exist, create it
if [ -z "$data_dir" ]; then if [ -z "$data_dir" ]; then
data_dir=/home/yunohost.app/$app data_dir=/home/yunohost.app/$app
#REMOVEME? ynh_app_setting_set --app=$app --key=data_dir --value=$data_dir
fi fi
#================================================= #=================================================
# CREATE DEDICATED USER # CREATE DEDICATED USER
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Making sure dedicated system user exists..." --weight=1
# Create a dedicated user (if not existing) # Create a dedicated user (if not existing)
#REMOVEME? ynh_system_user_create --username=$app --home_dir=$install_dir
#================================================= #=================================================
# UPGRADE DEPENDENCIES # UPGRADE DEPENDENCIES
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Upgrading dependencies..." --weight=5
#REMOVEME? ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
#================================================= #=================================================
# PHP-FPM CONFIGURATION # PHP-FPM CONFIGURATION
@ -130,7 +130,7 @@ chown -R $app:www-data "$data_dir"
# Framaforms 2 Yakforms Backup # Framaforms 2 Yakforms Backup
#================================================= #=================================================
upgrade_to_yakforms=false upgrade_to_yakforms=false
#REMOVEME? if test -d "$install_dir/app/CHANGELOG-FRAMAFORMS.md"
then then
update-alternatives --set php /usr/bin/php$phpversion update-alternatives --set php /usr/bin/php$phpversion
upgrade_to_yakforms=true upgrade_to_yakforms=true
@ -228,9 +228,9 @@ chown $app:$app "$install_dir/app/sites/default/settings.php"
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." --weight=1
#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload
#================================================= #=================================================
# END OF SCRIPT # END OF SCRIPT