dotfiles/scripts/sealed_secrets_get_encrypted_secret_from_cluster.sh
Michael Grote 947024fcf1 chmod +x
Signed-off-by: Michael Grote <michael.grote@posteo.de>
2024-01-25 10:14:22 +01:00

8 lines
195 B
Bash
Executable file

#!/bin/bash
if [[ "$#" -eq 2 ]]; then
kubectl get secret $1 -n $2 -o jsonpath="{.data.<key>}" | base64 --decode ; echo""
else
echo "Missing:
\$1 = secretname
\$2 = namespace"
fi