Ubuntu 16.04 is using systemd so you can use this doc to start gunicorn: http://docs.gunicorn.org/en/stable/deploy.html#systemd
This is working for me: vi /etc/systemd/system/gunicorn.service [Unit] Description=gunicorn daemon Requires=gunicorn.socket nginx.service docker-postgres_server.service docker-redis_server.service Before=nginx.service After=postgresql.service docker-redis_server.service [Service] PIDFile=/var/run/gunicorn.pid User=mayanuser Group=www-data WorkingDirectory=/home/mayanuser/pythonenvs/mayan ExecStart=/home/mayanuser/pythonenvs/mayan/bin/gunicorn --workers 5 mayan.wsgi:application ExecReload=/bin/kill -s HUP $MAINPID ExecStop=/bin/kill -s TERM $MAINPID PrivateTmp=true [Install] WantedBy=multi-user.target ---------------------------------- vi /etc/systemd/system/gunicorn.socket [Unit] Description=gunicorn socket [Socket] ListenStream=/run/gunicorn/socket #ListenStream=0.0.0.0:9000 #ListenStream=[::]:8000 [Install] WantedBy=sockets.target ------------------------------------------- systemctl start gunicorn systemctl stop gunicorn see: http://www.dynacont.net/documentation/linux/Useful_SystemD_commands/ br Matthias ----------------------------------- Am Sonntag, 13. November 2016 17:47:05 UTC+1 schrieb Hans Fritz: > > I have setup Mayan on an Ubuntu 16.04 VM, as per the instructions for > deploying on bare metal. > > It all works fine, except that I have to manually enter > `/etc/init.d/supervisor start` every time the VM boots to have Mayan > running. NGINX seems fine, because it returns a 502 bad gateway until I > manually start Mayan. > > How do I get Mayan to automatically start after the machine is booted and > NFS mounts are ready? > -- --- You received this message because you are subscribed to the Google Groups "Mayan EDMS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
