Linux Service Creation: Difference between revisions

From Chorke Wiki
Jump to navigation Jump to search
No edit summary
Line 24: Line 24:
* [https://stackoverflow.com/questions/45374910 How to pass environment variables to a service started by systemd]
* [https://stackoverflow.com/questions/45374910 How to pass environment variables to a service started by systemd]
* [https://taras.codes/blog/hosting-an-asp-net-core-application-on-raspberry-pi-3/ Hosting an ASP.NET Core application on Raspberry Pi 3]
* [https://taras.codes/blog/hosting-an-asp-net-core-application-on-raspberry-pi-3/ Hosting an ASP.NET Core application on Raspberry Pi 3]
* [https://www.baeldung.com/spring-boot-app-as-a-service Spring Boot Application as a Service]
* [https://support.rackspace.com/how-to/checking-running-services-on-linux/ Check running services on Linux]
* [https://support.rackspace.com/how-to/checking-running-services-on-linux/ Check running services on Linux]

Revision as of 10:14, 2 October 2019

Raspbian | Ubuntu | Debian

/etc/systemd/system/demod.service

[Unit]
Description=Academia AMQPD Daemon
 
[Service]
WorkingDirectory=/opt/chorke/academia/amqpd/usr/bin
ExecStart=/opt/chorke/academia/amqpd/usr/bin/amqpd
StandardOutput=syslog
Restart=always
RestartSec=10
User=www-data
KillSignal=SIGINT
SyslogIdentifier=amqpd
Environment=ACADEMIA_HOME=/opt/chorke/academia
Environment=AMQP_HOME=/opt/chorke/academia/amqpd
 
[Install]
WantedBy=multi-user.target

References