blob: 0890381d77c0a26819d11a5bdadb8554e5f0fa22 [file] [log] [blame]
#!/bin/bash
set -e
echo "Generating ~/.gke-jenkins/oauth-credentials.yaml since you don't have one."
install -d -m 700 $HOME/.gke-jenkins
read -p "Please enter the OAuth2 Client ID here: " clientid
read -p "Please enter the OAuth2 Client Secret here: " clientsecret
cat <<EOF > $HOME/.gke-jenkins/oauth-credentials.yaml
securityRealm:
googleOAuth2:
clientId: "${clientid}"
clientSecret: "${clientsecret}"
domain: "google.com"
rootURLFromRequest: true
# Indentation matters! DO NOT EDIT MANUALLY!
EOF