199a5d
[Unit]
199a5d
Description=Berkeley Internet Name Domain (DNS)
199a5d
Wants=nss-lookup.target
199a5d
Wants=named-setup-rndc.service
199a5d
Before=nss-lookup.target
199a5d
After=named-setup-rndc.service
199a5d
After=network.target
199a5d
199a5d
[Service]
199a5d
Type=forking
199a5d
Environment=NAMEDCONF=/etc/named.conf
199a5d
EnvironmentFile=-/etc/sysconfig/named
199a5d
Environment=KRB5_KTNAME=/etc/named.keytab
199a5d
PIDFile=/run/named/named.pid
199a5d
199a5d
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'
199a5d
ExecStart=/usr/sbin/named -u named -c ${NAMEDCONF} $OPTIONS
199a5d
ExecReload=/bin/sh -c 'if /usr/sbin/rndc null > /dev/null 2>&1; then /usr/sbin/rndc reload; else /bin/kill -HUP $MAINPID; fi'
199a5d
199a5d
ExecStop=/bin/sh -c '/usr/sbin/rndc stop > /dev/null 2>&1 || /bin/kill -TERM $MAINPID'
199a5d
199a5d
PrivateTmp=true
199a5d
199a5d
[Install]
199a5d
WantedBy=multi-user.target