57726f
[Unit]
57726f
Description=Berkeley Internet Name Domain (DNS)
57726f
Wants=nss-lookup.target
57726f
Wants=named-setup-rndc.service
57726f
Before=nss-lookup.target
57726f
After=named-setup-rndc.service
57726f
After=network.target
57726f
57726f
[Service]
57726f
Type=forking
57726f
Environment=NAMEDCONF=/etc/named.conf
57726f
EnvironmentFile=-/etc/sysconfig/named
57726f
Environment=KRB5_KTNAME=/etc/named.keytab
57726f
PIDFile=/run/named/named.pid
57726f
57726f
ExecStartPre=/bin/bash -c 'if [ ! "$DISABLE_ZONE_CHECKING" == "yes" ]; then /usr/sbin/named-checkconf -z "$NAMEDCONF"; else echo "Checking of zone files is disabled"; fi'
57726f
ExecStart=/usr/sbin/named-sdb -u named -c ${NAMEDCONF} $OPTIONS
57726f
57726f
ExecReload=/bin/sh -c 'if /usr/sbin/rndc null > /dev/null 2>&1; then /usr/sbin/rndc reload; else /bin/kill -HUP $MAINPID; fi'
57726f
57726f
ExecStop=/bin/sh -c '/usr/sbin/rndc stop > /dev/null 2>&1 || /bin/kill -TERM $MAINPID'
57726f
57726f
PrivateTmp=true
57726f
57726f
[Install]
57726f
WantedBy=multi-user.target