diff --git a/scripts/install b/scripts/install index 0bc7f6b..e135183 100755 --- a/scripts/install +++ b/scripts/install @@ -157,7 +157,7 @@ chown -R $app: $final_path # Set the app as temporarily public for curl call ynh_script_progression --message="Configuring SSOwat..." --weight=42 -ynh_app_setting_set --app=$app --key=skipped_uris --value="/" +ynh_permission_update --permission main --remove all_users --add visitors # Reload SSOwat config yunohost app ssowatconf @@ -176,7 +176,7 @@ ynh_local_curl "/?PagePrincipale&installAction=install" "config[default_language # Remove the public access if [ $is_public -eq 0 ] then - ynh_app_setting_delete --app=$app --key=skipped_uris + ynh_permission_update --permission main --remove visitors --add all_users fi #================================================= @@ -185,7 +185,7 @@ fi # SECURE FILES AND DIRECTORIES #================================================= -# Set permissions to app files +# Set permissions to app files chown -R root: $final_path chown -R $app $final_path/{cache,files,themes,tools,wakka.config.php} @@ -195,11 +195,11 @@ chown -R $app $final_path/{cache,files,themes,tools,wakka.config.php} ynh_script_progression --message="Configuring SSOwat..." --weight=47 # Make app public if necessary -if [ $is_public -eq 1 ] -then +#if [ $is_public -eq 1 ] +#then - ynh_app_setting_set --app=$app --key=unprotected_uris --value="/" -fi +# ynh_permission_update --permission main --add visitors +#fi #================================================= # RELOAD NGINX diff --git a/scripts/upgrade b/scripts/upgrade index 2bfa8e4..b7ffecf 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -121,22 +121,6 @@ ynh_script_progression --message="Upgrading php-fpm configuration..." --weight=2 # Create a dedicated php-fpm config ynh_add_fpm_config -#================================================= -# SPECIFIC UPGRADE -#================================================= -# ... -#================================================= - -#================================================= -# STORE THE CONFIG FILE CHECKSUM -#================================================= - -### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. -### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it. -#####ynh_backup_if_checksum_is_different --file="$final_path/CONFIG_FILE" -# Recalculate and store the checksum of the file for the next upgrade. -#####ynh_store_file_checksum --file="$final_path/CONFIG_FILE" - #================================================= # GENERIC FINALIZATION #================================================= @@ -145,6 +129,7 @@ ynh_add_fpm_config # Set permissions on app files chown -R root: $final_path +chown -R $app $final_path/{cache,files,themes,tools,wakka.config.php} #================================================= # SETUP SSOWAT @@ -152,11 +137,11 @@ chown -R root: $final_path ynh_script_progression --message="Upgrading SSOwat configuration..." --weight=29 # Make app public if necessary -if [ $is_public -eq 1 ] -then +#if [ $is_public -eq 1 ] +#then # unprotected_uris allows SSO credentials to be passed anyway - ynh_app_setting_set --app=$app --key=unprotected_uris --value="/" -fi + #ynh_permission_update --permission main --remove all_users --add visitors +#fi #================================================= # RELOAD NGINX