Apache 2.4 禁止通过IP地址访问

在httpd-vhosts.conf中配置:



	ServerName 218.*.*.*.*      #External HTTP Service IP Address
	DocumentRoot "${SRVROOT}/www/error"
	
		Require all denied
	



	ServerName HOST_NAME
	DocumentRoot "${SRVROOT}/htdocs"


你可能感兴趣的:(Apache)