Create helma.service
Add SystemD unit file with reasonable settings See <https://www.baeldung.com/linux/run-java-application-as-service>
This commit is contained in:
parent
ec67204d51
commit
58d893f044
1 changed files with 23 additions and 0 deletions
23
src/dist/extras/helma.service
vendored
Normal file
23
src/dist/extras/helma.service
vendored
Normal file
|
@ -0,0 +1,23 @@
|
|||
[Unit]
|
||||
Description = Helma Object Publisher
|
||||
After = syslog.target network.target
|
||||
StartLimitIntervalSec = 0
|
||||
|
||||
[Service]
|
||||
Restart = always
|
||||
RestartSec = 1
|
||||
SuccessExitStatus = 143
|
||||
Type = simple
|
||||
WorkingDirectory = /opt/helma
|
||||
|
||||
ExecStart = /usr/bin/java -server \
|
||||
-Dfile.encoding=UTF-8 \
|
||||
-Djava.awt.headless=true \
|
||||
-Xms1024m -Xmx2048m \
|
||||
-jar launcher.jar \
|
||||
-w 8080 -x 8081
|
||||
|
||||
ExecStop = /bin/kill -15 $MAINPID
|
||||
|
||||
[Install]
|
||||
WantedBy = multi-user.target
|
Loading…
Add table
Reference in a new issue