diff --git a/check_process b/check_process index 88fd2ab..a2a129d 100644 --- a/check_process +++ b/check_process @@ -7,7 +7,7 @@ ; Manifest domain="domain.tld" (DOMAIN) path="/path" (PATH) - admin="john" (USER) + admin="john" (admin) password="yourls123" (password) ; Checks pkg_linter=1 diff --git a/conf/nginx.conf b/conf/nginx.conf index dfff1a6..686b543 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -6,7 +6,7 @@ location __PATH__ { rewrite ^ https://$server_name$request_uri? permanent; } - try_files $uri $uri/ /yourls-loader.php; + try_files $uri $uri/ __PATHTOCHANGE__/yourls-loader.php; index index.php index.html index.htm; diff --git a/manifest.json b/manifest.json index cb65077..5b795f0 100644 --- a/manifest.json +++ b/manifest.json @@ -51,9 +51,9 @@ }, { "name": "admin", - "type": "user", + "type": "admin", "ask": { - "en": "Choose the Yourls administrator (can be other then YunoHOst registered user)", + "en": "Choose a Yourls administrator (can be other then YunoHost registered user)", "fr": "Administrateur du site Yourls" }, "example": "yoda" diff --git a/scripts/install b/scripts/install index d32b6c3..ebab6e4 100644 --- a/scripts/install +++ b/scripts/install @@ -86,6 +86,11 @@ ynh_setup_source "$final_path" #================================================= # Create a dedicated nginx config +if [ "$path_url" != "/" ]; then + ynh_replace_string "__PATHTOCHANGE__" "$path_url" "../conf/nginx.conf" +else + ynh_replace_string "__PATHTOCHANGE__" " " "../conf/nginx.conf" +fi ynh_add_nginx_config #=================================================