mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-28 11:43:25 +02:00
Geändert:
* CONFIG_ROOT in den Scripts angepasst auf /var/ipfire * Zwei führende "/" in den ROOTFILES entfernt. git-svn-id: http://svn.ipfire.org/svn/ipfire/trunk@134 ea5c0bd1-69bd-2848-81d8-4f18e57aeed8
This commit is contained in:
@@ -26421,5 +26421,5 @@ usr/sbin/visudo
|
|||||||
##
|
##
|
||||||
## pakfire
|
## pakfire
|
||||||
##
|
##
|
||||||
/opt/pakfire
|
opt/pakfire
|
||||||
/etc/pakfire.conf
|
etc/pakfire.conf
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
# commands to run to set these as shell environment variables, it is
|
# commands to run to set these as shell environment variables, it is
|
||||||
# intended to be used as follows:
|
# intended to be used as follows:
|
||||||
#
|
#
|
||||||
# eval $(readhash /var/ipcop/main/settings)
|
# eval $(readhash /var/ipfire/main/settings)
|
||||||
#
|
#
|
||||||
|
|
||||||
# shell variables must consist of alphanumeric characters and underscores,
|
# shell variables must consist of alphanumeric characters and underscores,
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -25,15 +25,15 @@ else
|
|||||||
/etc/httpd/conf/httpd.conf
|
/etc/httpd/conf/httpd.conf
|
||||||
|
|
||||||
/bin/sed -i -e "s+:[0-9]\{3,5\}/\$ENV{'PATH_INFO'}+:$HTTPS/\$ENV{'PATH_INFO'}+" \
|
/bin/sed -i -e "s+:[0-9]\{3,5\}/\$ENV{'PATH_INFO'}+:$HTTPS/\$ENV{'PATH_INFO'}+" \
|
||||||
/var/ipcop/header.pl
|
/var/ipfire/header.pl
|
||||||
|
|
||||||
/bin/sed -i -e "s+acl IPFire_https port.*$+acl IPCop_https port $HTTPS+" \
|
/bin/sed -i -e "s+acl IPFire_https port.*$+acl IPCop_https port $HTTPS+" \
|
||||||
/var/ipcop/proxy/acl
|
/var/ipfire/proxy/acl
|
||||||
/bin/chown nobody:nobody /var/ipcop/proxy/acl
|
/bin/chown nobody:nobody /var/ipfire/proxy/acl
|
||||||
|
|
||||||
/bin/sed -i -e "s+acl IPFire_https port.*$+acl IPCop_https port $HTTPS+" \
|
/bin/sed -i -e "s+acl IPFire_https port.*$+acl IPCop_https port $HTTPS+" \
|
||||||
/var/ipcop/proxy/squid.conf
|
/var/ipfire/proxy/squid.conf
|
||||||
/bin/chown nobody:nobody /var/ipcop/proxy/squid.conf
|
/bin/chown nobody:nobody /var/ipfire/proxy/squid.conf
|
||||||
|
|
||||||
# restart everything impacted
|
# restart everything impacted
|
||||||
/bin/killall httpd
|
/bin/killall httpd
|
||||||
|
|||||||
@@ -12,64 +12,64 @@
|
|||||||
# /usr/local/bin/settime
|
# /usr/local/bin/settime
|
||||||
|
|
||||||
ongreen=1
|
ongreen=1
|
||||||
green=$(cat /var/ipcop/ethernet/settings | grep GREEN_NETADDRESS)
|
green=$(cat /var/ipfire/ethernet/settings | grep GREEN_NETADDRESS)
|
||||||
if [ -z "$green" ]; then
|
if [ -z "$green" ]; then
|
||||||
: # no Green subnet
|
: # no Green subnet
|
||||||
else
|
else
|
||||||
green=${green##*=}; green="${green%.*}.[0-9]"
|
green=${green##*=}; green="${green%.*}.[0-9]"
|
||||||
if [ -n "$(cat /var/ipcop/time/settime.conf | grep $green)" ]; then
|
if [ -n "$(cat /var/ipfire/time/settime.conf | grep $green)" ]; then
|
||||||
ongreen=0 # NTP on Green
|
ongreen=0 # NTP on Green
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
onorange=1
|
onorange=1
|
||||||
orange=$(cat /var/ipcop/ethernet/settings | grep ORANGE_NETADDRESS)
|
orange=$(cat /var/ipfire/ethernet/settings | grep ORANGE_NETADDRESS)
|
||||||
if [ -z "$orange" ]; then
|
if [ -z "$orange" ]; then
|
||||||
: # no Orange subnet
|
: # no Orange subnet
|
||||||
else
|
else
|
||||||
orange=${orange##*=}; orange="${orange%.*}.[0-9]"
|
orange=${orange##*=}; orange="${orange%.*}.[0-9]"
|
||||||
if [ -n "$(cat /var/ipcop/time/settime.conf | grep $orange)" ]; then
|
if [ -n "$(cat /var/ipfire/time/settime.conf | grep $orange)" ]; then
|
||||||
onorange=0 # NTP on Orange
|
onorange=0 # NTP on Orange
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# find out language
|
# find out language
|
||||||
tlanguage=$(cat /var/ipcop/main/settings | grep LANGUAGE)
|
tlanguage=$(cat /var/ipfire/main/settings | grep LANGUAGE)
|
||||||
tlanguage=${tlanguage##*=}
|
tlanguage=${tlanguage##*=}
|
||||||
|
|
||||||
if [ -n "$1" ]; then
|
if [ -n "$1" ]; then
|
||||||
if [ -e /var/ipcop/red/active ] || [ "$ongreen" -eq 0 ] || [ "$onorange" -eq 0 ]; then
|
if [ -e /var/ipfire/red/active ] || [ "$ongreen" -eq 0 ] || [ "$onorange" -eq 0 ]; then
|
||||||
/usr/bin/ntpdate -su $1 $2
|
/usr/bin/ntpdate -su $1 $2
|
||||||
ntpdatetest=$?
|
ntpdatetest=$?
|
||||||
|
|
||||||
if [ "$ntpdatetest" -eq 0 ]; then
|
if [ "$ntpdatetest" -eq 0 ]; then
|
||||||
case $tlanguage in
|
case $tlanguage in
|
||||||
en ) date "+%X %Z on %d %B %Y" > /var/ipcop/time/lastset ;
|
en ) date "+%X %Z on %d %B %Y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synchronisation event" ;;
|
logger -t ipcop "NTP synchronisation event" ;;
|
||||||
da ) date "+%k:%M:%S på %d/%m/%y" > /var/ipcop/time/lastset ;
|
da ) date "+%k:%M:%S på %d/%m/%y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synkronisering" ;;
|
logger -t ipcop "NTP synkronisering" ;;
|
||||||
de ) date "+%X Uhr am %d.%m.%Y" > /var/ipcop/time/lastset ;
|
de ) date "+%X Uhr am %d.%m.%Y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP Synchronisierung" ;;
|
logger -t ipcop "NTP Synchronisierung" ;;
|
||||||
fr ) date "+%X le %e/%m/%y" > /var/ipcop/time/lastset ;
|
fr ) date "+%X le %e/%m/%y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "synchronisation NTP" ;;
|
logger -t ipcop "synchronisation NTP" ;;
|
||||||
it ) date "+%X il %d-%m-%Y" > /var/ipcop/time/lastset ;
|
it ) date "+%X il %d-%m-%Y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "sincronizzazione NTP" ;;
|
logger -t ipcop "sincronizzazione NTP" ;;
|
||||||
nl ) date "+%X %e-%m-%Y" > /var/ipcop/time/lastset ;
|
nl ) date "+%X %e-%m-%Y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synchronisatie" ;;
|
logger -t ipcop "NTP synchronisatie" ;;
|
||||||
no ) date "+%X på %d-%m-%y" > /var/ipcop/time/lastset ;
|
no ) date "+%X på %d-%m-%y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synkronisering" ;;
|
logger -t ipcop "NTP synkronisering" ;;
|
||||||
sv ) date "+%H.%M.%S på %y-%m-%d" > /var/ipcop/time/lastset ;
|
sv ) date "+%H.%M.%S på %y-%m-%d" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synkronisering" ;;
|
logger -t ipcop "NTP synkronisering" ;;
|
||||||
es ) date "+%X %e/%-m/%y" > /var/ipcop/time/lastset ;
|
es ) date "+%X %e/%-m/%y" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP sincronizado" ;;
|
logger -t ipcop "NTP sincronizado" ;;
|
||||||
* ) date "+%X %Z, %Y-%m-%d" > /var/ipcop/time/lastset ;
|
* ) date "+%X %Z, %Y-%m-%d" > /var/ipfire/time/lastset ;
|
||||||
logger -t ipcop "NTP synchronisation" ;;
|
logger -t ipcop "NTP synchronisation" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
/sbin/hwclock --systohc
|
/sbin/hwclock --systohc
|
||||||
rm -f /var/ipcop/time/settimenow
|
rm -f /var/ipfire/time/settimenow
|
||||||
# reset counter variable
|
# reset counter variable
|
||||||
cp /var/ipcop/time/counter.conf /var/ipcop/time/counter
|
cp /var/ipfire/time/counter.conf /var/ipfire/time/counter
|
||||||
else
|
else
|
||||||
case $tlanguage in
|
case $tlanguage in
|
||||||
de ) logger -t ipcop "ntpdate fehlerhaft" ;;
|
de ) logger -t ipcop "ntpdate fehlerhaft" ;;
|
||||||
|
|||||||
@@ -10,26 +10,26 @@
|
|||||||
#
|
#
|
||||||
# /usr/local/bin/timecheck
|
# /usr/local/bin/timecheck
|
||||||
|
|
||||||
if [ -e /var/ipcop/time/enable ]; then
|
if [ -e /var/ipfire/time/enable ]; then
|
||||||
if [ $(cat /var/ipcop/time/settings | grep period) ] && [ -e /var/ipcop/time/counter ]; then
|
if [ $(cat /var/ipfire/time/settings | grep period) ] && [ -e /var/ipfire/time/counter ]; then
|
||||||
if [ $(cat /var/ipcop/time/counter) -gt 0 ]; then
|
if [ $(cat /var/ipfire/time/counter) -gt 0 ]; then
|
||||||
echo $(($(cat /var/ipcop/time/counter)-5)) > /var/ipcop/time/counter
|
echo $(($(cat /var/ipfire/time/counter)-5)) > /var/ipfire/time/counter
|
||||||
else
|
else
|
||||||
touch /var/ipcop/time/settimenow
|
touch /var/ipfire/time/settimenow
|
||||||
rm -f /var/ipcop/time/counter
|
rm -f /var/ipfire/time/counter
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
# EAO added 2003-08-14 for v1.3.1
|
# EAO added 2003-08-14 for v1.3.1
|
||||||
# if settings are restored from a backup
|
# if settings are restored from a backup
|
||||||
# /var/ipcop/time/counter will not exist
|
# /var/ipfire/time/counter will not exist
|
||||||
if [ $(cat /var/ipcop/time/settings | grep periodic) ]; then
|
if [ $(cat /var/ipfire/time/settings | grep periodic) ]; then
|
||||||
touch /var/ipcop/time/settimenow
|
touch /var/ipfire/time/settimenow
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -e /var/ipcop/time/settimenow ]; then
|
if [ -e /var/ipfire/time/settimenow ]; then
|
||||||
if [ -e /var/ipcop/time/settime.conf ]; then
|
if [ -e /var/ipfire/time/settime.conf ]; then
|
||||||
/usr/local/bin/settime $(cat /var/ipcop/time/settime.conf)
|
/usr/local/bin/settime $(cat /var/ipfire/time/settime.conf)
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ UPGRADEVERSION="1.4.x" # configured by ./make.sh newupdate
|
|||||||
PREVIOUSVERSION="1.4."$((`echo $UPGRADEVERSION | /usr/bin/cut -f3 -d '.'`-1))
|
PREVIOUSVERSION="1.4."$((`echo $UPGRADEVERSION | /usr/bin/cut -f3 -d '.'`-1))
|
||||||
echo "This is the $UPGRADEVERSION update patch for IPCop $PREVIOUSVERSION installing."
|
echo "This is the $UPGRADEVERSION update patch for IPCop $PREVIOUSVERSION installing."
|
||||||
|
|
||||||
CURRENTVERSION=`perl -e "require '/var/ipcop/general-functions.pl';print \\$General::version;"`
|
CURRENTVERSION=`perl -e "require '/var/ipfire/general-functions.pl';print \\$General::version;"`
|
||||||
if [ "$CURRENTVERSION" != "$PREVIOUSVERSION" ]; then
|
if [ "$CURRENTVERSION" != "$PREVIOUSVERSION" ]; then
|
||||||
echo "You are not running IPCop v$PREVIOUSVERSION for this patch to install."
|
echo "You are not running IPCop v$PREVIOUSVERSION for this patch to install."
|
||||||
echo "Aborting installation."
|
echo "Aborting installation."
|
||||||
@@ -12,12 +12,12 @@ if [ "$CURRENTVERSION" != "$PREVIOUSVERSION" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# general-functions might not be overwrited by patch...
|
# general-functions might not be overwrited by patch...
|
||||||
/bin/sed -i -e "s+= '1.4.*$+= '$UPGRADEVERSION';+" /var/ipcop/general-functions.pl
|
/bin/sed -i -e "s+= '1.4.*$+= '$UPGRADEVERSION';+" /var/ipfire/general-functions.pl
|
||||||
|
|
||||||
/bin/tar -zxpf patch.tar.gz -C /
|
/bin/tar -zxpf patch.tar.gz -C /
|
||||||
|
|
||||||
#build cachelang file after all "lang/*.pl" updates
|
#build cachelang file after all "lang/*.pl" updates
|
||||||
perl -e "require '/var/ipcop/lang.pl'; &Lang::BuildCacheLang"
|
perl -e "require '/var/ipfire/lang.pl'; &Lang::BuildCacheLang"
|
||||||
|
|
||||||
killall mingetty #redisplay correct version
|
killall mingetty #redisplay correct version
|
||||||
echo "end of $UPGRADEVERSION update"
|
echo "end of $UPGRADEVERSION update"
|
||||||
|
|||||||
Reference in New Issue
Block a user