Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision |
Your text |
Line 38: |
Line 38: |
| } | | } |
| </nowiki>}} | | </nowiki>}} |
|
| |
| === uWSGI Emperor Config ===
| |
|
| |
| It is a good idea to run the uWSGI apps as vassals to the uWSGI Emperor service. Install it with:
| |
|
| |
| {{bc|sudo yum install uwsgi uwsgi-plugin-python3}}
| |
|
| |
| Then create a uwsgi config file for mediagoblin:
| |
|
| |
| {{hc|/etc/uwsgi.d/mediagoblin.ini|<nowiki>
| |
| [uwsgi]
| |
| plugin=python3
| |
| uid=mediagoblin
| |
| gid=nginx
| |
| socket=127.0.0.1:26543
| |
| virtualenv=/srv/www/mediagoblin
| |
| chdir=/srv/www/mediagoblin
| |
| ini-paste=/srv/www/mediagoblin/paste.ini
| |
| logto=/srv/www/mediagoblin/mg.log
| |
| </nowiki>}}
| |
|
| |
| Most importantly, chown it to mediagoblin:nginx so that uwsgi will run the service with those permissions.
| |
|
| |
| {{bc|sudo chown mediagoblin:nginx /etc/uwsgi.d/mediagoblin.ini}}
| |
|
| |
| Finally, run the uwsgi Emperor service.
| |
|
| |
| {{bc|sudo systemctl start uwsgi}}
| |
|
| |
| If {{ic|sudo systemctl restart uwsgi}} shows you that {{ic|[emperor] vassal mediagoblin.ini is ready to accept requests}}, then enable the uwsgi service on boot:
| |
|
| |
| {{bc|sudo systemctl enable uwsgi}}
| |
|
| |
|
| === Notes === | | === Notes === |