-
Notifications
You must be signed in to change notification settings - Fork 141
rc.local
holishing edited this page Dec 10, 2018
·
3 revisions
為了讓開機的時候會自己把 bbs (以及所須要的程式) 跑起來,
如果使用 Linux,要讓開機後程式自動開啟,則也可以使用 rc.local
或類似系統服務
若您使用 FreeBSD, 您可以將 sample/pttbbs.sh 拷貝到 /usr/local/etc/rc.d/
之後您可以重新開機試試看是不是在重開後可以正常運作 :)
部分 Linux 發行版可能先記得開啟rc.local
等相關服務:
-root- # systemctl enable rc-local
-root- # systemctl start rc-local.service
然後自行建立 /etc/rc.local
檔案,寫進你要啟動 CurrentPtt 相關的腳本,最後一行記得加上 exit 0
記得利用 chmod
等指令讓它可以被執行
-root- # chmod u+x /etc/rc.local
to do: 記錄如何在 Linux 下直接改用 systemd unit 啟動相關服務