Skip to content

feat: Removed base image alpine #11

feat: Removed base image alpine

feat: Removed base image alpine #11

Workflow file for this run

name: Java
on:
workflow_dispatch:
push:
branches:
- master
paths:
- java/**
jobs:
push:
name: "esdock:java_${{ matrix.tag }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
tag:
- 16
- 17
- 18
- 19
- 20
- 21
- 22
platform:
- linux/amd64
- linux/arm64
steps:
- uses: actions/checkout@v4
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
with:
buildkitd-flags: --debug
- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Determine Base Image
id: base-image
run: |
if [[ "${{ matrix.platform }}" == "linux/arm64" ]]; then
if [[ ${{ matrix.tag }} -eq 16 ]]; then
echo "BASE_IMAGE=focal" >> $GITHUB_ENV
elif [[ ${{ matrix.tag }} -ge 17 && ${{ matrix.tag }} -le 20 ]]; then
echo "BASE_IMAGE=jammy" >> $GITHUB_ENV
fi
fi
- uses: docker/build-push-action@v5
with:
context: ./java
file: ./java/${{ matrix.tag }}/Dockerfile
platforms: ${{ matrix.platform }}
push: true
build-args: |
BASE_IMAGE=${{ env.BASE_IMAGE }}
tags: |
ghcr.io/zastinian/esdock:java_${{ matrix.tag }}