blob: 312c4b359cb5e43cdd4c3a69631da6025d5acbc6 [file] [log] [blame]
#!/bin/bash
set -e
set -o pipefail
# Retrieve the most recent version of the secret from GCP Secret Manager.
if [ $# -ne 2 ]; then
echo "$0 <secret name> <destination>"
exit 1
fi
SECRET_NAME="$1"; shift
DEST="$1"; shift
REL=$(dirname "$0")
source ${REL}/config.sh
${REL}/get-gcp-secret.sh ${SECRET_NAME} > "${DEST}"