/^127\.0\.1\.1/d
EOF
-if bitfolk; then
- sudo systemctl disable systemd-networkd
-fi
-
##### exit first stage if running as root
if [[ $EUID == 0 ]]; then
+ if [[ ! -e /home/iank/.ssh/authorized_keys && ! -L /home/iank/.ssh/authorized_keys ]]; then
+ sudo -u iank mkdir -p /home/iank/.ssh
+ chmod 0700 /home/iank/.ssh
+ sudo -u iank ln -sf /p/c/machine_specific/vps/subdir_files/.ssh/authorized_keys /home/iank/.ssh
+ fi
echo "$0: running as root. exiting now that users are setup"
exit 0
fi
case $HOSTNAME in
bk)
sudo sed -i --follow-symlinks 's/^ *hosts:.*/hosts: files dns myhostname/' /etc/nsswitch.conf
+ soff systemd-resolved
+ ln -sf 127.0.0.1-resolv/stub-resolv.conf /etc/resolv.conf
+ sgo bind9
+ # cautious measure to make sure bind is up
+ sleep 1
;;
*)
# default is
;;
esac
-
+if bitfolk; then
+ sudo systemctl disable systemd-networkd
+fi
##### setup email
primary-setup