Created
May 20, 2019 08:36
-
-
Save shalkam/d15d532fc98187d7fae3237c7f76b418 to your computer and use it in GitHub Desktop.
using kubeconfig.yml
This file contains 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
stages: | |
- deploy | |
variables: | |
KUBE_CONFIG: "content_of_base64_kubeconfig.yml_goes_here" | |
deploy_app: | |
image: bitnami/kubectl:latest | |
stage: deploy | |
environment: production | |
only: | |
- master | |
script: | |
- echo -n $KUBE_CONFIG | base64 -d > ./config | |
- kubectl set image deployment my-app web=${CI_REGISTRY}/user/repo/${CI_PROJECT_PATH_SLUG}:${CI_COMMIT_SHORT_SHA} --kubeconfig ./config --namespace default |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment