From bc6a23bdaa73bd984d247930de680ac893a9c8c3 Mon Sep 17 00:00:00 2001 From: teastep Date: Sat, 3 Jun 2006 15:50:05 +0000 Subject: [PATCH] Fix install script -- take 3 git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@3976 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb --- Shorewall-lite/install.sh | 285 -------------------------------------- 1 file changed, 285 deletions(-) diff --git a/Shorewall-lite/install.sh b/Shorewall-lite/install.sh index 1d0ac4a14..3f8c0b530 100755 --- a/Shorewall-lite/install.sh +++ b/Shorewall-lite/install.sh @@ -287,286 +287,6 @@ install_file help ${PREFIX}/usr/share/shorewall/help 0544 echo "Help command executor installed in ${PREFIX}/usr/share/shorewall/help" -# -# Install the policy file -# -if [ ! -f ${PREFIX}/etc/shorewall/policy ]; then - run_install $OWNERSHIP -m 0600 policy ${PREFIX}/etc/shorewall/policy - echo "Policy file installed as ${PREFIX}/etc/shorewall/policy" -fi -# -# Install the interfaces file -# -if [ ! -f ${PREFIX}/etc/shorewall/interfaces ]; then - run_install $OWNERSHIP -m 0600 interfaces ${PREFIX}/etc/shorewall/interfaces - echo "Interfaces file installed as ${PREFIX}/etc/shorewall/interfaces" -fi -# -# Install the ipsec file -# -if [ ! -f ${PREFIX}/etc/shorewall/ipsec ]; then - run_install $OWNERSHIP -m 0600 ipsec ${PREFIX}/etc/shorewall/ipsec - echo "Dummy IPSEC file installed as ${PREFIX}/etc/shorewall/ipsec" -fi - -# -# Install the hosts file -# -if [ ! -f ${PREFIX}/etc/shorewall/hosts ]; then - run_install $OWNERSHIP -m 0600 hosts ${PREFIX}/etc/shorewall/hosts - echo "Hosts file installed as ${PREFIX}/etc/shorewall/hosts" -fi -# -# Install the rules file -# -if [ ! -f ${PREFIX}/etc/shorewall/rules ]; then - run_install $OWNERSHIP -m 0600 rules ${PREFIX}/etc/shorewall/rules - echo "Rules file installed as ${PREFIX}/etc/shorewall/rules" -fi -# -# Install the NAT file -# -if [ ! -f ${PREFIX}/etc/shorewall/nat ]; then - run_install $OWNERSHIP -m 0600 nat ${PREFIX}/etc/shorewall/nat - echo "NAT file installed as ${PREFIX}/etc/shorewall/nat" -fi -# -# Install the NETMAP file -# -if [ ! -f ${PREFIX}/etc/shorewall/netmap ]; then - run_install $OWNERSHIP -m 0600 netmap ${PREFIX}/etc/shorewall/netmap - echo "NETMAP file installed as ${PREFIX}/etc/shorewall/netmap" -fi -# -# Install the Parameters file -# -if [ ! -f ${PREFIX}/etc/shorewall/params ]; then - run_install $OWNERSHIP -m 0600 params ${PREFIX}/etc/shorewall/params - echo "Parameter file installed as ${PREFIX}/etc/shorewall/params" -fi -# -# Install the proxy ARP file -# -if [ ! -f ${PREFIX}/etc/shorewall/proxyarp ]; then - run_install $OWNERSHIP -m 0600 proxyarp ${PREFIX}/etc/shorewall/proxyarp - echo "Proxy ARP file installed as ${PREFIX}/etc/shorewall/proxyarp" -fi -# -# Install the Stopped Routing file -# -if [ ! -f ${PREFIX}/etc/shorewall/routestopped ]; then - run_install $OWNERSHIP -m 0600 routestopped ${PREFIX}/etc/shorewall/routestopped - echo "Stopped Routing file installed as ${PREFIX}/etc/shorewall/routestopped" -fi -# -# Install the Mac List file -# -if [ ! -f ${PREFIX}/etc/shorewall/maclist ]; then - run_install $OWNERSHIP -m 0600 maclist ${PREFIX}/etc/shorewall/maclist - echo "MAC list file installed as ${PREFIX}/etc/shorewall/maclist" -fi -# -# Install the Masq file -# -if [ ! -f ${PREFIX}/etc/shorewall/masq ]; then - run_install $OWNERSHIP -m 0600 masq ${PREFIX}/etc/shorewall/masq - echo "Masquerade file installed as ${PREFIX}/etc/shorewall/masq" -fi -# -# Install the Modules file -# -if [ ! -f ${PREFIX}/etc/shorewall/modules ]; then - run_install $OWNERSHIP -m 0600 modules ${PREFIX}/etc/shorewall/modules - echo "Modules file installed as ${PREFIX}/etc/shorewall/modules" -fi -# -# Install the TC Rules file -# -if [ ! -f ${PREFIX}/etc/shorewall/tcrules ]; then - run_install $OWNERSHIP -m 0600 tcrules ${PREFIX}/etc/shorewall/tcrules - echo "TC Rules file installed as ${PREFIX}/etc/shorewall/tcrules" -fi - -# -# Install the TOS file -# -if [ ! -f ${PREFIX}/etc/shorewall/tos ]; then - run_install $OWNERSHIP -m 0600 tos ${PREFIX}/etc/shorewall/tos - echo "TOS file installed as ${PREFIX}/etc/shorewall/tos" -fi -# -# Install the Tunnels file -# -if [ ! -f ${PREFIX}/etc/shorewall/tunnels ]; then - run_install $OWNERSHIP -m 0600 tunnels ${PREFIX}/etc/shorewall/tunnels - echo "Tunnels file installed as ${PREFIX}/etc/shorewall/tunnels" -fi -# -# Install the blacklist file -# -if [ ! -f ${PREFIX}/etc/shorewall/blacklist ]; then - run_install $OWNERSHIP -m 0600 blacklist ${PREFIX}/etc/shorewall/blacklist - echo "Blacklist file installed as ${PREFIX}/etc/shorewall/blacklist" -fi -# -# Delete the Routes file -# -delete_file ${PREFIX}/etc/shorewall/routes -# -# Delete the tcstart file -# - -delete_file ${PREFIX}/usr/share/shorewall/tcstart - -# -# Install the Providers file -# -if [ ! -f ${PREFIX}/etc/shorewall/providers ]; then - run_install $OWNERSHIP -m 0600 providers ${PREFIX}/etc/shorewall/providers - echo "Providers file installed as ${PREFIX}/etc/shorewall/providers" -fi - -# -# Install the Route Rules file -# -if [ ! -f ${PREFIX}/etc/shorewall/route_rules ]; then - run_install $OWNERSHIP -m 0600 route_rules ${PREFIX}/etc/shorewall/route_rules - echo "Routing rules file installed as ${PREFIX}/etc/shorewall/route_rules" -fi - -# -# Install the tcclasses file -# -if [ ! -f ${PREFIX}/etc/shorewall/tcclasses ]; then - run_install $OWNERSHIP -m 0600 tcclasses ${PREFIX}/etc/shorewall/tcclasses - echo "TC Classes file installed as ${PREFIX}/etc/shorewall/tcclasses" -fi - -# -# Install the tcdevices file -# -if [ ! -f ${PREFIX}/etc/shorewall/tcdevices ]; then - run_install $OWNERSHIP -m 0600 tcdevices ${PREFIX}/etc/shorewall/tcdevices - echo "TC Devices file installed as ${PREFIX}/etc/shorewall/tcdevices" -fi - -# -# Install the rfc1918 file -# -install_file rfc1918 ${PREFIX}/usr/share/shorewall/rfc1918 0600 -echo "RFC 1918 file installed as ${PREFIX}/usr/share/shorewall/rfc1918" -# -# Install the default config path file -# -install_file configpath ${PREFIX}/usr/share/shorewall/configpath 0600 -echo "Default config path file installed as ${PREFIX}/usr/share/shorewall/configpath" -# -# Install the init file -# -if [ ! -f ${PREFIX}/etc/shorewall/init ]; then - run_install $OWNERSHIP -m 0600 init ${PREFIX}/etc/shorewall/init - echo "Init file installed as ${PREFIX}/etc/shorewall/init" -fi -# -# Install the initdone file -# -if [ ! -f ${PREFIX}/etc/shorewall/initdone ]; then - run_install $OWNERSHIP -m 0600 initdone ${PREFIX}/etc/shorewall/initdone - echo "Initdone file installed as ${PREFIX}/etc/shorewall/initdone" -fi -# -# Install the start file -# -if [ ! -f ${PREFIX}/etc/shorewall/start ]; then - run_install $OWNERSHIP -m 0600 start ${PREFIX}/etc/shorewall/start - echo "Start file installed as ${PREFIX}/etc/shorewall/start" -fi -# -# Install the stop file -# -if [ ! -f ${PREFIX}/etc/shorewall/stop ]; then - run_install $OWNERSHIP -m 0600 stop ${PREFIX}/etc/shorewall/stop - echo "Stop file installed as ${PREFIX}/etc/shorewall/stop" -fi -# -# Install the stopped file -# -if [ ! -f ${PREFIX}/etc/shorewall/stopped ]; then - run_install $OWNERSHIP -m 0600 stopped ${PREFIX}/etc/shorewall/stopped - echo "Stopped file installed as ${PREFIX}/etc/shorewall/stopped" -fi -# -# Install the ECN file -# -if [ ! -f ${PREFIX}/etc/shorewall/ecn ]; then - run_install $OWNERSHIP -m 0600 ecn ${PREFIX}/etc/shorewall/ecn - echo "ECN file installed as ${PREFIX}/etc/shorewall/ecn" -fi -# -# Install the Accounting file -# -if [ ! -f ${PREFIX}/etc/shorewall/accounting ]; then - run_install $OWNERSHIP -m 0600 accounting ${PREFIX}/etc/shorewall/accounting - echo "Accounting file installed as ${PREFIX}/etc/shorewall/accounting" -fi -# -# Install the Continue file -# -if [ ! -f ${PREFIX}/etc/shorewall/continue ]; then - run_install $OWNERSHIP -m 0600 continue ${PREFIX}/etc/shorewall/continue - echo "Continue file installed as ${PREFIX}/etc/shorewall/continue" -fi -# -# Install the Started file -# -if [ ! -f ${PREFIX}/etc/shorewall/started ]; then - run_install $OWNERSHIP -m 0600 started ${PREFIX}/etc/shorewall/started - echo "Started file installed as ${PREFIX}/etc/shorewall/started" -fi -# -# Install the Standard Actions file -# -install_file actions.std ${PREFIX}/usr/share/shorewall/actions.std 0644 -echo "Standard actions file installed as ${PREFIX}/etc/shorewall/actions.std" - -# -# Install the Actions file -# -if [ ! -f ${PREFIX}/etc/shorewall/actions ]; then - run_install $OWNERSHIP -m 0644 actions ${PREFIX}/etc/shorewall/actions - echo "Actions file installed as ${PREFIX}/etc/shorewall/actions" -fi - -# -# Install the Makefile -# -run_install $OWNERSHIP -m 0600 Makefile ${PREFIX}/etc/shorewall/Makefile -echo "Makefile installed as ${PREFIX}/etc/shorewall/Makefile" - -# -# Install the Action files -# -for f in action.* ; do - install_file $f ${PREFIX}/usr/share/shorewall/$f 0644 - echo "Action ${f#*.} file installed as ${PREFIX}/usr/share/shorewall/$f" -done - -install_file Limit ${PREFIX}/usr/share/shorewall/Limit 0600 -echo "Limit action extension script installed as ${PREFIX}/usr/share/shorewall/Limit" -# -# Install the Macro files -# -for f in macro.* ; do - install_file $f ${PREFIX}/usr/share/shorewall/$f 0644 - echo "Macro ${f#*.} file installed as ${PREFIX}/usr/share/shorewall/$f" -done -# -# Install the program skeleton files -# -for f in prog.* ; do - install_file $f ${PREFIX}/usr/share/shorewall/$f 0644 - echo "Program skeleton file ${f#*.} installed as ${PREFIX}/usr/share/shorewall/$f" -done # # Create the version file # @@ -581,11 +301,6 @@ if [ -z "$PREFIX" ]; then ln -s ${DEST}/${INIT} /usr/share/shorewall/init fi -# -# Install the firewall script -# -install_file firewall ${PREFIX}/usr/share/shorewall/firewall 0544 - if [ -z "$PREFIX" -a -n "$first_install" ]; then if [ -n "$DEBIAN" ]; then run_install $OWNERSHIP -m 0644 default.debian /etc/default/shorewall