diff options
author | root | 2022-05-30 15:59:54 +0200 |
---|---|---|
committer | root | 2022-05-30 15:59:54 +0200 |
commit | 6891a04373daa365c35828ce71e047f5f14486e4 (patch) | |
tree | 20e71951c13407f5b7c49f3c9336fd876bbea666 /install | |
download | IPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.tar.gz IPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.tar.bz2 IPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.zip |
Beta2: DNS & NTP Redirect To Exernal Working!
Diffstat (limited to 'install')
-rwxr-xr-x | install | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -0,0 +1,28 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | # backup... tjust in case... | ||
4 | echo "Backup of firewall.local -> $PWD/data/backups/firewall.$(date +"%Y_%m_%d_%I_%M_%p_%s").local" | ||
5 | mkdir -p $PWD/data/backups | ||
6 | cp /etc/sysconfig/firewall.local $PWD/data/backups/firewall.$(date +"%Y_%m_%d_%I_%M_%p_%s").local | ||
7 | |||
8 | # Another backup! | ||
9 | echo "Backup of firewall.local -> firewall.local.old" | ||
10 | cp -PL /etc/sysconfig/firewall.local /etc/sysconfig/firewall.local.old | ||
11 | |||
12 | # iterator | ||
13 | |||
14 | if [[ ! -L "/etc/sysconfig/firewall.local" ]] ; then | ||
15 | echo "Linking IPFire Custom Firewall Rules Looper" | ||
16 | echo "Installing $PWD/data/executable/firewall.local -> /etc/sysconfig/firewall.local" | ||
17 | rm /etc/sysconfig/firewall.local | ||
18 | cp $PWD/data/originals/firewall.looper $PWD/data/run/firewall.local | ||
19 | ln -s $PWD/data/run/firewall.local /etc/sysconfig/firewall.local | ||
20 | fi | ||
21 | |||
22 | # rules! | ||
23 | |||
24 | if [[ ! -L "/etc/sysconfig/rules.d" ]] ; then | ||
25 | echo "Linking IPFire Custom Firewall Rules" | ||
26 | echo "Installing $PWD/rules.d/ -> /etc/sysconfig/rules.d" | ||
27 | ln -s $PWD/rules.d /etc/sysconfig/rules.d | ||
28 | fi | ||