Cloud Run
CircleCIから CloudRun にデプロイするサンプル
version: 2.1
orbs:
gcp-gcr: circleci/gcp-gcr@0.11.0
cloudrun: circleci/gcp-cloud-run@1.0.2
jobs:
build-and-deploy:
executor: gcp-gcr/default
steps:
- checkout
- gcp-gcr/gcr-auth
- gcp-gcr/build-image:
image: ${IMAGE_NAME}
tag: ${CIRCLE_SHA1}
registry-url: asia.gcr.io
- gcp-gcr/push-image:
image: ${IMAGE_NAME}
tag: ${CIRCLE_SHA1}
registry-url: asia.gcr.io
- cloudrun/deploy:
image: asia.gcr.io/${GOOGLE_PROJECT_ID}/${IMAGE_NAME}:${CIRCLE_SHA1}
platform: managed
region: asia-northeast1
service-name: ${SERVICE_NAME}
unauthenticated: true
workflows:
deploy:
jobs:
- build-and-deploy:
filters:
branches:
only: master
参考資料