########### misc stuff
+# pressing tab after sdf here:
+# scp sdfbash: set +o noglob: command not found
+# in t11, bash 5.1.16. this fixes it.
+sudo sed -ri 's/([[:space:]]*)(\$reset)$/\1set +o noglob #$reset/' /usr/share/bash-completion/bash_completion
+
rm -fv /home/iank/.mpv/watch_later
rm -rf /home/iank/.mpv
hash -r
fi
+# notes about barrier
+# run barrier, do the gui config,
+# setup the 2 screens, using hostnames for the new screen.
+# save the server config
+# $HOME/.local/share/barrier/.barrier.conf
+# per the man page.
+#
+# ssl errors, resolved via advice here: https://github.com/debauchee/barrier/issues/231
+# BARRIER_SSL_PATH=~/.local/share/barrier/SSL/
+# mkdir -p "${BARRIER_SSL_PATH}"
+# openssl req -x509 -nodes -days 365 -subj /CN=Barrier -newkey rsa:4096 -keyout ${BARRIER_SSL_PATH}/Barrier.pem -out ${BARRIER_SSL_PATH}/Barrier.pem
+# ran on both machines.
+# When pressing start in the gui, the cli options used are printed to the console,
+# they are useful. So on server, just run barriers, client run barrierc SERVER_IP
### begin timetrap setup
if mountpoint /p &>/dev/null; then
### begin nagios ###
-pi nagios4
-s rm -fv /etc/apache2/conf-enabled/nagios4-cgi.conf
+case $HOSTNAME in
+ kd)
+ pi nagios4
+ s rm -fv /etc/apache2/conf-enabled/nagios4-cgi.conf
-# to add a password for admin:
-# htdigest /etc/nagios4/htdigest.users Nagios4 iank
-# now using the same pass as prometheus
+ # to add a password for admin:
+ # htdigest /etc/nagios4/htdigest.users Nagios4 iank
+ # now using the same pass as prometheus
-# nagstamon auth settings, set to digest instead of basic.
+ # nagstamon auth settings, set to digest instead of basic.
-web-conf -p 3005 - apache2 i.b8.nz <<'EOF'
+ web-conf -p 3005 - apache2 i.b8.nz <<'EOF'
# adapted from /etc/apache2/conf-enabled/nagios4-cgi.conf
ScriptAlias /cgi-bin/nagios4 /usr/lib/cgi-bin/nagios4
Options +ExecCGI
</Directory>
EOF
-
+ ;;
+esac
# when you alter a service through the web, it changes vars in /var/lib/nagios4/status.dat. for example:
# notifications_enabled=1
### end nagios ###
+### begin bitcoin ###
+
+case $HOSTNAME in
+ sy)
+ f=$dir/bitcoin.conf
+ sudo install -m 0755 -o root -g root -t /usr/bin /a/opt/bitcoin-23.0/bin/*
+ sgo bitcoind
+ sudo usermod -a -G bitcoin iank
+ # todo, link in wallet. see
+ # /a/bin/ds/disabled/bitcoin
+ ;;
+esac
+
+### end bitcoin
+
end_msg <<'EOF'
In mate settings settings, change scrolling to two-finger,