Skip to main content

Restricting access to the admin site by ip using nginx

If you have a static ip, and you administer the site exclusively from this address, you can restrict access to the admin panel of the site by ip. As a rule, site control panels are located in a folder (occasionally on a subdomain :) For example, WordPress has / wp-admin /. So, you need to restrict access only to this directory. In this case, the configuration code will look like this:

(Further…)