Password protecting a folder/resource with Nginx, add the following to Nginx configuration file or nginx virtualhost desired :
location / {
auth_basic "Restricted";
auth_basic_user_file /etc/nginx/htpasswd;
}
for example i want to protect folder dicatatdl.tk/dicatatdl, add this config into Nginx vhost configuration file on /etc/nginx/conf.d/dicatatdl.tk.conf
#nano /etc/nginx/
How to Protect Folders/Resource with Password on Nginx
4/
5
Oleh
Admin