Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
execute rc.local on boot startup on systemd OS types
#
# file: rc-local.service
# author: Aysad Kozanoglu
# OS types: systemd
#
# Description
# ============
# execute rc.local on boot startup
# systemd-rc-local-generator if /etc/rc.local is executable.
#
# @todo
# vim /etc/systemd/system/rc-local.service
# chmod +x /etc/rc.local
# systemctl enable rc-local systemctl start rc-local.service systemctl status rc-local.service
[Unit]
Description=/etc/rc.local Compatibility
ConditionPathExists=/etc/rc.local
[Service]
Type=forking
ExecStart=/etc/rc.local start
TimeoutSec=0
StandardOutput=tty
RemainAfterExit=yes
SysVStartPriority=99
[Install]
WantedBy=multi-user.target
#!/bin/sh -e
#
# file: rc.local
# author: Aysad Kozanoglu
# OS types: systemd
#
# Description
# ============
# execute rc.local on boot startup
#
# @todo
# vim /etc/systemd/system/rc-local.service
# chmod +x /etc/rc.local
# systemctl enable rc-local systemctl start rc-local.service systemctl status rc-local.service
/bin/mount /dev/sdb /home
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.