Skip to content

Instantly share code, notes, and snippets.

@treeder
Last active July 29, 2019 19:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save treeder/e577eb5c0de77228f9b9e43c03efdacb to your computer and use it in GitHub Desktop.
Save treeder/e577eb5c0de77228f9b9e43c03efdacb to your computer and use it in GitHub Desktop.
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/hello:$SHORT_SHA', '.']
- name: 'gcr.io/cloud-builders/docker'
args: ['tag', 'gcr.io/$PROJECT_ID/hello:$SHORT_SHA', 'gcr.io/$PROJECT_ID/hello:latest']
- name: 'gcr.io/cloud-builders/docker'
args: ['tag', 'gcr.io/$PROJECT_ID/hello:$SHORT_SHA', 'gcr.io/$PROJECT_ID/hello:$BRANCH_NAME']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/hello:$SHORT_SHA']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/hello:latest']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/hello:$BRANCH_NAME']
- name: 'gcr.io/cloud-builders/gcloud'
args: [ 'beta', 'run', 'deploy', '--region', 'us-central1', '--image', 'gcr.io/$PROJECT_ID/hello', '--platform', 'managed', 'hello' ]
images:
- 'gcr.io/$PROJECT_ID/hello'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment