禁止非法恶意访问的IP[root@LNMP~]#vim/usr/local/nginx/conf/vhosts/linux.conflocation~.*admin\.php${allow127.0.0.1;denyall;#auth_basic"auth";#auth_basic_user_file/usr/local/nginx/conf/.htpasswd;includefastcgi_params;fastcgi_passunix:/tmp/dis.sock;fastcgi_inde..
分类:
其他好文 时间:
2016-12-03 02:42:31
阅读次数:
191
基本步骤: 第一步:创建根目录 第二步:配置虚拟主机 (文件:httpd-vhost.conf 位置:extra/httpd-vhosts.conf) 第三步:修改hosts文件(改完后打开www.bbs.com测试) 第四步:完善项目的组织架构 1、创建view目录,用于存放模板文件 (.htac ...
分类:
其他好文 时间:
2016-12-02 03:05:16
阅读次数:
169
以上界面,如果管理员设置密码过于简单其他人试出来,就太不安全了,所以在些基础上我们可以加一层用户认证。更新配置之前备份配置文件。[root@LNMPvhosts]#cd/usr/local/nginx/conf/vhosts#vimlinux.confserver{listen80;server_namewww.linux.com;indexindex.htmlindex.htmin..
分类:
其他好文 时间:
2016-11-30 17:48:32
阅读次数:
220
nginx负载均衡集群实际上就是代理环境说明:Nginx分发器;一个公网IP,一个内网IPRS1只有一个内网ipRS2只有内网ip#在nginx分发器上编辑文件#nginx负载均衡有自动检测rs的机制,当rs有一台机器宕机,nginx就不会把请求发个给那台rsvim/usr/local/nginx/conf/vhosts/upstream.con..
分类:
其他好文 时间:
2016-11-24 22:27:01
阅读次数:
328
1.更改host文件 更改host文件,http请求相应域名,指向本地服务器 2.配置httpd-vhosts.conf 在本地服务器内,寻找指定文件目录 3.更改httpd.conf 去掉下面这一行前面的# # Virtual hostsInclude conf/extra/httpd-vhost ...
分类:
Web程序 时间:
2016-11-21 19:49:15
阅读次数:
351
配置虚拟机最少需要修改两个文件,即httpd-vhosts.conf 和 hosts (记住修改任何配置前先备份哦,这才是个好习惯) 第一步,修改httpd-vhosts.conf文件, 文件路径 \apache\conf\extra\ 在文件底部加入下面这段 第二步,修改hosts文件, 文件路径 ...
分类:
Web程序 时间:
2016-11-17 00:22:10
阅读次数:
211
在一个Window Server 2008R2系统上使用Apache架设了一个PHP的网站项目 在配置Apache的过程中出现了以下问题 根据上面的提示说是没有相应的权限,那就在虚拟主机里进行了配置,httpd-vhosts.conf 中的配置如下 <VirtualHost *:80> Server ...
分类:
Web程序 时间:
2016-11-14 12:32:19
阅读次数:
324
#VirtualHosts##Requiredmodules:mod_log_config#Ifyouwanttomaintainmultipledomains/hostnamesonyour#machineyoucansetupVirtualHostcontainersforthem.Mostconfigurations#useonlyname-basedvirtualhostssotheserverdoesn‘tneedtoworryabout#IPaddresses.Thisisindicatedbyt..
分类:
Web程序 时间:
2016-11-09 13:22:41
阅读次数:
205
1.配置wamp网站地址: 找到wamp的安装目录,如~\wamp\bin\apache\Apache2.4.4\conf\extra\httpd-vhosts.conf 打开httpd-vhosts.conf文件 其中有默认的样例: <VirtualHost *:80> ServerAdmin w ...
分类:
其他好文 时间:
2016-10-31 21:58:39
阅读次数:
131
1.安装好xampp后 2.找到安装目录 apache目录--conf目录--extra目录--httpd-vhosts.conf文件(用记事本或者别的编辑器打开) 文件最后添加代码 3.打开C盘,依次找到下面的目录:windows目录--system32目录--drivers目录--etc目录-- ...
分类:
其他好文 时间:
2016-10-19 23:46:29
阅读次数:
299