fluxcd : adding repo example with some apps
This commit is contained in:
14
fluxcd/repo/scripts/external-secrets-manual-secret.sh
Executable file
14
fluxcd/repo/scripts/external-secrets-manual-secret.sh
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
set -eu
|
||||
read -p "Are you in the right cluster 'KUBECONFIG=$KUBECONFIG' ? (y/N) : " START
|
||||
|
||||
if [[ $START != 'y' ]]; then
|
||||
echo "Bye bye."
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
NAMESPACE="infrastructure"
|
||||
NAME="vault-k8s-external-secrets"
|
||||
|
||||
kubectl -n $NAMESPACE create secret generic $NAME \
|
||||
--from-env-file <(vault kv get -format=json kubernetes-secrets/$NAME | jq '.data.data' | jq -r "to_entries|map(\"\(.key)=\(.value|tostring)\")|.[]")
|
||||
Reference in New Issue
Block a user