diff options
-rwxr-xr-x | scripts/box/restore-backup.env.sh | 4 | ||||
-rwxr-xr-x | scripts/ci/setup.sh | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/scripts/box/restore-backup.env.sh b/scripts/box/restore-backup.env.sh index 14d462d..0c6fdca 100755 --- a/scripts/box/restore-backup.env.sh +++ b/scripts/box/restore-backup.env.sh @@ -6,12 +6,12 @@ export BORG_PASSPHRASE="${BORG_PASSPHRASE}" pushd "$(mktemp -d)" || exit 1 ARCHIVE="$(borg list "${BORG_REPO}" --last 1 --short)" -echo "Extracting archive ${ARCHIVE}" +echo "Extracting archive ${DOLLAR}{ARCHIVE}" borg extract \ --verbose \ --stats \ --progress \ - "${BORG_REPO}"::"${ARCHIVE}" + "${BORG_REPO}"::"${DOLLAR}{ARCHIVE}" echo "Done." mv home/vps/volumes/* /home/vps/volumes/ diff --git a/scripts/ci/setup.sh b/scripts/ci/setup.sh index dbbf32a..d9ac70c 100755 --- a/scripts/ci/setup.sh +++ b/scripts/ci/setup.sh @@ -28,6 +28,11 @@ export SSH_SERVER_PRIVATE_KEY SSH_SERVER_PUBLIC_KEY="$(cat ./secrets/ssh/vps-box-server.pub)" export SSH_SERVER_PUBLIC_KEY +# Used for keeping bash variables for run-time substituion instead of execution time substitution. +# Taken from: +# https://stackoverflow.com/questions/24963705/is-there-an-escape-character-for-envsubst +export DOLLAR='$' + envsubst < ./ssh.env.conf >> ~/.ssh/config envsubst < ./hosts.env > ./hosts envsubst < ./docker-compose.env.yaml > ./docker-compose.yaml |