Hi Suppose i got /var/www/website/secretfiles I want secretfiles to be accessed by only a few specific static ip addresses How do i achieve this ? This was possible in Apache2 using .htaccess files. But i really dont know how to get it going with nginx. Please advice. Thank You
Code: location <dir> { allow 1.2.3.4/32; # To give one ip access allow 192.168.1.0/24; # To give a whole network access deny all; }
http://www.cyberciti.biz/faq/linux-unix-nginx-access-control-howto/ I can do it in nginx.conf thanks for telling me the right words i searched with location deny nginx and got to the correct page thank you