Skip to content

add morphos

add morphos #3

Workflow file for this run

name: "[DEV] - Deploy"
on:
push:
branches:
- gh_actions
pull_request:
branches:
- dev
types:
- closed
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: get-npm-version
id: package-version
run: |
echo "current-version=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- id: 'auth'
uses: 'google-github-actions/auth@v2'
with:
credentials_json: ${{secrets.GCP_DEV_CREDENTIALS}}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GCR
uses: docker/login-action@v3
with:
registry: "us.gcr.io"
username: _json_key
password: ${{ secrets.GCP_DEV_CREDENTIALS }}
- name: Build and push
uses: docker/build-push-action@v6
id: docker_build
env:
DOCKER_BUILD_RECORD_UPLOAD: false
with:
push: true
no-cache: false
provenance: false
tags: us.gcr.io/${{secrets.GCP_PROJECT_DEV}}/vial-dcs-backend/morphos:commit-${{ steps.package-version.outputs.current-version }}
- id: 'deploy'
uses: 'google-github-actions/deploy-cloudrun@v2'
with:
service: "morphos"
image: "${{fromJSON(steps.docker_build.outputs.metadata)['image.name']}}"