Skip to main content

Questions tagged [uwsgi]

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

Filter by
Sorted by
Tagged with
0 votes
1 answer
22 views

Nginx or uWSGI to serve sitemap and robots?

Does it matter whether it's nginx or uwsgi that serves sitemap.xml and robots.txt? If it's uwsgi, then I'd need to add the two routes in my python server, which I feel like gets a bit cluttered. With ...
No Name's user avatar
  • 101
0 votes
0 answers
42 views

uwsgi Emperor mode and systemd

I recently created two working configurations for starting uwsgi in Emperor mode with systemd. With the first configuration, the socket is created by uwsgi – Configuration 1 # /etc/systemd/system/...
janeden's user avatar
  • 267
0 votes
1 answer
98 views

uwsgi socket not found when started via systemd

I try to start uwsgi (installed manually via pip) in Ubuntu 22.04 as a systemd service, but so far without success. Nginx cannot connect to the uwsgi socket, although the service is running: 2024/05/...
janeden's user avatar
  • 267
0 votes
1 answer
97 views

Exposing two applications on different external ports using nginx - nginx: [emerg] bind() to 0.0.0.0:8000 failed (98: Address already in use) [closed]

I am trying to make two apps be accessible on my LAN server (raspberry pi). lab_app: this one is a very simple app, made with flask from a third party, using a sqlite3 database, which results to be a ...
Tms91's user avatar
  • 101
0 votes
1 answer
478 views

Django uwsgi behind haproxy: http or http-socket?

I've a Django app inside a docket that uses uwsgi. Since we have several Dockers running on different machines we have haproxy as load balancer. My question is: should I use uwsgi with http or http-...
EsseTi's user avatar
  • 257
0 votes
0 answers
67 views

uWSGI with nginx bad gateway error

So I'm trying to host my django app with nginx and uwsgi but i keep running into a 502 bad gateway error. I have the following nginx config. upstream django { server unix:///home/david/...
david backx's user avatar
0 votes
0 answers
109 views

Permission problems with uWSGI and Modoboa

I have run a manual installation of Modoboa (https://modoboa.readthedocs.io/en/latest/installation.html#manual-installation), which runs a webapp in uWSGI. I moved the static content to /var/www/html ...
daydr3amer's user avatar
1 vote
1 answer
171 views

nginx Expires header based on mime type for proxied content?

My setup uses a map to define different Expires headers for various static files (based on their mime type). For proxied content (uwsgi_pass), I use a static Expires header: map $...
janeden's user avatar
  • 267
0 votes
0 answers
238 views

Issues with cgi-bin scripts using uWSGI and nginx

I am trying to get cgi-bin scripts running on an nginx system using uWSGI and I am having issues with this, and with debugging this to figure out what is going wrong. The system is a Raspberry Pi ...
John Tate's user avatar
  • 199
1 vote
1 answer
341 views

uwsgi: strange error message: unknown config directive: inifile

I have a uwsgi.ini file. It works perfectly, but if I add strict=true it fails with the message [strict-mode] unknown config directive: inifile however the word inifile doesn't even exist in my ...
gelonida's user avatar
  • 289
0 votes
1 answer
85 views

can nginx block incoming headers as reverse proxy / uwsgi client

I am using nginx and would like to block certain incoming headers, such, that uwsgi never receives these headers a server / service that I proxy to will not receive them How can I achieve this
gelonida's user avatar
  • 289
1 vote
0 answers
305 views

Handling a deployment in prod with in memory data with uwsgi & kubernetes

I'm in a bit of a bind here and I'm looking for pointers as to how to best manage my situation: So, I have a Flask app with uwsgi and I'm deploying this to Kubernetes with 2 pods. UWSGI configuration ...
Saturnian's user avatar
  • 111
2 votes
0 answers
2k views

NGINX (111: Connection refused) error while connecting to upstream

I am setting up a configuration for NGINX but I am constantly getting the following error: 8#8: *698 connect() failed (111: Connection refused) while connecting to upstream, client: <IP1>, ...
Japkeerat Singh's user avatar
0 votes
0 answers
796 views

How to add multiple ip and add sub-domain in nginx?

I was following the nginx,uwsgi with flask & docker tutorial. My nginx config file contains: server { listen 5000; server_name 19X.X.X.X; client_header_buffer_size 5M; ...
siam's user avatar
  • 1
1 vote
1 answer
671 views

What's the advantage of uwsgi protocol over http for Apache proxying?

I've just set up a couple of WSGI apps behind an Apache server proxying to uwsgi using UNIX sockets on the same host. The generally advertised method to do that seems to be like this: Apache config: ...
musbur's user avatar
  • 213
-2 votes
1 answer
870 views

Hosting Multiple Django Websites on a VPS

I'm moving away from WordPress and into bespoke Django websites. I've settled on Django as my Python framework, my only problems at the moment are concerning hosting. My current shared hosting ...
StudioProjects's user avatar
0 votes
1 answer
924 views

Unix socket communication with Apache 2.4.51 and Flask App using Uwsgi returning "404 Not Found"

I'm using Apache in the front as web server and running python flask application at the back end and they communicate using Unix socket as mentioned in the link below for mod_proxy_uwsgi module and i ...
Jai's user avatar
  • 1
0 votes
1 answer
1k views

centos8 nginx uwsgi socket permission denied

I've configured uwsgi and nginx to work through socket(chmod 777) which is located in user home dir, but nginx can't access the socket(13: Permission denied in error.log). Tried moving socket to /tmp/ ...
dav's user avatar
  • 13
1 vote
1 answer
2k views

uWSGI aborts responses, loses connection to nginx

I'm running a small web application written in Python, running in uWSGI and served through nginx. There's a component that generates ZIP files for downloading, which occasionally can be quite large (...
Felix's user avatar
  • 46
1 vote
1 answer
286 views

How to tell nginx to honor backend's cache? uWSGI

There's a similar question but solution there doesn't work for me. We have nginx and uWSGI ad backend. We need nginx to cache the backend response according to what is in the response header. For ...
Putnik's user avatar
  • 2,347
0 votes
0 answers
626 views

How do I configure uwsgi as a production WSGI server?

I have a flask app that I want to run using uwsgi. I am also managing the uwsgi with supervisor. here is the my supervisor.conf file [program:myapp] command=/opt/python_envs/apps/bin/uwsgi --ini /opt/...
Hussain Nagri's user avatar
3 votes
0 answers
4k views

Nginx converts POST Request to GET request while proxy_pass

I am having 3 Server: A, B, C. Details are: Server A: NGINX Server, URL: https://test1.example.com Server B: NGINX Server hosting NodeJS Web Application, URL: http://test2.example.com Server C: ...
Amarjeet Sharma's user avatar
1 vote
1 answer
1k views

UWSGI block incoming connections when all threads are busy

I have a simple UWSGI app put behind a LB with the following .ini config [uwsgi] socket=0.0.0.0:5071 chdir = src/ wsgi-file = uwsgi.py processes=2 threads=1 protocol=http plugins=python exit-on-reload=...
Constantin's user avatar
2 votes
0 answers
2k views

Nginx + uWSGI + Flask Connection Reset

Problem I have a Flask app deployed using Elastic Beanstalk's "Single Container Docker" platform (latest revision 3.2.5 at the time of writing), with an "Application Load Balancer" ...
jlucier's user avatar
  • 121
0 votes
0 answers
138 views

Is it possible to define "excludes" for check-static in uwsgi settings?

I have an application which I don't want to modify. It has multiple directories with static files which are defined as static via check-static directive in uwsgi's .ini-file. My problem is that each ...
strizhechenko's user avatar
2 votes
1 answer
4k views

Invalid Request Block Size with Nginx and USWGI

I am trying to load balance 2 Python apps using Docker and Nginx. App 1 is run using UWSGI and App 2 is run using default Python Server (I used default server for App 2 just for testing purposes. At ...
Mervin Hemaraju's user avatar
0 votes
0 answers
1k views

uWSGI cannot find “application” using Flask and Virtualenv

This is the error im getting using uwsgi on my webserver *** Operational MODE: single process *** ModuleNotFoundError: No module named 'app' unable to load app 0 (mountpoint='') (callable not found or ...
Yierith's user avatar
2 votes
1 answer
2k views

How to use UNIX domain sockets behind Apache / mod_proxy_uwsgi?

On my development system I'm running a Flask WSGI application with uwsgi and nginx. However on the production server I need to use Apache instead of nginx, so I'm trying to do that. In nginx the site ...
musbur's user avatar
  • 213
1 vote
1 answer
148 views

uWSGI on ubuntu 18 suddenly fails when --never-swap specified

I use uWSGI on ubuntu 18 (18.04.5 LTS). Very recently this stopped working - I'd get this error on startup: Fatal Python error: Cannot recover from MemoryErrors while normalizing exceptions. Nothing ...
Rich B's user avatar
  • 11
0 votes
1 answer
2k views

Why is my virtualenv not activated by uwsgi?

On a fresh install of Debian Bullseye I am unable to use the uwsgi command. It fails to load the requested virtualenv. This is the command that fails: uwsgi --plugins http,python3 --wsgi-file wsgi.py -...
Jaap Joris Vens's user avatar
2 votes
1 answer
1k views

uwsgi vassal does not use virtualenv

I am running a python application started by an uwsgi emperor. The application is supposed to run in a specific venv, but I cannot get that to work. The ini file for the application specifies a venv ...
ygramoel's user avatar
  • 151
1 vote
1 answer
2k views

HAProxy + uwsgi all connection "Connection reset by peer"

I've a problem with UWSGI + HAProxy. for all the connections that get closed, i see this log in uwsgi file [uwsgi-http key: client_addr: 192.168.173.250 client_port: 57002] hr_read(): Connection ...
EsseTi's user avatar
  • 257
0 votes
1 answer
1k views

Unable to connect flask app by public ip and domain using ubuntu, nginx, uwsgi

I am a beginner in web developement, trying to deploy my flask app in oracle cloud with ubuntu 18.04, nginx, uwsgi and flask. nginx config is default. myapp.config for server is: server { listen ...
Biswajit's user avatar
  • 101
1 vote
0 answers
230 views

Multiple "Location" sections with different handlers aren't combined anymore in apache2 after upgrade

I have a website with the following configuration: <VirtualHost *:80> ServerName example.it <Location /> SetHandler uwsgi-handler uWSGISocket /var/sitedir/moin.sock </...
Pietro Battiston's user avatar
0 votes
1 answer
4k views

flask app served by nginx uwsgi returns 502

I cannot connect to a flask app (searx search engine) served by nginx and uwsgi. My web server shows "502 Bad Gateway nginx" Here is my nginx error: error log: /var/log/nginx/error.log [crit]...
posop's user avatar
  • 247
0 votes
0 answers
2k views

nginx error 500 when making api request to backend container

I am having trouble in setting up a system that consists of an nginx set up as a reverse proxy processing https requests on a Virtual Machine that is livin on my local computer. This reverse proxy ...
Christian Geng's user avatar
1 vote
0 answers
387 views

uWSGI in emperor mode Nginx can't access socket

But when I do it in single mode then it runs just fine. emperor.ini uid = www-data gid = www-data #exec-asap = mkdir -p /var/run/uwsgi #exec-asap = chown -R www-data:www-data /var/run/uwsgi ...
133794m3r's user avatar
  • 155
0 votes
0 answers
1k views

/myproject.sock failed (111: Connection refused) while connecting to upstream,

Iam serving flask by nginx and uwsgi but i am getting a permission error Iam newbie with nginx /var/log/nginx/error.log *1 connect() to unix:///usr/share/nginx/html/myproject/myproject.sock ...
black snow's user avatar
1 vote
0 answers
407 views

nginx + uWsgi is not using it's maximum capability. 90% workers remain idle all the time

I have deployed my Django application using nginx + uwsgi. I have also implemented micro caching and made other changes by following this article (Nginx 10k concurrent connections). Now I am using ...
Ankit Rastogi's user avatar
1 vote
0 answers
707 views

pip3 install wsgi can't find openssl libraries on QNAP

When try to install uwsgi via pip3, it cannot find some openssl libraries, though I think they are installed. In similiar issues it was recommended to install libssl-dev but the package manager I am ...
Lukas's user avatar
  • 111
2 votes
0 answers
2k views

Nginx - UWSGI 504 gateway timeout

I saw lots of topics of nginx 504 error , but non if them solved this. Im using nginx , uwsgi on 1 machine to run Django application . i tried to add these config line at the end of /etc/nginx/...
Mehdi bahmanpour's user avatar
4 votes
1 answer
2k views

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 = ...
Djent's user avatar
  • 109
0 votes
0 answers
111 views

Nginx error upon attempting to view my website 502 Http Error

When I go to view my website.com in the browser it fails to properly load with a HTTP 502 error. When I view the logs at: /var/log/nginx/error.log I get: 2019/11/22 18:32:34 [error] 1761#1761: *25 ...
John Deer's user avatar
1 vote
0 answers
673 views

Should I avoid CORS when building an SPA with backend API hosted on the same server?

I've stumbled upon this question and had the thought that my application should not require CORS, since it is hosted on the same server (a raspberry pi). However, since CORS is a security "feature" I'...
HackXIt's user avatar
  • 21
0 votes
1 answer
3k views

VueJS sending POST to Flask fails (CORS Request blocked)

I've been following this vuejs guide and this flask guide to host my frontend and backend on a raspberry pi. On my frontend I have this method, which sends an axios POST to the backend. // path = ...
HackXIt's user avatar
  • 21
5 votes
2 answers
17k views

nginx works on LAN IP but not on public IP

I have setup a nginx web server with uwsgi to host my flask app. When I access it through the LAN ip (192.168.1.x) I get the website just fine but when I access it through my public IP i am greeted ...
david doyyer 32's user avatar
3 votes
3 answers
2k views

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 ...
ExcellentAverage's user avatar
2 votes
1 answer
3k views

Flask to uwsgi threading get stuck

im Using Python 3.7.3, uwsgi 2.0.18, (docker container image python:3-stretch) We have development environment where we are running our code on flask and we change it to uwsgi when we test it on ...
Batchen Regev's user avatar
1 vote
0 answers
809 views

Uwsgi/nginx unix socket refusing connections

I have a python project that I am trying to serve with uWSGI and Nginx. I'm trying to connect the two with a Unix IPC socket (debian stretch), but the socket refuses connections whenever Nginx tries ...
uwsgiissues's user avatar
1 vote
0 answers
1k views

nginx + uwsgi + django 502 bad gateway on aws ec2

I have successfully installed nginx and uwsgi on aws ec2 instance. But on hitting the public IP its showing "502 bad gateway". Though both nginx and uwsgi server status is running and active. The ...
Jatin Goyal's user avatar

1
2 3 4 5
7