服务器(centos)配置启动nginx,浏览器无法访问?
服务器启动nginx后,浏览器打开设置的ip,无法访问nginx
# the upstream component nginx needs to connect toupstream django {
# server unix:///path/to/your/mysite/mysite.sock; # for a file socket
server 127.0.0.1:8001; # for a web port socket (we'll use this first)
}
# configuration of the server
server {
# the port your site will be served on
listen 80;
# the domain name it will serve for
server_name 115.28.105.90; # substitute your machine's IP address or FQDN
charset utf-8;
# max upload size
client_max_body_size 75M; # adjust to taste
# Finally, send all non-media requests to the Django server.
location / {
uwsgi_pass django;
include uwsgi_params; # the uwsgi_params file you installed
}
}
不知道是什么原因?
回答:
看下centos是不是有什么默认启动的服务占用80端口了,禁用再开nginx
回答:
你这是配负载均衡啊,8001这个服务的nginx配置呢??
以上是 服务器(centos)配置启动nginx,浏览器无法访问? 的全部内容, 来源链接: utcz.com/a/162216.html