From b045529c40c83601909dca7b76a53498e9a70f33 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 10 Apr 2024 21:05:44 +0200 Subject: Adding upstream version 3.3.4. Signed-off-by: Daniel Baumann --- distro/pkg/deb/knot.postrm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 distro/pkg/deb/knot.postrm (limited to 'distro/pkg/deb/knot.postrm') diff --git a/distro/pkg/deb/knot.postrm b/distro/pkg/deb/knot.postrm new file mode 100644 index 0000000..14b3d69 --- /dev/null +++ b/distro/pkg/deb/knot.postrm @@ -0,0 +1,21 @@ +#!/bin/sh +set -e + +if test "$1" = "purge"; then + state_dir=/var/lib/knot + for db_name in "catalog" "confdb" "journal" "keys" "timers"; do + rm -rf $state_dir/$db_name >/dev/null 2>&1 || true + done + rmdir $state_dir >/dev/null 2>&1 || true + [ -e $state_dir/* ] && echo "Notice: there are still data in ${state_dir}, please check." + + dpkg-statoverride --remove /var/lib/knot >/dev/null 2>&1 || true + dpkg-statoverride --remove /etc/knot/knot.conf >/dev/null 2>&1 || true + dpkg-statoverride --remove /etc/knot >/dev/null 2>&1 || true + + deluser --quiet knot >/dev/null 2>&1 || true +fi + +#DEBHELPER# + +exit 0 -- cgit v1.2.3