Welcome! Log In Create A New Profile

Advanced

Re: uwsgi problems

Steven Williams
October 12, 2014 01:54PM
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


On 10/10/2014 12:13 AM, Roberto De Ioris wrote:

> This covers basically any aspect of a production
> ready-deployments:
>
> http://uwsgi-docs.readthedocs.org/en/latest/WSGIquickstart.html
>
> as you can see it uses tcp sockets when describing nginx
> integration. This avoid you to start messing with permissions (btw,
> the process connecting to the unix socket, nginx in your case, must
> have write permission on the socket).
>
> Read and follow the whole quickstart from start to end, as it
> progressively introduces concepts
>

That did the trick. Apparently SELinux was interfering with Nginx
connecting by the port number. I adjusted the policy and everything is
working fine now. Thank you for telling me to read the guide from
start to finish.

For posterity's sake all nginx needed was:

location / {
include uwsgi_params;
uwsgi_pass 127.0.0.1:3031;
}

$ uwsgi --socket 127.0.0.1:3031 --wsgi-file run.py

In order to get that working under Fedora and CentOS you have to
adjust the running SELinux policy which you can do with the following:

$ sudo cat /var/log/audit/audit.log | grep nginx | grep denied |
audit2allow -M mynginx
$ sudo semodule -i mynginx.pp

Thanks guys.

Steven Williams
My PGP Key: http://pgp.mit.edu/pks/lookup?op=get&search=0xCACA6C74669A54FA
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJUOr+tAAoJEMrKbHRmmlT6mgwP/0hW3iZhGzFOlNp1XJp3ALs0
xVA3DISGzf8uigJXDnARNIcLRDzw16f8SeTpYYZs8YLZStvx0xaJYsdj9Us9rPLC
dymF1kO3CwKjsuAS4Os94ENCFqzob5cqNdN6sp0dV1U1MLX17R1mvLych5WCosJp
aFL6eMoP/CFI9cbfS1kbMLowVSOfjOmsq9R6ZVrvkEUM9hSH1gRmXbvJR6bMW7Sz
vEH0eCLmL8/Z40YcX9ChXMvpZd1NoOLfMMQo/yKCHtrQQ/OBiSTPKu76KgIxNaiJ
k5tDC6cAKw0xhvQ3XsT7skMiMRrUUozpnouhS7ochTXcQaXBKJ2uEA0qMgPhRgom
K+OwJxrAAB0KglyLKdjiaNysI06Oy+eMn+WBQDX5BOVg35RjcWc/v8gRbdCSrLLO
iTMma5uCReHLhfuPignMYOHQNWpwUwxygbHzSNGbs7rFDe8HQkC6UZA8r7Qzs7fD
as6xPAjs3oTuW2fJRzOolzVO0qKmo1D/XQIL3YiscTYnqyololHdCGUgkz+a5NYY
B9xgYgrI1NIYos2+L8mfvTeEj2xe2AMm1KU/3tepVoDc+2lle2dzl8utC2LJCKbU
0jaQhmjyzY4MKW11L6qHA17Do3GlKTp4mlQIl141pNSf1SY4ik3RyhKos6SnSWUN
3VXEKnnHUH4yS1hoiV4j
=TG21
-----END PGP SIGNATURE-----

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

uwsgi problems

Steven Williams October 09, 2014 08:48AM

Re: uwsgi problems

fletchowns October 09, 2014 01:52PM

Re: uwsgi problems

Steven Williams October 09, 2014 04:54PM

Re: uwsgi problems

fletchowns October 09, 2014 05:54PM

Re: uwsgi problems

roberto October 10, 2014 01:20AM

Re: uwsgi problems

Steven Williams October 12, 2014 01:54PM

Re: uwsgi problems

Valentin V. Bartenev October 10, 2014 11:08AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 143
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready