summaryrefslogtreecommitdiff
path: root/install
diff options
context:
space:
mode:
authorroot2022-05-30 15:59:54 +0200
committerroot2022-05-30 15:59:54 +0200
commit6891a04373daa365c35828ce71e047f5f14486e4 (patch)
tree20e71951c13407f5b7c49f3c9336fd876bbea666 /install
downloadIPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.tar.gz
IPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.tar.bz2
IPFireCustomRules-6891a04373daa365c35828ce71e047f5f14486e4.zip
Beta2: DNS & NTP Redirect To Exernal Working!
Diffstat (limited to 'install')
-rwxr-xr-xinstall28
1 files changed, 28 insertions, 0 deletions
diff --git a/install b/install
new file mode 100755
index 0000000..d16dbfa
--- /dev/null
+++ b/install
@@ -0,0 +1,28 @@
1#!/bin/sh
2
3# backup... tjust in case...
4echo "Backup of firewall.local -> $PWD/data/backups/firewall.$(date +"%Y_%m_%d_%I_%M_%p_%s").local"
5mkdir -p $PWD/data/backups
6cp /etc/sysconfig/firewall.local $PWD/data/backups/firewall.$(date +"%Y_%m_%d_%I_%M_%p_%s").local
7
8# Another backup!
9echo "Backup of firewall.local -> firewall.local.old"
10cp -PL /etc/sysconfig/firewall.local /etc/sysconfig/firewall.local.old
11
12# iterator
13
14if [[ ! -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
20fi
21
22# rules!
23
24if [[ ! -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
28fi