Skip to content

Instantly share code, notes, and snippets.

@mstapp
Last active October 4, 2023 08:18
Show Gist options
  • Save mstapp/c0f4dfc8c86f521b4910 to your computer and use it in GitHub Desktop.
Save mstapp/c0f4dfc8c86f521b4910 to your computer and use it in GitHub Desktop.
Install tinydns (djbdns) & daemontools on ubuntu 14.04
# install tinydns (djbdns) & daemontools on ubuntu 14.04
apt-get -y install daemontools
apt-get -y install daemontools-run
apt-get -y install ucspi-tcp
apt-get -y install djbdns
mkdir -p /etc/service
# NOTE: installing daemontools-run takes care of this, else
# would need to add a conf file for booting:
#
#cd /etc/init/
#touch svscan.conf
#echo "start on runlevel [2345]" > svscan.conf
#echo "" >> svscan.conf
#echo "expect fork" >> svscan.conf
#echo "respawn" >> svscan.conf
#echo "exec svscanboot" >> svscan.conf
service svscan start
########
# djbdns
adduser --no-create-home --disabled-login --shell /bin/false dnslog
adduser --no-create-home --disabled-login --shell /bin/false tinydns
tinydns-conf tinydns dnslog /etc/tinydns/ EXTERNAL.IP.ADDRESS # TODO: your IP here
cd /etc/service ; ln -sf /etc/tinydns/
# svscan should find & launch the new tinydns daemon
# NOTE: to stop & start manually:
# stop:
# svc -d /etc/service/tinydns
# start:
# svc -u /etc/service/tinydns
###
# Now configure the tinydns "data" file in /etc/tinydns/root/data,
# then run "make" in that directory to build the runtime data .cbd file and
# restart tinydns.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment