13 lines
338 B
SYSTEMD
13 lines
338 B
SYSTEMD
|
[Unit]
|
||
|
Description=Sentry backup
|
||
|
After=docker.service
|
||
|
|
||
|
[Service]
|
||
|
Type=oneshot
|
||
|
WorkingDirectory=/mnt/data/backup
|
||
|
ExecStartPre=/bin/sh -c 'systemctl -q is-active sentry.service && systemctl stop sentry'
|
||
|
ExecStart=/opt/sentry-util/sentry-util.sh backup
|
||
|
ExecStartPost=/bin/sh -c 'systemctl start sentry'
|
||
|
|
||
|
[Install]
|
||
|
WantedBy=multi-user.target
|