Fix container build workflow
This commit is contained in:
14
.github/workflows/build-and-push-image.yml
vendored
14
.github/workflows/build-and-push-image.yml
vendored
@@ -1,4 +1,4 @@
|
||||
name: Build and Push Image to Dockerhub and GHCR
|
||||
name: Build and Push Images to Dockerhub and GHCR
|
||||
|
||||
on:
|
||||
push:
|
||||
@@ -9,6 +9,9 @@ on:
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
service: [backend, frontend]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
@@ -35,16 +38,19 @@ jobs:
|
||||
with:
|
||||
context: workflow
|
||||
images: |
|
||||
ericgullickson/motovaultpro
|
||||
ghcr.io/ericgullickson/motovaultpro
|
||||
ericgullickson/motovaultpro-${{ matrix.service }}
|
||||
ghcr.io/ericgullickson/motovaultpro-${{ matrix.service }}
|
||||
tags: |
|
||||
type=raw,value=latest,enable={{is_default_branch}}
|
||||
type=ref,event=tag
|
||||
labels: |
|
||||
org.opencontainers.image.title=MotoVaultPro ${{ matrix.service }}
|
||||
org.opencontainers.image.description=MotoVaultPro ${{ matrix.service }} service
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
context: ./${{ matrix.service }}
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
|
||||
Reference in New Issue
Block a user