Last active
April 12, 2021 14:35
-
-
Save echang0929/c4bcfcd027c31138ca6ea1725621d092 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GITHUB_USER="foo" | |
GITHUB_TOKN="1111111111222222222233333333334444444444" | |
GITHUB_REPO="https://xxx/foo/yyy.git" | |
cat <<EOF | kubectl apply -f - | |
apiVersion: v1 | |
kind: Secret | |
metadata: | |
name: github-secrets | |
type: Opaque | |
data: | |
git-user: $(echo -n ${GITHUB_USER} | base64) | |
git-token: $(echo -n ${GITHUB_TOKN} | base64) | |
EOF | |
repo_url="https://\$(git-user):\$(git-token)@${GITHUB_REPO#'https://'}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment