各位大佬 在学习项目部署
nginx设置如下,但是静态文件一直不显示。恳请各位大佬帮忙看看
设置的路径没问题。。找不到原因
nginx.cof 内容如下
user www-data;
worker_processes auto;
pid /run/nginx.pid;
error_log /var/log/nginx/error.log;
include /etc/nginx/modules-enabled/*.conf;
events {
worker_connections 768;
# multi_accept on;
}
http {
sendfile on;
tcp_nopush on;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
upstream django {
server 127.0.0.1:8002;
}
server {
listen 80;
listen [::]:80;
location /static {
alias /data/www/unicom/unicom/static;
}
location / {
uwsgi_pass django;
include uwsgi_params;
}
}
}
nginx设置如下,但是静态文件一直不显示。恳请各位大佬帮忙看看
设置的路径没问题。。找不到原因
nginx.cof 内容如下
user www-data;
worker_processes auto;
pid /run/nginx.pid;
error_log /var/log/nginx/error.log;
include /etc/nginx/modules-enabled/*.conf;
events {
worker_connections 768;
# multi_accept on;
}
http {
sendfile on;
tcp_nopush on;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
upstream django {
server 127.0.0.1:8002;
}
server {
listen 80;
listen [::]:80;
location /static {
alias /data/www/unicom/unicom/static;
}
location / {
uwsgi_pass django;
include uwsgi_params;
}
}
}