fix the newline problem with stringData
All checks were successful
Github Actions Demo / Explore-Gitea-Actions (push) Successful in 6s

This commit is contained in:
James Andariese 2024-03-02 22:17:07 -06:00
parent d887b3b746
commit d7afd09da5

View File

@ -4,7 +4,7 @@ cd /root
/bin/ipfs-key "$@" 2> /root/keygen.stderr 1> peer.key /bin/ipfs-key "$@" 2> /root/keygen.stderr 1> peer.key
awk '/^ID for generated key:/ {print $5}' < keygen.stderr > peer.id awk '/^ID for generated key:/ {print $5}' < keygen.stderr > peer.id
xxd -p -l 32 -c 32 /dev/random > cluster.key xxd -p -l 32 -c 32 /dev/random | tr -d '\n' > cluster.key
cat << EOF cat << EOF
--- ---
@ -20,9 +20,10 @@ apiVersion: v1
kind: Secret kind: Secret
metadata: metadata:
name: ipfs-secrets name: ipfs-secrets
data: stringData:
cluster-secret: |- cluster-secret: |-
$(base64 -w 0 cluster.key) $(xxd -p -l 32 -c 32 /dev/random)
data:
bootstrap-peer-priv-key: |- bootstrap-peer-priv-key: |-
$(base64 -w 0 peer.key) $(base64 -w 0 peer.key)
EOF EOF