我正在尝试使用u-wsgi模块在nginx上安装部署我的烧瓶服务。 当我重新启动nginx时,我收到此错误 -
`Restarting nginx: nginx.
nginx: [emerg] unknown directive "uwsgi_param" in /etc/nginx/uwsgi_params:1
nginx: configuration file /etc/nginx/nginx.conf test failed`
我的烧瓶配置文件是 -
server{
listen 2000;
server_name _;
#location = /flaskapplication { rewrite ^ /flaskapplication/; }
#include uwsgi_params;
location /flaskapplication { try_files $uri @flaskapplication; }
location @flaskapplication {
include uwsgi_params;
uwsgi_param SCRIPT_NAME /home/uday/demo/flask_performance;
uwsgi_modifier1 30;
uwsgi_pass unix:/home/uday/demo/uwsgi.sock;
}
}
我尝试搜索问题,发现安装nginx-full
可能会解决问题。
当我尝试apt-get install nginx-full
错误时 -
The following packages have unmet dependencies:
nginx-full : Depends: passenger-common (>= 1:3.0.17) but it is not going to be installed
Depends: passenger-common (< 1:3.0.18) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
enter code here
答案 0 :(得分:1)
看起来您需要安装Uwsgi。
sudo apt-get install nginx
sudo apt-get install uwsgi
sudo apt-get install uwsgi-plugin-python
sudo apt-get install uwsgi-plugin-http
要安装具有依赖项的包,请指定-f标志。
sudo apt-get -f install nginx-full