1

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

emperor = /srv/*/uwsgi.ini

vassals-include = /etc/uwsgi/vassals-include.ini

touch-reload = /etc/uwsgi/emperor.ini
touch-reload = /etc/uwsgi/vassals-include.ini

chmod-socket = 770
chown-socket = www-data


stats = /var/run/uwsgi/emperor-stats.sock

auto-procname = true
vacuum = true
workers = 1
logto = /var/log/uwsgi/emperor.log
safe-pidfile = /var/run/uwsgi/emperor.pid

Vassals include.ini

[uwsgi]
logto = /var/log/uwsgi/%N-%C.log
pidfile = /var/run/uwsgi/vassal-%C.pid

stats = /var/run/uwsgi/vassal-%C-stats.sock
chdir = %D

socket = /var/run/uwsgi/vassal-%C.sock

heartbeat = 10
max-requests = 100

subscribe-to = /var/run/uwsgi/fastrouter-sub.sock:%C

unsubscribe-on-graceful-reload = true

app.ini

[uwsgi]
module=wsgi
enable-threads =true
master= true
processes = 5
socket = app_socket.sock
chmod-socket 755
vacuum = true
plugin = python3
die-on-term = true

Nginx config(works AOK for single mode)

server {
    listen 80 default_server;
    listen [::]:80 default_server;
    root /var/www/html/hacks;
    location /static{
        alias /var/www/html/hacks/static;
    }
    location /{
        include uwsgi_params;
        uwsgi_pass unix:/var/www/html/hacks/app_socket.sock;
    }
}

Basically it's looking like I may have to just spawn multiple uwsgi processes with each one pointing towards a different configuration(as a workaround). It always gives me the error about no being able to connect to the unix socket.

  • What is the error that you received? – Michael Hampton Jun 10 at 20:01
  • It was the old "error 111" socket connection refused error. The socket can be read AOK when I'm running uwsgi in single mode but I wanted to have a dev/playground version of the site for some teammates to hack on and have a stable version that presented work when it was done at the same time. – 133794m3r Jun 11 at 3:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.