W
W
wawa2018-06-11 19:55:58
linux
wawa, 2018-06-11 19:55:58

How to run uwsgi on port 80 as securely as possible?

I want to run uwsgi without front.
Port 80 is for root only. But I don't want to run uwsgi as root. He even throws warning at it.
In the uwsgi config I specify uid=myuser and I get scolded for denied access to the socket.
How do you still run uwsgi to listen on 80 and at the same time so that it conducts all the rest of its activities as an unprivileged user?
PS: I don't plan to use this in production. I just want to sort out this issue. After all, with the launch of nginx, the same dilemma will arise.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Gornostaev, 2018-06-11
@sergey-gornostaev

sudo setcap CAP_NET_BIND_SERVICE=+eip /usr/bin/uwsgi

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question