Skip to content

Instantly share code, notes, and snippets.

@edsoncelio
Created March 19, 2019 12:56
Show Gist options
  • Save edsoncelio/25a85fa4b59b2cf43e8eac064bdbb17f to your computer and use it in GitHub Desktop.
Save edsoncelio/25a85fa4b59b2cf43e8eac064bdbb17f to your computer and use it in GitHub Desktop.
Configuração para integração Gitlab + Source Repository do GCP
image: docker:latest
services:
- docker:dind
variables:
DOCKER_DRIVER: overlay
stages:
- update_mirror
google_source:
image: google/cloud-sdk
stage: update_mirror
script:
- echo "$GOOGLE_KEY" > key.json
- gcloud auth activate-service-account --key-file key.json
- git config --global credential.'https://source.developers.google.com'.helper gcloud.sh
- git remote add google https://source.developers.google.com/p/<GCP Project Name>/r/<Cloud Source Repo>
- git checkout -b master
- git push -f google master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment