summaryrefslogtreecommitdiff
blob: 289aae0df0b1d6d899ca7a6cb51928e49db93139 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
[Unit]
Description=Gracefully restart the box
Documentation=man:kexec(8)
After=boot.mount
Before=shutdown.target umount.target final.target
ConditionPathExists=!/nokexec

[Service]
Type=oneshot
RemainAfterExit=yes
EnvironmentFile=/etc/kexec.conf
ExecStart=/usr/sbin/kexec -l /boot/${KNAME} ${KEXEC_OPT_ARGS}
ExecStop=/usr/sbin/kexec -l /boot/${KNAME} ${KEXEC_OPT_ARGS}

[Install]
WantedBy=multi-user.target