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