summaryrefslogtreecommitdiffstats
path: root/bin/launch
blob: 571b70d51b977b75826608c651d2d4d427cce438 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env bash
set -eu
set -o pipefail

script_path="$(realpath "$(dirname "$0")")"
secrets_bin="${script_path}/secrets"

case "$1" in
base | mail | partofme)
    "$secrets_bin" open
    trap '"$secrets_bin" close' EXIT
    "$(dirname "$0")/helpers/launch-$1"
    ;;
*)
    echo "unknown host $1" >&2
    exit 1
    ;;
esac