Skip to content

Merge pull request #12 from AxonIQ/docs #35

Merge pull request #12 from AxonIQ/docs

Merge pull request #12 from AxonIQ/docs #35

Workflow file for this run

name: Build
# Controls when the workflow will run
on:
workflow_dispatch:
push:
branches:
- 'main'
pull_request:
branches:
- 'main'
# permissions are needed if pushing to ghcr.io
permissions:
packages: write
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up JDK ${{ matrix.java-version }}
uses: actions/[email protected]
with:
distribution: 'corretto'
java-version: 21
cache: "maven"
- name: Login to GHCR
if: github.event_name != 'pull_request'
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
# https://github.com/docker/setup-qemu-action
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
# https://github.com/docker/setup-buildx-action
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- name: Install services
run: |
sh create-microservices.sh
sh mvnw -B -U clean install
- name: Build and push Command service
uses: docker/build-push-action@v2
with:
context: microservices/rental-command
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-command:latest
- name: Build and push Rental Payment service
uses: docker/build-push-action@v2
with:
context: microservices/rental-payment
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-rental-payment:latest
- name: Build and push Payment service
uses: docker/build-push-action@v2
with:
context: payment
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-payment:latest
- name: Build and push Query service
uses: docker/build-push-action@v2
with:
context: microservices/rental-query
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-query:latest
- name: Build and push UI service
uses: docker/build-push-action@v2
with:
context: microservices/rental-ui
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-ui:latest
- name: Build and push axon server
uses: docker/build-push-action@v2
with:
context: .github/axonserver
platforms: linux/amd64,linux/arm64/v8
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/axoniq/bike-rental-axonserver-control-tower:latest