diff --git a/scripts/install b/scripts/install index 0b3eb88..51ef5a4 100755 --- a/scripts/install +++ b/scripts/install @@ -10,7 +10,7 @@ ynh_script_progression "Setting up source files..." ynh_setup_source --dest_dir="$install_dir/app" -chmod -R 750 "$install_dir" +chmod -R "u=rX,g=rX,o=" "$install_dir" chown -R "$app:www-data" "$install_dir" #================================================= @@ -21,8 +21,8 @@ ynh_script_progression "Adding $app's configuration..." mkdir -p "$install_dir/app/data/_data_/_default_/configs" ynh_config_add --template="application.ini" --destination="$install_dir/app/data/_data_/_default_/configs/application.ini" -chown -R $app:$app "$install_dir/app/data" -chmod -R 600 "$install_dir/app/data" +chmod -R "u=rwX,g=,o=" "$install_dir/app/data" +chown -R "$app:$app" "$install_dir/app/data" #================================================= # SETUP SSO @@ -30,8 +30,8 @@ chmod -R 600 "$install_dir/app/data" ynh_script_progression "Applying SSO patch..." ynh_config_add --template="sso.php" --destination="$install_dir/index.php" +chmod "u=rX,g=,o=" "$install_dir/index.php" chown "$app:www-data" "$install_dir/index.php" -chmod 750 "$install_dir/index.php" #================================================= # SYSTEM CONFIGURATION diff --git a/scripts/restore b/scripts/restore index cbecfbd..de26cae 100755 --- a/scripts/restore +++ b/scripts/restore @@ -11,10 +11,13 @@ ynh_script_progression "Restoring the app main directory..." ynh_restore "$install_dir" -chmod -R 750 "$install_dir" +chmod -R "u=rX,g=rX,o=" "$install_dir" chown -R "$app:www-data" "$install_dir" -chmod 600 "$install_dir/app/data/_data_/_default_/configs/application.ini" -chown -R "$app:$app" "$install_dir/app/data/_data_" + +chmod -R "u=rwX,g=,o=" "$install_dir/app/data" +chown -R "$app:$app" "$install_dir/app/data" + +chmod "u=rX,g=,o=" "$install_dir/index.php" #================================================= # RESTORE SYSTEM CONFIGURATIONS diff --git a/scripts/upgrade b/scripts/upgrade index b585cbd..cd1624b 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -24,7 +24,7 @@ ynh_script_progression "Upgrading source files..." ynh_setup_source --dest_dir="$install_dir/app" --full_replace=1 --keep="data/_data_/_default_/configs/application.ini" -chmod -R 750 "$install_dir" +chmod -R "u=rX,g=rX,o=" "$install_dir" chown -R "$app:www-data" "$install_dir" #================================================= @@ -34,7 +34,7 @@ chown -R "$app:www-data" "$install_dir" #ynh_config_add --template="application.ini" --destination="$install_dir/app/data/_data_/_default_/configs/application.ini" -chmod -R 600 "$install_dir/app/data" +chmod -R "u=rwX,g=,o=" "$install_dir/app/data" chown -R "$app:$app" "$install_dir/app/data" #================================================= @@ -43,8 +43,8 @@ chown -R "$app:$app" "$install_dir/app/data" ynh_script_progression "Applying SSO patch..." ynh_config_add --template="sso.php" --destination="$install_dir/index.php" +chmod "u=rX,g=,o=" "$install_dir/index.php" chown "$app:www-data" "$install_dir/index.php" -chmod 750 "$install_dir/index.php" #================================================= # REAPPLY SYSTEM CONFIGURATIONS