diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.yml index f293862..4487110 100644 --- a/.github/workflows/docker-build.yml +++ b/.github/workflows/docker-build.yml @@ -8,7 +8,7 @@ on: - master jobs: - build-docker: + build-docker-hotspot: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 @@ -35,4 +35,32 @@ jobs: file: ./Dockerfile platforms: linux/amd64,linux/arm64 push: true - tags: 1337kavin/piped:latest + tags: 1337kavin/piped:hotspot + build-docker-openj9: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Set up QEMU + uses: docker/setup-qemu-action@v1 + with: + platforms: all + - name: Set up Docker Buildx + id: buildx + uses: docker/setup-buildx-action@v1 + with: + version: latest + - name: Login to DockerHub + uses: docker/login-action@v1 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + file: ./Dockerfile.openj9 + platforms: linux/amd64 + push: true + tags: 1337kavin/piped:latest,1337kavin/piped:openj9 diff --git a/Dockerfile.openj9 b/Dockerfile.openj9 new file mode 100644 index 0000000..1b92dbe --- /dev/null +++ b/Dockerfile.openj9 @@ -0,0 +1,17 @@ +FROM adoptopenjdk/openjdk11-openj9:slim AS build + +WORKDIR /app/ + +COPY . /app/ + +RUN chmod +x ./gradlew && ./gradlew shadowJar + +FROM adoptopenjdk/openjdk11-openj9:jre + +WORKDIR /app/ + +COPY --from=build /app/build/libs/piped-1.0-all.jar /app/piped.jar + +EXPOSE 8080 + +CMD java -jar /app/piped.jar