2020-07-19 19:37:07 +02:00
|
|
|
name: Docker
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
|
|
|
env:
|
|
|
|
VERSION: latest
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
push:
|
|
|
|
name: Push
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
if: github.event_name == 'push'
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Code Checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Registry Authentication
|
|
|
|
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
|
|
|
|
|
2020-08-05 04:11:03 +02:00
|
|
|
- name: Build alpine Image
|
2020-07-19 19:39:19 +02:00
|
|
|
run: docker build ./alpine --tag alpine
|
2020-07-19 19:37:07 +02:00
|
|
|
|
2020-08-05 04:11:03 +02:00
|
|
|
- name: Build java7 Image
|
|
|
|
run: docker build ./java7 --tag java7
|
|
|
|
|
|
|
|
- name: Build java8 Image
|
2020-07-19 19:39:19 +02:00
|
|
|
run: docker build ./java8 --tag java8
|
2020-07-19 19:37:07 +02:00
|
|
|
|
2020-08-05 04:11:03 +02:00
|
|
|
- name: Build java9 Image
|
|
|
|
run: docker build ./java9 --tag java9
|
|
|
|
|
|
|
|
- name: Build java10 Image
|
|
|
|
run: docker build ./java10 --tag java10
|
|
|
|
|
|
|
|
- name: Build java11 Image
|
|
|
|
run: docker build ./java11 --tag java11
|
|
|
|
|
|
|
|
- name: Build java12 Image
|
|
|
|
run: docker build ./java12 --tag java12
|
|
|
|
|
|
|
|
- name: Build java13 Image
|
|
|
|
run: docker build ./java13 --tag java13
|
|
|
|
|
|
|
|
- name: Build java14 Image
|
|
|
|
run: docker build ./java14 --tag java14
|
|
|
|
|
|
|
|
- name: Push alpine Image
|
2020-07-19 19:37:07 +02:00
|
|
|
run: |
|
|
|
|
IMAGE_NAME=alpine
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
2020-08-05 04:11:03 +02:00
|
|
|
- name: Push java7 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java7
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java8 Image
|
2020-07-19 19:37:07 +02:00
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java8
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
2020-08-05 04:11:03 +02:00
|
|
|
|
|
|
|
- name: Push java9 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java9
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java10 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java10
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java11 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java11
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java12 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java12
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java13 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java13
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|
|
|
|
|
|
|
|
- name: Push java14 Image
|
|
|
|
run: |
|
|
|
|
IMAGE_NAME=java14
|
|
|
|
IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/$IMAGE_NAME
|
|
|
|
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
|
|
|
|
|
|
|
|
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
|
|
|
|
docker push $IMAGE_ID:$VERSION
|