summaryrefslogtreecommitdiffstats
path: root/bin/terminate
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2018-10-16 00:09:25 -0400
committerJesse Luehrs <doy@tozt.net>2018-10-16 00:09:25 -0400
commit45a4f9be97f53c729ccf6bbea68225744116f740 (patch)
tree6fbf107fd14e4cc570a608b9808f19f22e139d88 /bin/terminate
parentacd6c2b8f2d96c259998f986f65ffe4f62927dad (diff)
downloadpuppet-tozt-45a4f9be97f53c729ccf6bbea68225744116f740.tar.gz
puppet-tozt-45a4f9be97f53c729ccf6bbea68225744116f740.zip
also parameterize terminate script
Diffstat (limited to 'bin/terminate')
-rwxr-xr-xbin/terminate10
1 files changed, 9 insertions, 1 deletions
diff --git a/bin/terminate b/bin/terminate
index ad4c337..2805abb 100755
--- a/bin/terminate
+++ b/bin/terminate
@@ -2,4 +2,12 @@
set -eu
set -o pipefail
-doctl compute droplet delete tozt
+case "$1" in
+ tozt)
+ doctl compute droplet delete "$1"
+ ;;
+ *)
+ echo "unknown host $1" >&2
+ exit 1
+ ;;
+esac