nginx的nginx.conf目录简单配置


 

nginx的nginx.conf目录简单配置

 

 我的nginx.conf是在  etc/nginx/目录下

我是直接在http随便找了个地方添加如下代码的:

server {
listen 8066;
server_name 192.168.0.200;

location / {
root /usr/local/nginx/html/xiaoxi/;
index index.html index.htm;
}


error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}

其中listen是用户需要访问你的端口号,server_name是你的ip地址

nginx的nginx.conf目录简单配置

 

原创文章,作者:bd101bd101,如若转载,请注明出处:https://blog.ytso.com/tech/aiops/271762.html

(0)
上一篇 2022年7月6日 21:45
下一篇 2022年7月6日 21:54

相关推荐

发表回复

登录后才能评论