Linux 拨号vps windows公众号手机端

windows下nginx如何搭建网站

lewis 7年前 (2018-12-13) 阅读数 16 #VPS/云服务器
文章标签 nginxwindows建站

windows下nginx搭建网站的方法:

1.打开nginx安装目录,找到“nginx.conf”配置文件。

2.把本机的80端口的访问请求转到我们自己的网站主页上,配置如:

server {

listen 80;

server_ name localhost;

#charset koi8-r:

access_ 1og 1ogs/host.access.1og main;

location / {

root D:/MyWebApps/; //改成nginx根目录

index index.html index.htm;

]

3.在nginx.exe文件的目录下打开cmd命令窗口,执行命令:

nginx.exe -s reload

4.把准备好的网站程序放进nginx根目录即可。

版权声明

本文仅代表作者观点,不代表米安网络立场。

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

热门