systemd: use SIGUSR2 for shutdown, for LDM

This commit is contained in:
Phil Pennock
2023-09-28 13:16:48 -04:00
parent 9c96576066
commit 47db17a4c8
2 changed files with 6 additions and 0 deletions

View File

@@ -9,6 +9,9 @@ ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s SIGINT $MAINPID ExecStop=/bin/kill -s SIGINT $MAINPID
User=nats User=nats
Group=nats Group=nats
# The nats-server uses SIGUSR2 to trigger using Lame Duck Mode (LDM) shutdown
KillSignal=SIGUSR2
# You might want to adjust TimeoutStopSec too.
# Hardening # Hardening
CapabilityBoundingSet= CapabilityBoundingSet=

View File

@@ -10,6 +10,9 @@ ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s SIGINT $MAINPID ExecStop=/bin/kill -s SIGINT $MAINPID
User=nats User=nats
Group=nats Group=nats
# The nats-server uses SIGUSR2 to trigger using Lame Duck Mode (LDM) shutdown
KillSignal=SIGUSR2
# You might want to adjust TimeoutStopSec too.
[Install] [Install]
WantedBy=multi-user.target WantedBy=multi-user.target