Private
Server IP : 195.201.23.43  /  Your IP : 3.21.113.219
Web Server : Apache
System : Linux webserver2.vercom.be 5.4.0-192-generic #212-Ubuntu SMP Fri Jul 5 09:47:39 UTC 2024 x86_64
User : kdecoratie ( 1041)
PHP Version : 7.1.33-63+ubuntu20.04.1+deb.sury.org+1
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /proc/self/root/var/lib/dpkg/info/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /proc/self/root/var/lib/dpkg/info/bind9.postinst
#!/bin/sh

set -e

if [ "$1" = configure ]; then
    # lets give them a bind user/group in all cases.
    getent group bind >/dev/null 2>&1 || addgroup --system bind
    getent passwd bind >/dev/null 2>&1 ||
	adduser --system --home /var/cache/bind --no-create-home \
		--disabled-password --ingroup bind bind

    # create data directory on fresh install
    if [ -z "$2" ]; then
	mkdir -p /var/lib/bind
	chown root:bind /var/lib/bind
	chmod 775 /var/lib/bind
    fi

    if [ ! -s /etc/bind/rndc.key ] && [ ! -s /etc/bind/rndc.conf ]; then
	rndc-confgen -a
    fi

    uid=$(ls -ln /etc/bind/rndc.key | awk '{print $3}')
    if [ "$uid" = "0" ]; then
	chown bind /etc/bind/rndc.key
	chgrp bind /etc/bind
	chmod g+s /etc/bind
	chgrp bind /etc/bind/rndc.key /var/cache/bind
	chgrp bind /etc/bind/named.conf* || true
	chmod g+r /etc/bind/rndc.key /etc/bind/named.conf* || true
	chmod g+rwx /var/cache/bind
    fi
fi

# Automatically added by dh_apparmor/2.13.3-7ubuntu5.4
if [ "$1" = "configure" ]; then
    APP_PROFILE="/etc/apparmor.d/usr.sbin.named"
    if [ -f "$APP_PROFILE" ]; then
        # Add the local/ include
        LOCAL_APP_PROFILE="/etc/apparmor.d/local/usr.sbin.named"

        test -e "$LOCAL_APP_PROFILE" || {
            mkdir -p `dirname "$LOCAL_APP_PROFILE"`
            install --mode 644 /dev/null "$LOCAL_APP_PROFILE"
        }

        # Reload the profile, including any abstraction updates
        if aa-enabled --quiet 2>/dev/null; then
            apparmor_parser -r -T -W "$APP_PROFILE" || true
        fi
    fi
fi
# End automatically added section
# Automatically added by dh_installsystemd/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	# In case this system is running systemd, we need to ensure that all
	# necessary tmpfiles (if any) are created before starting.
	if [ -d /run/systemd/system ] ; then
		systemd-tmpfiles --create named.conf >/dev/null || true
	fi
fi
# End automatically added section
# Automatically added by dh_installdeb/12.10ubuntu1
dpkg-maintscript-helper mv_conffile /etc/default/bind /etc/default/named 1:9.13.6\~ -- "$@"
dpkg-maintscript-helper mv_conffile /etc/default/bind9 /etc/default/named 1:9.12.0\~ -- "$@"
dpkg-maintscript-helper mv_conffile /etc/init.d/bind /etc/init.d/named 1:9.13.6\~ -- "$@"
dpkg-maintscript-helper mv_conffile /etc/init.d/bind9 /etc/init.d/named 1:9.12.0\~ -- "$@"
# End automatically added section
# Automatically added by dh_installinit/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	if [ -x "/etc/init.d/named" ]; then
		update-rc.d named defaults >/dev/null
		if [ -n "$2" ]; then
			_dh_action=restart
		else
			_dh_action=start
		fi
		invoke-rc.d --skip-systemd-native named $_dh_action || exit 1
	fi
fi
# End automatically added section
# Automatically added by dh_installsystemd/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	if deb-systemd-helper debian-installed 'named-resolvconf.service'; then
		# This will only remove masks created by d-s-h on package removal.
		deb-systemd-helper unmask 'named-resolvconf.service' >/dev/null || true

		if deb-systemd-helper --quiet was-enabled 'named-resolvconf.service'; then
			# Create new symlinks, if any.
			deb-systemd-helper enable 'named-resolvconf.service' >/dev/null || true
		fi
	fi

	# Update the statefile to add new symlinks (if any), which need to be cleaned
	# up on purge. Also remove old symlinks.
	deb-systemd-helper update-state 'named-resolvconf.service' >/dev/null || true
fi
# End automatically added section
# Automatically added by dh_installsystemd/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	if [ -d /run/systemd/system ]; then
		systemctl --system daemon-reload >/dev/null || true
		if [ -n "$2" ]; then
			_dh_action=restart
		else
			_dh_action=start
		fi
		deb-systemd-invoke $_dh_action 'named-resolvconf.service' >/dev/null || true
	fi
fi
# End automatically added section
# Automatically added by dh_installsystemd/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	# This will only remove masks created by d-s-h on package removal.
	deb-systemd-helper unmask 'named.service' >/dev/null || true

	# was-enabled defaults to true, so new installations run enable.
	if deb-systemd-helper --quiet was-enabled 'named.service'; then
		# Enables the unit on first installation, creates new
		# symlinks on upgrades if the unit file has changed.
		deb-systemd-helper enable 'named.service' >/dev/null || true
	else
		# Update the statefile to add new symlinks (if any), which need to be
		# cleaned up on purge. Also remove old symlinks.
		deb-systemd-helper update-state 'named.service' >/dev/null || true
	fi
fi
# End automatically added section
# Automatically added by dh_installsystemd/12.10ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then
	if [ -d /run/systemd/system ]; then
		systemctl --system daemon-reload >/dev/null || true
		if [ -n "$2" ]; then
			_dh_action=restart
		else
			_dh_action=start
		fi
		deb-systemd-invoke $_dh_action 'named.service' >/dev/null || true
	fi
fi
# End automatically added section


exit 0
Private