Last active
March 2, 2025 20:11
-
-
Save pdaw/7a1cf6727f6cd23e79195af84be97782 to your computer and use it in GitHub Desktop.
Supervisor running in systemd (it's manually configured because usage of virtualenv, not distribution package)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# activating supervisor service | |
systemctl enable supervisor.service | |
# checking if service is active | |
systemctl is-active supervisor.service | |
# checking service status | |
systemctl status supervisor.service | |
# managing service | |
systemctl start/stop/restart supervisor.service | |
# resources about systemd | |
# http://www.tecmint.com/manage-services-using-systemd-and-systemctl-in-linux/ | |
# https://wiki.archlinux.org/index.php/Systemd | |
# https://www.digitalocean.com/community/tutorials/understanding-systemd-units-and-unit-files |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/systemd/system/supervisor.service | |
[Unit] | |
Description=Supervisor | |
After=syslog.target network.target | |
[Service] | |
ExecStart=/path/to/virtualenv/bin/supervisord --configuration=/path/to/supervisord.conf --logfile=/path/to/log | |
ExecStop=/path/to/virtualenv/bin/supervisorctl shutdown | |
ExecReload=/path/to/virtualenv/bin/supervisorctl reload all | |
Type=forking | |
Restart=always | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://stackoverflow.com/a/67724450/2090870