Skip to content

Instantly share code, notes, and snippets.

@zhouyl
Created March 22, 2017 01:50
Show Gist options
  • Select an option

  • Save zhouyl/6dd1ce853ca358a245eb9a47d7554ae2 to your computer and use it in GitHub Desktop.

Select an option

Save zhouyl/6dd1ce853ca358a245eb9a47d7554ae2 to your computer and use it in GitHub Desktop.
/etc/systemd/system/rc-local.service
sudo systemctl daemon-reload
sudo systemctl enable rc.local
[Unit]
Description=/etc/rc.local Compatibility
After=network.target
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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment