diff options
Diffstat (limited to 'nix/deploy.sh')
| -rwxr-xr-x | nix/deploy.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/nix/deploy.sh b/nix/deploy.sh index d3ad649..4459aab 100755 --- a/nix/deploy.sh +++ b/nix/deploy.sh @@ -1,6 +1,9 @@ #!/usr/bin/env bash set -euo pipefail +# Resolve paths relative to this script, not the caller's CWD +cd -- "$(dirname -- "$(readlink -f -- "${BASH_SOURCE[0]}")")" + HOST="$1" FLAKE=".#${HOST}" KEY_DIR="./host-keys/${HOST}" |
