Answer the question
In order to leave comments, you need to log in
Why can't I configure access to the folder with a password (Nginx)?
Guys, I'm already tormented, you need to restrict access to the folder with the script (The mini admin panel on Vuejs also uses PHP)
Server (Nginx, PHP-FPM, SSL)
There is a small js script in /utils
index file index.html
also pulls the file manager in php I set it up
using the standard method described in many manuals
location ~* ^/utils/index.html {
auth_basic "Hello, Manager";
auth_basic_user_file /etc/nginx/htpasswd;
}
location ~* ^/utils/index.html {
auth_basic "Hello, Manager";
auth_basic_user_file /etc/nginx/htpasswd;
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question