NoPaste

/var/lib/dpkg/info/bind9.postrm

von suleiman
SNIPPET_DESC:
Mögliche Fehlermeldungen unterdrücken
SNIPPET_CREATION_TIME:
20.04.2018 15:10:17
SNIPPET_PRUNE_TIME:
Unendlich

SNIPPET_TEXT:
  1. #!/bin/sh
  2. # /var/lib/dpkg/info/bind9.postrm
  3.  
  4. # Automatically added by dh_systemd_enable
  5. if [ "$1" = "remove" ]; then
  6.         if [ -x "/usr/bin/deb-systemd-helper" ]; then
  7.                 deb-systemd-helper mask bind9-resolvconf.service >/dev/null || true
  8.         fi
  9. fi
  10.  
  11. if [ "$1" = "purge" ]; then
  12.         if [ -x "/usr/bin/deb-systemd-helper" ]; then
  13.                 deb-systemd-helper purge bind9-resolvconf.service >/dev/null || true
  14.                 deb-systemd-helper unmask bind9-resolvconf.service >/dev/null || true
  15.         fi
  16. fi
  17. # End automatically added section
  18. # Automatically added by dh_systemd_enable
  19. if [ "$1" = "remove" ]; then
  20.         if [ -x "/usr/bin/deb-systemd-helper" ]; then
  21.                 deb-systemd-helper mask bind9.service >/dev/null || true
  22.         fi
  23. fi
  24.  
  25. if [ "$1" = "purge" ]; then
  26.         if [ -x "/usr/bin/deb-systemd-helper" ]; then
  27.                 deb-systemd-helper purge bind9.service >/dev/null || true
  28.                 deb-systemd-helper unmask bind9.service >/dev/null || true
  29.         fi
  30. fi
  31. # End automatically added section
  32. # Automatically added by dh_installinit
  33. if [ "$1" = "purge" ] ; then
  34.         update-rc.d bind9 remove >/dev/null || true
  35. fi
  36.  
  37.  
  38. # In case this system is running systemd, we make systemd reload the unit files
  39. # to pick up changes.
  40. if [ -d /run/systemd/system ] ; then
  41.         systemctl --system daemon-reload >/dev/null || true
  42. fi
  43. # End automatically added section
  44. # Automatically added by dh_installdebconf
  45. if [ "$1" = purge ] && [ -e /usr/share/debconf/confmodule ]; then
  46.         . /usr/share/debconf/confmodule
  47.         db_purge
  48. fi
  49. # End automatically added section
  50.  
  51.  
  52. if [ "$1" = "purge" ]; then
  53.         rm -f /etc/bind/rndc.key /etc/bind/named.conf.options /etc/default/bind9
  54.         rmdir /etc/bind >/dev/null 2>&1 || true
  55.         rm -f /etc/apparmor.d/force-complain/usr.sbin.named >/dev/null 2>&1 || true
  56.         rm -f /var/lib/bind/bind9-default.md5sum
  57.         rmdir /var/lib/bind
  58.         # delete bind daemon user, if it exists
  59.         if getent passwd bind > /dev/null ; then
  60.             echo "Deleting bind user"
  61.             deluser  --quiet bind > /dev/null || true
  62.         fi
  63. fi
  64.  
  65. exit 0

Quellcode

Hier kannst du den Code kopieren und ihn in deinen bevorzugten Editor einfügen. PASTEBIN_DOWNLOAD_SNIPPET_EXPLAIN