Last active
August 7, 2024 08:45
-
-
Save NotYusta/0d669bd57bfc67a56c8f1f18941a2b9a to your computer and use it in GitHub Desktop.
RC Local
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if ! grep -q "bash /root/firewall.sh" "/etc/rc.local"; then | |
echo 'bash /root/firewall.sh' | sudo tee -a /etc/rc.local | |
fi | |
chmod +x /etc/rc.d/rc.local | |
sleep 1s | |
systemctl enable rc-local --now |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment