我已经为具有以下配置的 python 网站设置了带有 uwsgi 的本地 Nginx 服务器
server {
root /var/www/localhost/current;
index index.html index.htm;
server_name localhost;
location /static {
alias /var/www/localhost/current/static;
}
location / {
include uwsgi_params;
uwsgi_pass unix:/tmp/localhost.sock;
uwsgi_param UWSGI_PYHOME /var/www/localhost;
uwsgi_param UWSGI_CHDIR /var/www/localhost/current;
uwsgi_param UWSGI_MODULE wsgi;
uwsgi_param UWSGI_CALLABLE application;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/www;
}
}
uwsgi 配置:
[uwsgi]
plugins=python
vhost=true
socket=/tmp/localhost.sock
当我对位于/static
文件夹中的 CSS 文件进行更改时,我在浏览器中访问它时会得到以下信息:
这就是 CSS 的样子:
body {
background-color: #002b36;
position: relative;
padding-top: 50px;
color: #93a1a1;
}
如果我删除color: #93a1a1;
,我不会得到\u0
角色。关于这可能是什么的任何想法?