Skip to content

Commit

Permalink
Update docker build platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
mkjsix committed Sep 3, 2024
1 parent c8e68e6 commit a79cdb3
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 7 deletions.
26 changes: 21 additions & 5 deletions .github/workflows/branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ jobs:

- name: Deploy to Maven Central
if: ${{ matrix.deploy }}
run: MAVEN_OPTS="--add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.desktop/java.awt.font=ALL-UNNAMED" mvn -B deploy -Pdeploy -s settings.xml
run: |
MAVEN_OPTS="--add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.desktop/java.awt.font=ALL-UNNAMED" \
mvn -B deploy -Pdeploy -s settings.xml
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand All @@ -87,11 +89,17 @@ jobs:
uses: docker/build-push-action@v6
with:
context: ./core/
platforms: linux/amd64,linux/arm64/v8,linux/ppc64le,linux/s390x
platforms: |
linux/amd64,
linux/arm64,
linux/ppc64le,
linux/s390x
push: true # push all images built
pull: true # pull all required images before building
# NOTE: snapshot images must be tagged with "latest" in master branch only
tags: softinstigate/restheart-snapshot:latest,softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}
tags: |
softinstigate/restheart-snapshot:latest,
softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}
- name: Build and Push GraalVM Docker image
if: ${{ matrix.deploy }}
Expand All @@ -102,15 +110,23 @@ jobs:
push: true # push all images built
pull: true # pull all required images before building
# NOTE: snapshot images must be tagged with "graalvm" in master branch only
tags: softinstigate/restheart-snapshot:graalvm,softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}-graalvm
tags: |
softinstigate/restheart-snapshot:graalvm,
softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}-graalvm
- name: Build and Push distroless docker image
if: ${{ matrix.deploy }}
uses: docker/build-push-action@v6
with:
context: ./core/
file: ./core/Dockerfile.distroless
platforms: |
linux/amd64,
linux/arm64,
linux/ppc64le
push: true # push all images built
pull: true # pull all required images before building
# NOTE: snapshot images must be tagged with "distroless" in master branch only
tags: softinstigate/restheart-snapshot:distroless,softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}-distroless
tags: |
softinstigate/restheart-snapshot:distroless,
softinstigate/restheart-snapshot:${{steps.vars.outputs.SHA}}-distroless
5 changes: 3 additions & 2 deletions .github/workflows/pullrequests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ jobs:
- mongodb-version: "5.0"
- mongodb-version: "6.0"
- mongodb-version: "7.0"
deploy: true
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
Expand All @@ -37,4 +36,6 @@ jobs:
- name: Build and Test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
run: MAVEN_OPTS="--add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.desktop/java.awt.font=ALL-UNNAMED" mvn -B clean verify -Dmongodb.version="${{ matrix.mongodb-version }}" -Dkarate.options="${{ matrix.karate-options }}"
run: |
MAVEN_OPTS="--add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.desktop/java.awt.font=ALL-UNNAMED" \
mvn -B clean verify -Dmongodb.version="${{ matrix.mongodb-version }}" -Dkarate.options="${{ matrix.karate-options }}"

0 comments on commit a79cdb3

Please sign in to comment.