projects
/
carnet-upgrade.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b880e5f
)
Cleanup amavis upgrade.
author
Valentin Vidic
<Valentin.Vidic@CARNet.hr>
Mon, 13 Jun 2011 14:20:33 +0000
(16:20 +0200)
committer
Valentin Vidic
<Valentin.Vidic@CARNet.hr>
Mon, 13 Jun 2011 14:20:33 +0000
(16:20 +0200)
src/functions.sh
patch
|
blob
|
history
diff --git
a/src/functions.sh
b/src/functions.sh
index
bdb78e9
..
26d4014
100644
(file)
--- a/
src/functions.sh
+++ b/
src/functions.sh
@@
-1050,14
+1050,6
@@
upgrade_apache2 () {
upgrade_amavis () {
local conf
upgrade_amavis () {
local conf
- # remove init script diversion before upgrade
- if pkg amavisd-cn lt 3:2.6.1-1; then
- if [ -L /etc/init.d/amavis -a -f /etc/init.d/amavis.amavisd-new ]; then
- rm -vf /etc/init.d/amavis
- dpkg-divert --remove /etc/init.d/amavis
- fi
- fi
-
# move old config aside
for conf in /etc/amavisd.conf /etc/amavis/amavisd.conf; do
if [ -e $conf -a ! -e $conf.$backup_ext ]; then
# move old config aside
for conf in /etc/amavisd.conf /etc/amavis/amavisd.conf; do
if [ -e $conf -a ! -e $conf.$backup_ext ]; then
@@
-1068,18
+1060,8
@@
upgrade_amavis () {
# install new packages
pkgadd amavisd-cn amavisd-new
# install new packages
pkgadd amavisd-cn amavisd-new
- # fix new packages
- check_and_sed '^clamd.*5.clamav.log$' \
- 's/^\(clamd.*\)5.clamav.log$/\14\tsocket/g' \
- /etc/init.d/amavisd-cn || true
-
- # check if link got lost
- if pkg amavisd-cn && [ ! -L /etc/init.d/amavis ]; then
- apt-get install --reinstall --yes amavisd-cn
- fi
-
# start new packages
# start new packages
- /etc/init.d/amavis restart
+ /etc/init.d/amavisd-cn restart
}
# handle freerdius upgrade
}
# handle freerdius upgrade