Reputation: 395
I'm trying to install deploy my flask service on nginx with u-wsgi module. I'm getting this error when I restart 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`
my flask config file is --
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;
}
}
I tried to search for the problem and found that installing nginx-full
may solve the problem.
When I tried apt-get install nginx-full
error is--
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
Upvotes: 0
Views: 2644
Reputation: 12677
It looks like you need to install 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
To install packages with dependencies, specify the -f flag.
sudo apt-get -f install nginx-full
Upvotes: 2