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
4
votes
1 answer

UWSGI and NGINX for Python Apps on Ubuntu 11.10

I am trying to find an optimal way to set up my server to use NGINX and UWSGI to serve python applications. The following has worked so far: Initial setup: sudo apt-get install nginx uwsgi uwsgi-plugin-http uwsgi-plugin-python…
knpwrs
  • 357
  • 1
  • 5
  • 14
3
votes
1 answer

uWSGI can't load config in Docker

I have a weird problem, which is probably related to my Dockerfile, but I fail to see it - I've tried different settings, but nothing helps. Here is my uwsgi.ini file: [uwsgi] strict = true socket = 0.0.0.0:8000 protocol = http module =…
Djent
  • 99
  • 2
  • 6
  • 16
3
votes
3 answers

Selinux 'var_t' base type warning

I am currently 'lost' in the CentOS Selinux forest. My setup involves setting up a WSGI socket in /var/www/demo/out which nginx uses to communicate with the UWSGI process. Whenever I request the page in my browser I get an nginx error. Why is this…
3
votes
2 answers

uWSGI and NGINX 502: upstream prematurely closed connection

I have a Kubernetes cluster which is running Django application within docker container served by uWSGI. The ingress controller is ingress-nginx (this one: https://github.com/kubernetes/ingress-nginx). Recently I did an upgrade of the whole…
Djent
  • 99
  • 2
  • 6
  • 16
3
votes
1 answer

Restart Django/uWSGI vassal in uWSGI emperor mode

I am running a django site using uWSGI in emperor mode. I have found that while touching the uwsgi.ini file for a specific application does indeed cause the emperor process to reload that vassal (according to the log file) that a reload is not…
digitaladdictions
  • 1,505
  • 1
  • 12
  • 30
3
votes
0 answers

How to fix mysql has gone away, high writeiops, switch to postgres?

We have a Django site (Django 1.4) running under NGINX and uwsgi. The site uses MYSQL 5.6.39 which runs on a separate AWS RDS instance. It runs fine for about a week but then suddenly we get the dreaded MYSQL 2006 error - MYSQL server has gone away.…
Marc
  • 151
  • 2
3
votes
1 answer

How logrotate behave when there is * and there is one explicit filename in log rotation in one path?

The question is little bit long! Let me explain with the example below. I have a log-rotation configuration file in /etc/logrotate.d/ which is used for uwsgi: "/var/log/uwsgi/*.log" "/var/log/uwsgi/*/*.log" { copytruncate daily rotate 5 …
Alireza
  • 583
  • 4
  • 9
  • 27
3
votes
3 answers

Nginx uWSGI responses truncated

I tried to write a web service as a joke today at http://dont-tread-on-memes.controversial.io. It's a flask app that serves fairly large images. The Flask app works well on its own, as does an independent uWSGI server, but when I try to plug uWSGI…
Luke Taylor
  • 151
  • 7
3
votes
1 answer

uwsgi sometimes fails to compile in Alpine Linux in a Docker container

I recently switched to Alpine Linux for my docker images, and Alpine doesn't have uwsgi-python3 plugin at the moment. Thus, I compile uwsgi during the container build with pip3 install uwsgi. For some reason, this fails every now and then without…
Ilya Semenov
  • 191
  • 1
  • 8
3
votes
0 answers

How to config nginx and uwsgi to cache a url any way?

Update2: add uwsgi_ignore_headers Cache-Control Set-Cookie X-Accel-Expires Expires Vary; and problem solved. Thanks everyone. Update: I tried uwsgi_ignore_headers Cache-Control Set-Cookie X-Accel-Expires Expires Vary;. Doesnot work. I also find…
xiang
  • 33
  • 4
3
votes
1 answer

Using uWSGI's built-in load balancer vs nginx

I have a python app that is exposed through wsgi and was going to deploy it to the world. There are no static assets that are served from it. The app will be deployed to a single machine. I am going to serve the wsgi app using uwsgi and could…
dm03514
  • 201
  • 1
  • 3
  • 12
3
votes
0 answers

uWSGI won't start via Upstart, but starts ok from the console

I'm trying to make uWSGI run on boot using Upstart on a Vagrant box. So I've created /etc/init/uwsgi.conf with the following contents: # simple uWSGI script description "uwsgi tiny instance" start on runlevel [2345] stop on runlevel [06] …
Eugene Yarmash
  • 2,433
  • 5
  • 34
  • 54
3
votes
3 answers

504 Gateway Time-out uwsgi + nginx django application

I'm trying to run my Django application using Nginx + uwsgi, but I receive 504 Gateway Time-out after one minute of loading. My app takes time to do what needed as it searches for specific things on several websites. My nginx conf is the next one: …
Cajuu'
  • 131
  • 1
  • 1
  • 3
3
votes
0 answers

uwsgi and "No module named django.core.wsgi"

On a fairly vanilla FreeBSD system without virtualenv, I'm having trouble getting uwsgi to work with Django. Attempting to run generates this error: Traceback (most recent call last): File "./myapp/wsgi.py", line 3, in from…
user148905
3
votes
0 answers

Pyramid + Nginx + uWSGI Server 500 Errors

I have a uWSGI application written in Python using the Pyramid framework. Nginx is configured like below (I left out a few bits, but I don't think they will matter): upstream uwsgicluster { server 127.0.0.1:8989; } # Proxying…