From 7fa622ccabaad6af758b0d210d32c941cc2a2c72 Mon Sep 17 00:00:00 2001 From: rungeard Date: Wed, 12 May 2021 18:18:27 +0200 Subject: [PATCH] Modifier index.php en index.html --- conf/nginx.conf | 5 ++--- scripts/install | 15 ++++++--------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 676fefb..df583e2 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -10,7 +10,7 @@ location __PATH__/ { } ### Example PHP configuration (remove it if not used) - index index.php; + index index.html; # Common parameter to increase upload size limit in conjunction with dedicated php-fpm file #client_max_body_size 50M; @@ -19,8 +19,7 @@ location __PATH__/ { location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock; - - fastcgi_index index.php; + fastcgi_index index.html; include fastcgi_params; fastcgi_param REMOTE_USER $remote_user; fastcgi_param PATH_INFO $fastcgi_path_info; diff --git a/scripts/install b/scripts/install index 5e67fbc..bd4cd43 100755 --- a/scripts/install +++ b/scripts/install @@ -119,7 +119,12 @@ ynh_setup_source --dest_dir="$final_path" # But FOR THE LOVE OF GOD, do not allow r/x for "others" on the entire folder - # this will be treated as a security issue. -mv $final_path/'example-singleServer-pretty.html' "$final_path/index.html" +mv $final_path/'example-singleServer-full.html' "$final_path/index.html" + +chmod 750 "$final_path" +chown -R $app:www-data $final_path +chmod o-rwx $final_path + #================================================= # NGINX CONFIGURATION @@ -171,14 +176,6 @@ ynh_replace_string --match_string="enable_id_obfuscation = false" --replace_stri #================================================= # GENERIC FINALIZATION #================================================= -# SECURE FILES AND DIRECTORIES -#================================================= - -# Set permissions to app files -chmod 750 "$final_path" -chown -R $app:www-data $final_path -chmod o-rwx $final_path - #================================================= # SETUP SSOWAT