Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save TheCodeEngine/0e0feca5915991734154da35ed1f8c44 to your computer and use it in GitHub Desktop.
Save TheCodeEngine/0e0feca5915991734154da35ed1f8c44 to your computer and use it in GitHub Desktop.
SemaphoreCI-GCloud-init
#
## Build Container
#
export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
echo "deb http://packages.cloud.google.com/apt $CLOUD_SDK_REPO main" | sudo tee /etc/apt/sources.list.d/google-cloud-sdk.list
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
sudo apt-get update && sudo apt-get install google-cloud-sdk
sudo gcloud auth activate-service-account [email protected] --key-file /home/runner/key.json
# GCloud Einrichtung
sudo gcloud config set compute/zone "europe-west1-b"
sudo gcloud config set container/cluster shopcloud
sudo gcloud config set project shopcloud-1306
curl -k -o kubectl https://kuar.io/linux/kubectl
chmod +x kubectl
sudo mv kubectl /usr/local/bin/
sudo gcloud container clusters get-credentials shopcloud
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment