mirror of
https://git.proxmox.com/git/pmg-api
synced 2025-10-04 14:46:38 +00:00
d/postinst: version-guard migration to new pending pmg-score location
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
bc33a433c1
commit
b3558c4521
18
debian/postinst
vendored
18
debian/postinst
vendored
@ -126,14 +126,16 @@ case "$1" in
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
old_score_location=/var/cache/pmg-scores.cf
|
if test -n "$2" && dpkg --compare-versions "$2" 'lt' '8.2.0'; then
|
||||||
new_score_location=/etc/mail/spamassassin/pmg-scores.cf.new
|
old_score_location=/var/cache/pmg-scores.cf
|
||||||
if test -e "$old_score_location"; then
|
new_score_location=/etc/mail/spamassassin/pmg-scores.cf.new
|
||||||
if ! test -e "$new_score_location"; then
|
if test -e "$old_score_location"; then
|
||||||
echo "moving $old_score_location to $new_score_location"
|
if ! test -e "$new_score_location"; then
|
||||||
mv "$old_score_location" "$new_score_location"
|
echo "moving $old_score_location to $new_score_location"
|
||||||
else
|
mv "$old_score_location" "$new_score_location"
|
||||||
echo "both $old_score_location and $new_score_location exist - please review manually"
|
else
|
||||||
|
echo "both $old_score_location and $new_score_location exist - please review manually"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
|
Loading…
Reference in New Issue
Block a user