Questions tagged [uwsgi]

Questions regarding uWSGI which is a full stack for building hosting services

The uWSGI project

The uWSGI project aims at developing a full stack for building hosting services.

Application servers (for various programming languages and protocols), proxies, process managers and monitors are all implemented using a common api and a common configuration style.

Thanks to its pluggable architecture it can be extended to support more platforms and languages.

Currently, you can write plugins in C, C++ and Objective-C.

The “WSGI” part in the name is a tribute to the namesake Python standard, as it has been the first developed plugin for the project.

Versatility, performance, low-resource usage and reliability are the strengths of the project (and the only rules followed).

Github Docs

346 questions
1
vote
1 answer

uwsgi native https support?

I want to run my uwsgi server with https. Yes, I know it is a wrong thing to do in production. The docs clearly say: configure your keys and use --https option: http://uwsgi-docs.readthedocs.org/en/latest/HTTPS.html Problem is, no such option…
thule
  • 119
  • 3
1
vote
1 answer

Is it possible to get uwsgi to restart on 500 errors

I occasionally have issues where a db will restart or something similar. In these cases I need to go in and manually restart uwsgi. Is it possible to setup uwsgi to restart on 500 errors? Ideally I could get the worker to restart on a number of of…
emperorcezar
  • 113
  • 5
1
vote
0 answers

Internal Server Error with Nginx and uWSGI

I'm trying to host an app using Nginx on Linode.com but I'm stuck early on uWSGI config. I've used "Getting Started" guide and "WSGI using uWSGI and nginx on Ubuntu 12.04 (Precise Pangolin)" guide and I've succesfully deployed Nginx (got Nginx…
Dominik Serafin
  • 111
  • 1
  • 4
1
vote
0 answers

Nginx - How to authorize access to repositories using python script

I have set up a local Git server using Nginx ( in Ubuntu ) ,Now I want to authorize users using external python script , which should authorize them against predefined database . AFAIK, I have to use uwsgi to link python script with Nginx, however…
Ahmed T. Ali
  • 111
  • 3
1
vote
2 answers

UWSGI Bad Gateway - Connection refused while connecting to upstream

Trying to get a basic Django app running on nginx using UWSGI. I keep getting a 502 error with the error in the subject line. I am doing all of this as root, which I know is bad practice, but I am just practicing. My config file is as follows (it's…
HectorOfTroy407
  • 135
  • 1
  • 5
1
vote
0 answers

Mapping uWSGI processes to specific cpu cores

I have 2 sites on my server (debian) with 4 cpu cores. For both of them I use workers=2 and cpu-affinity=1 so workers are mapped to cpu 0 and 1 for both sites like that: spawned uWSGI master process (pid: 19345) spawned uWSGI worker 1 (pid: 19346,…
alTus
  • 111
  • 3
1
vote
0 answers

No Module Named OS - NGINX/UWSGI/NGINX

Have looked at many related posts and most point to an outdated version of python that is cause the 'no module named os' during the uwsgi boot. I've run print sys.version_info And it shows python 2.7, which all the other sources say is recent…
HectorOfTroy407
  • 135
  • 1
  • 5
1
vote
1 answer

NGINX + uWSGI + Flask. Some requests very slow

We're running a fairly large Flask application and finding that at random times we'll end up with a very slow request (sometimes a minute or more) I presume the issue is related to lazy-loading modules and slow requests are when a new worker needs…
Cfreak
  • 125
  • 1
  • 12
1
vote
0 answers

Django / uWSGI - Nginx giving 502 status code: error.log says "Permission Denied"

I'm trying to setup my Django app to use uWSGI and Nginx. I'm following this tutorial: http://uwsgi-docs.readthedocs.org/en/latest/tutorials/Django_and_nginx.html I'm on the "Using Unix sockets instead of ports" step. I tried doing uwsgi --socket…
user2719875
  • 129
  • 1
  • 7
1
vote
0 answers

Django uwsgi Nginx not serving media files - Django returns 404 status code

I originally posted this on SO but I think it might belong here instead. I'm following this tutorial: http://uwsgi-docs.readthedocs.org/en/latest/tutorials/Django_and_nginx.html Everything was going well until I reached the "Basic nginx test"…
user2719875
  • 129
  • 1
  • 7
1
vote
0 answers

502 Bad Gateway from relocated instance on AWS EC2

I tried to move some instance from tokio region (which by the way, it's working normally) to sao paulo region, then I followed this basic steps to perform but when I launch the instance from the generated AMI and turn on, it shows me "502 Bad…
geoom
  • 111
  • 1
  • 5
1
vote
1 answer

uwsgi configuration with Nginx, with python scripts as cgi - 502 Bad Gateway

This is my .ini file to run the uwsgi "pyApp.py" [uwsgi] plugins = cgi socket = 127.0.0.1:9010 cgi = /=/usr/share/test/ cgi-allowed-ext = .py cgi-helper = .py=python i have a file "firstapp.py" at location /usr/share/test/firstapp.py Its contents…
Archer
  • 113
  • 8
1
vote
1 answer

Nginx: Tracking try_files misses

We are using try_files as cache rather than hitting the UWSGI to serve the file. Using a rule like the following: try_files $uri @uwsgi_app; I was wondering what is the best way of logging the cache success of this?
tgandrews
  • 155
  • 1
  • 1
  • 7
1
vote
1 answer

uWSGI writes log as root

I have following uwsgi.ini: [uwsgi] uid = myuser gid = myuser master = true daemonize = /path-to-log/uwsgi.log ... I run uwsgi in rc.local. I can see workers run as myuser, I can see uwsgi switches to myuser in log and I'm assuming myuser will also…
demalexx
  • 115
  • 5
1
vote
1 answer

uWSGI cannot load virtualenv

I'm setting up a Python app using nginx and uWSGI. My dependencies are in a virtualenv. If I activate the virtualenv manually, everything works by running this command: uwsgi --ini uwsgi.ini But if I try to run the same command with the virtualenv…
handsofaten
  • 337
  • 1
  • 3
  • 6