# For more details on writing a service, see: # https://linuxconfig.org/how-to-create-systemd-service-unit-in-linux # [Unit] Description=Greenstone3 Digital Library Server After=network.target [Service] Type=forking User=www-data TimeoutStartSec=180 TimeoutStopSec=240 ExecStart=/usr/bin/env bash @GSDL3SRCHOME@/service.d/greenstone3-start.sh ExecStop=/usr/bin/env bash @GSDL3SRCHOME@/service.d/greenstone3-stop.sh # # If using 'Restart' directive, read the following to avoid some common pitfalls # https://medium.com/@benmorel/creating-a-linux-service-with-systemd-611b5c8b91d6 # Restart=on-failure # Other restart options: always, on-abort, etc # The install section is needed to use `systemctl enable` to start on boot # For a user service that you want to enable and start automatically, use `default.target` # For system level services, use `multi-user.target` # [Install] WantedBy=multi-user.target