Skip to content

Merge branch 'berkeley-schema-migration' of github.com:microbiomedata… #4

Merge branch 'berkeley-schema-migration' of github.com:microbiomedata…

Merge branch 'berkeley-schema-migration' of github.com:microbiomedata… #4

name: build-berkeley-image
on:
push:
branches:
- berkeley-schema-migration
env:
IS_ORIGINAL_REPO: ${{ github.repository == 'microbiomedata/nmdc-server' }}
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
image: [server, client, worker]
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Login to Github Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
images: |
ghcr.io/microbiomedata/nmdc-server/${{ matrix.image }}
flavor: |
latest=false
prefix=berkeley
tags: |
type=ref,event=branch
- name: Build and push
uses: docker/build-push-action@v5
with:
context: ${{ matrix.image == 'client' && 'web' || '.' }}
push: ${{ env.IS_ORIGINAL_REPO }}
file: ${{ matrix.image == 'worker' && 'Dockerfile.worker' || matrix.image == 'client' && 'web/Dockerfile' || 'Dockerfile' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}