commit - 6f6364cd451ccc661a9382300f0b27886b959f75
commit + f72c728cfdcabc01e5ac5ab089330bace69f9f47
blob - b7452c93615a770478fa039e25481074a5e1b873
blob + 4ceca74b88065fdd36ec5e373fafb8bb08b0589a
--- cease.sh
+++ cease.sh
#!/bin/sh
#
-# Copyright (c) 2019-2022 Mischa Peters <mischa @ openbsd.amsterdam>
+# Copyright (c) 2019-2024 Mischa Peters <mischa @ openbsd.amsterdam>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
+SSHOPTIONS='-p 31415 -l mischa -i /home/mischa/.ssh/id_ed25519'
+BINPATH='/home/mischa/bin'
+
CONF_FILE="${PWD}/_deploy.conf"
if [[ -f "${CONF_FILE}" ]]; then
. "${CONF_FILE}"
IPV4=$(grep -A2 ${1%.txt} /etc/dhcpd.conf | awk '/fixed/ {print $2}' | tr -d ';')
IPV6=$(grep -A3 ${1%.txt} /etc/dhcpd.conf | awk '/fixed-address-ipv6/ {print $2}' | tr -d ';')
echo "a reset ${IPV4} ${IPV6}"
- remove.pl ${1}
- deploy.pl
+ ${BINPATH}/remove.pl ${1}
+ ${BINPATH}/deploy.pl
if [[ -z ${DHCPD} ]]; then
rcctl restart dhcpd
fi
fi
if [[ "${SERVER}" == server* ]] || [[ "${SERVER}" == mega* ]]; then
- openrsync -va --del /home/mischa/vms/ mischa@wm1.obsda.ms:vms/${HOST}/
- ssh wm1.obsda.ms "doas userdel -r ${HOST}${1%.txt}"
- ssh wm1.obsda.ms "doas groupdel ${HOST}${1%.txt}"
- openrsync -va --del /home/mischa/vms/ mischa@rx.high5.nl:vms/${HOST}/
+ openrsync -va --del -e "ssh ${SSHOPTIONS}" /home/mischa/vms/ mischa@wm1.obsda.ms:vms/${HOST}/
+ ssh ${SSHOPTIONS} wm1.obsda.ms "doas userdel -r ${HOST}${1%.txt}"
+ ssh ${SSHOPTIONS} wm1.obsda.ms "doas groupdel ${HOST}${1%.txt}"
+ openrsync -va --del -e "ssh ${SSHOPTIONS}" /home/mischa/vms/ mischa@rx.high5.nl:vms/${HOST}/
fi
blob - 168364b5d31d19649cbfba444fff99e7bdf6985d
blob + c3e1ad2b98bbf656683a14b25a17d831ca2dae71
--- launch.sh
+++ launch.sh
#!/bin/sh
#
-# Copyright (c) 2019-2023 Mischa Peters <mischa @ openbsd.amsterdam>
+# Copyright (c) 2019-2024 Mischa Peters <mischa @ openbsd.amsterdam>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
+SSHOPTIONS='-p 31415 -l mischa -i /home/mischa/.ssh/id_ed25519'
+BINPATH='/home/mischa/bin'
+
CONF_FILE="${PWD}/_deploy.conf"
if [[ -f "${CONF_FILE}" ]]; then
. "${CONF_FILE}"
fi
if [[ "${SERVER}" == server* ]] || [[ "${SERVER}" == mega* ]]; then
- openrsync -va --del /home/mischa/vms/ mischa@wm1.obsda.ms:vms/${HOST}/
- ssh wm1.obsda.ms "doas ./create-user.pl ${HOST}${1}"
- openrsync -va --del /home/mischa/vms/ mischa@rx.high5.nl:vms/${HOST}/
+ openrsync -va --del -e "ssh ${SSHOPTIONS}" /home/mischa/vms/ mischa@wm1.obsda.ms:vms/${HOST}/
+ ssh ${SSHOPTIONS} wm1.obsda.ms "doas ./create-user.pl ${HOST}${1}"
+ openrsync -va --del -e "ssh ${SSHOPTIONS}" /home/mischa/vms/ mischa@rx.high5.nl:vms/${HOST}/
fi
-deploy.pl
+${BINPATH}/deploy.pl
sleep 5
if [[ -z ${DHCPD} ]]; then
rcctl restart dhcpd
echo "completed"
-deploy.pl
+${BINPATH}/deploy.pl
sleep 5
if [[ -z ${DHCPD} ]]; then
rcctl restart dhcpd
echo
echo "SUCCES! - deployed ${INSTANCE}"
-notify.pl deployed ${1} "${2}"
-pushover.pl -m "${SERVER} ${INSTANCE} deployed" -t "OpenBSD Amsterdam"
+${BINPATH}/notify.pl deployed ${1} "${2}"
+${BINPATH}/pushover.pl -m "${SERVER} ${INSTANCE} deployed" -t "OpenBSD Amsterdam"