Skip to content

Docker Image CI

Docker Image CI #25

Workflow file for this run

name: Docker Image CI
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
cache: 'maven'
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
-
name: Build and push producer
uses: docker/build-push-action@v4
with:
context: ./fruit-producer
platforms: linux/amd64
push: true
tags: |
ghcr.io/${{ github.repository_owner }}/fruit-producer:${{ github.event.release.tag_name }}
ghcr.io/${{ github.repository_owner }}/fruit-producer:latest
-
name: Build and push azurefunction
uses: docker/build-push-action@v4
with:
context: ./fruit-consumer-azurefunction
platforms: linux/amd64
push: true
tags: |
ghcr.io/${{ github.repository_owner }}/fruit-consumer-azurefunction:${{ github.event.release.tag_name }}
ghcr.io/${{ github.repository_owner }}/fruit-consumer-azurefunction:latest
- name: build mvnm
run: |
cd fruit-consumer-java
mvn package
-
name: Build and push java
uses: docker/build-push-action@v4
with:
context: ./fruit-consumer-java
file: ./fruit-consumer-java/src/main/docker/Dockerfile.jvm
platforms: linux/amd64
push: true
tags: |
ghcr.io/${{ github.repository_owner }}/fruit-consumer-java:${{ github.event.release.tag_name }}
ghcr.io/${{ github.repository_owner }}/fruit-consumer-java:latest