systemd rc.local

Published: 2013-02-17
Updated: 2013-02-17

This version runs /etc/rc.local.sh instead of /etc/rc.local, just to avoid conflicting with the real rc.local during the transition. A fair bit of this unit file is probably redundant or unnecessary. I just kept adding stuff until it seemed to run the script, at the end of the boot sequence, to completion, reliably. Put this at /etc/systemd/system/rc-local.service.

[Unit]
Description=/etc/rc.local Compatibility
ConditionFileIsExecutable=/etc/rc.local.sh

[Service]
Type=oneshot
ExecStart=/etc/rc.local.sh
TimeoutSec=0
StandardInput=tty
RemainAfterExit=yes
SysVStartPriority=99

[Install]
WantedBy=multi-user.target