Skip to content

Commit

Permalink
build docker
Browse files Browse the repository at this point in the history
  • Loading branch information
vharseko committed Nov 1, 2023
1 parent cf38aa5 commit 1fd993d
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 2 deletions.
53 changes: 52 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,55 @@ jobs:
jee-agents-distribution/jee-agents-distribution-jetty-v61/target/*.zip
jee-agents-distribution/jee-agents-distribution-jetty-v7/target/*.zip
jee-agents-distribution/jee-agents-distribution-jsr196/target/*.zip
jee-agents-distribution/jee-agents-distribution-tomcat-v6/target/*.zip
jee-agents-distribution/jee-agents-distribution-tomcat-v6/target/*.zip
build-docker-tomcat85-jre8:
runs-on: 'ubuntu-latest'
services:
registry:
image: registry:2
ports:
- 5000:5000
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: recursive
- name: Get latest release version
shell: bash
run: |
git fetch -t; export git_version_last="$(git describe --abbrev=0 --tags)" ; echo "last release: $git_version_last"
echo "release_version=$git_version_last" >> $GITHUB_ENV
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: |
localhost:5000/${{ github.repository }}
tags: |
type=raw,value=latest
type=raw,value=${{ env.release_version }}
type=raw,value=${{ env.release_version }}-tomcat
type=raw,value=tomcat
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
driver-opts: network=host
- name: Build image
uses: docker/build-push-action@v3
continue-on-error: true
with:
context: ./jee-agents-distribution/jee-agents-distribution-tomcat-v6
file: ./jee-agents-distribution/jee-agents-distribution-tomcat-v6/Dockerfile
build-args: |
VERSION=${{ env.release_version }}
platforms: linux/386, linux/amd64, linux/arm64/8, linux/arm/v6, linux/arm/v7, linux/ppc64le, linux/s390x
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
- name: Docker test
shell: bash
run: |
docker run --rm -it -d --name=test localhost:5000/${GITHUB_REPOSITORY,,}:${{ env.release_version }}
timeout 3m bash -c 'until docker inspect --format="{{json .State.Health.Status}}" test | grep -q \"healthy\"; do sleep 10; done'
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM tomcat:8.5-jre8
FROM tomcat:8.5-jre8-alpine

MAINTAINER Open Identity Platform Community <open-identity-platform-openam@googlegroups.com>

Expand Down

0 comments on commit 1fd993d

Please sign in to comment.