1
0
mirror of https://github.com/etesync/server synced 2024-11-18 06:48:08 +00:00
etesync-server/example-configs/nginx-uwsgi
2019-10-03 00:03:31 +03:00
..
etesync.ini Add example config for using using nginx with uwsgi 2018-11-06 20:48:46 +00:00
my.server.name.conf added missing closing bracket 2019-10-03 00:03:31 +03:00
readme.md Add example config for using using nginx with uwsgi 2018-11-06 20:48:46 +00:00
uwsgi.service Add example config for using using nginx with uwsgi 2018-11-06 20:48:46 +00:00

Running etesync under nginx and uwsgi

This configuration assumes that etesync server has been installed in the home folder of a non privileged user called EtesyncUser following the instructions in https://github.com/etesync/server-skeleton. Also that static files have been collected at /srv/http/etesync_server by running the following commands:

sudo mkdir -p /srv/http/etesync_server/static
sudo chown -R EtesyncUser /srv/http/etesync_server
sudo su EtesyncUser
cd /path/to/etesync
ln -s /srv/http/etesync_server/static static
./manage.py collectstatic

It is also assumed that nginx and uwsgi have been installed system wide by root, and that nginx is running as user/group www-data.

In this setup, uwsgi running as a systemd service as root creates a unix socket with read-write access to both EtesyncUser and nginx. It then drops its root privilege and runs etesync as EtesyncUser.

nginx listens on the https port (or a non standard port https port if desired), delivers static pages directly and for everything else, communicates with etesync over the unix socket.