配置也是改了下老师的文件
# the upstream component nginx needs to connect to
upstream django {
# server unix:///path/to/your/mysite/mysite.sock; # for a file socket
server 127.0.0.1:8086; # for a web port socket (we'll use this first)
}
server {
#监听端口
listen 80 ;
# 服务器域名或者IP地址
server_name 127.0.0.1 ;
# 编码
charset utf-8;
# 文件最大上传大小
client_max_body_size 75M; # adjust to taste
# 媒体文件
location /media {
alias /root/MxOnline/media; # 指向django的media目录
}
# 静态文件
location /static {
alias /root/MxOnline/static; # 指向django的static目录
}
# 主目录
location / {
uwsgi_pass django;
include uwsgi_params;
}
}
都不知道哪里的问题