diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:56:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:56:53 +0000 |
commit | a9c818418b81b93680170e1a84d4e221e578ad2f (patch) | |
tree | 5b883aa428f1edb12f5d40f9768438ee16a7ed6b /debian/wordpress.preinst | |
parent | Adding upstream version 6.4.3+dfsg1. (diff) | |
download | wordpress-a9c818418b81b93680170e1a84d4e221e578ad2f.tar.xz wordpress-a9c818418b81b93680170e1a84d4e221e578ad2f.zip |
Adding debian version 6.4.3+dfsg1-1.debian/6.4.3+dfsg1-1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/wordpress.preinst')
-rw-r--r-- | debian/wordpress.preinst | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/debian/wordpress.preinst b/debian/wordpress.preinst new file mode 100644 index 0000000..db4f729 --- /dev/null +++ b/debian/wordpress.preinst @@ -0,0 +1,21 @@ +#!/bin/sh + +set -e + +case "$1" in + upgrade) + if dpkg --compare-versions "$2" lt 5.8.1+dfsg1-2; then + # Move the incorrectly placed AppArmor file + if [ -d /etc/apparmor.d/apache2.d/wordpress ]; then + mv /etc/apparmor.d/apache2.d/wordpress /etc/apparmor.d/apache2.d/wordpress.old + if [ -e /etc/apparmor.d/apache2.d/wordpress.old/wordpress.apparmor ]; then + mv /etc/apparmor.d/apache2.d/wordpress.old/wordpress.apparmor /etc/apparmor.d/apache2.d/wordpress.tmp + fi + # Try to remove the old directory but ignore if it fails + rmdir /etc/apparmor.d/apache2.d/wordpress.old || true + fi + fi + ;; +esac + +#DEBHELPER# |