From 01faad1459bda053af0a43da3330994d9315df7f Mon Sep 17 00:00:00 2001 From: Eduardo Martins Date: Wed, 6 Sep 2023 11:32:28 +0100 Subject: [PATCH] ... --- .../helloworld-quickstart-testing.ci.yml | 70 ----------------- ...roprofile-config-quickstart-testing.ci.yml | 70 ----------------- .github/workflows/{ci.yml => project_ci.yml} | 32 -------- .../workflows/quickstart_helloworld_ci.yml | 78 +++++++++++++++++++ .../quickstart_microprofile-config_ci.yml | 78 +++++++++++++++++++ 5 files changed, 156 insertions(+), 172 deletions(-) delete mode 100644 .github/workflows/helloworld-quickstart-testing.ci.yml delete mode 100644 .github/workflows/microprofile-config-quickstart-testing.ci.yml rename .github/workflows/{ci.yml => project_ci.yml} (61%) create mode 100644 .github/workflows/quickstart_helloworld_ci.yml create mode 100644 .github/workflows/quickstart_microprofile-config_ci.yml diff --git a/.github/workflows/helloworld-quickstart-testing.ci.yml b/.github/workflows/helloworld-quickstart-testing.ci.yml deleted file mode 100644 index 7d406fc4ec..0000000000 --- a/.github/workflows/helloworld-quickstart-testing.ci.yml +++ /dev/null @@ -1,70 +0,0 @@ -name: WildFly Quickstart CI - -env: - QUICKSTART_PATH: helloworld - MICROPROFILE: false - -on: - pull_request: - types: [opened, synchronize, reopened, ready_for_review] -# paths: -# - '$QUICKSTART_PATH/**' - -jobs: - Test-build-default-matrix: - name: BUILD DEFAULT - JDK${{ matrix.jdk }} - ${{ matrix.os }} - runs-on: ${{ matrix.os }} - strategy: - fail-fast: false - matrix: - jdk: [11, 17] - os: [ubuntu-20.04, windows-latest] - steps: - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - - uses: actions/checkout@v2 - with: - path: quickstarts - - name: Set up JDK ${{ matrix.java }} - uses: AdoptOpenJDK/install-jdk@v1 - with: - version: ${{ matrix.jdk }} - impl: hotspot - - name: Build & Run Quickstart with provisioned-server profile - if: ${{ env.MICROPROFILE == 'false' }} - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Pprovisioned-server - mvn -U -B -fae wildfly:start -DjbossHome=target/server - mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing - mvn -U -B -fae wildfly:shutdown - shell: bash - - name: Build Quickstart bootable-jar profile - if: ${{ env.MICROPROFILE == 'true' }} - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Pbootable-jar - mvn -U -B -fae wildfly-jar:start -Djar-file-name=target/${{ env.QUICKSTART_PATH }}-bootable.jar - mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing - mvn -U -B -fae wildfly-jar:shutdown - shell: bash - - name: Build Quickstart openshift profile - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Popenshift - shell: bash - - name: Build Quickstart for Release - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean install -Drelease - shell: bash - - uses: actions/upload-artifact@v3 - if: failure() - with: - name: surefire-reports-JDK${{ matrix.jdk }}-${{ matrix.os }} - path: 'quickstarts/$QUICKSTART_PATH/**/surefire-reports/*.txt' \ No newline at end of file diff --git a/.github/workflows/microprofile-config-quickstart-testing.ci.yml b/.github/workflows/microprofile-config-quickstart-testing.ci.yml deleted file mode 100644 index 21698f14fb..0000000000 --- a/.github/workflows/microprofile-config-quickstart-testing.ci.yml +++ /dev/null @@ -1,70 +0,0 @@ -name: WildFly Quickstart CI - -env: - QUICKSTART_PATH: microprofile-config - MICROPROFILE: true - -on: - pull_request: - types: [opened, synchronize, reopened, ready_for_review] -# paths: -# - '$QUICKSTART_PATH/**' - -jobs: - Test-build-default-matrix: - name: BUILD DEFAULT - JDK${{ matrix.jdk }} - ${{ matrix.os }} - runs-on: ${{ matrix.os }} - strategy: - fail-fast: false - matrix: - jdk: [11, 17] - os: [ubuntu-20.04, windows-latest] - steps: - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - - uses: actions/checkout@v2 - with: - path: quickstarts - - name: Set up JDK ${{ matrix.java }} - uses: AdoptOpenJDK/install-jdk@v1 - with: - version: ${{ matrix.jdk }} - impl: hotspot - - name: Build & Run Quickstart with provisioned-server profile - if: ${{ env.MICROPROFILE == 'false' }} - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Pprovisioned-server - mvn -U -B -fae wildfly:start -DjbossHome=target/server - mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing - mvn -U -B -fae wildfly:shutdown - shell: bash - - name: Build Quickstart bootable-jar profile - if: ${{ env.MICROPROFILE == 'true' }} - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Pbootable-jar - mvn -U -B -fae wildfly-jar:start -Djar-file-name=target/${{ env.QUICKSTART_PATH }}-bootable.jar - mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing - mvn -U -B -fae wildfly-jar:shutdown - shell: bash - - name: Build Quickstart openshift profile - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean package -Popenshift - shell: bash - - name: Build Quickstart for Release - run: | - cd quickstarts - cd ${{ env.QUICKSTART_PATH }} - mvn -U -B -fae clean install -Drelease - shell: bash - - uses: actions/upload-artifact@v3 - if: failure() - with: - name: surefire-reports-JDK${{ matrix.jdk }}-${{ matrix.os }} - path: 'quickstarts/$QUICKSTART_PATH/**/surefire-reports/*.txt' \ No newline at end of file diff --git a/.github/workflows/ci.yml b/.github/workflows/project_ci.yml similarity index 61% rename from .github/workflows/ci.yml rename to .github/workflows/project_ci.yml index 8723235d2c..1dd0132f18 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/project_ci.yml @@ -1,5 +1,3 @@ -# This workflow will build a Java project with Maven -# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven name: WildFly Quickstarts CI on: @@ -26,21 +24,6 @@ jobs: with: version: ${{ matrix.jdk }} impl: hotspot - - name: Build Quickstarts provisioned-server profile - run: | - cd quickstarts - mvn -U -B -fae clean package -Pprovisioned-server - shell: bash - - name: Build Quickstarts bootable-jar profile - run: | - cd quickstarts - mvn -U -B -fae clean package -Pbootable-jar - shell: bash - - name: Build Quickstarts openshift profile - run: | - cd quickstarts - mvn -U -B -fae clean package -Popenshift - shell: bash - name: Build Quickstarts Release run: | cd quickstarts @@ -102,21 +85,6 @@ jobs: cd boms echo "VERSION_BOMS=$(mvn -N org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_ENV shell: bash - - name: Build Quickstarts provisioned-server profile with Server and BOMs Versions - run: | - cd quickstarts - mvn -U -B -fae clean package -Pprovisioned-server -Dversion.server.bom=${{ env.VERSION_BOMS }} -Dversion.bom.ee=${{ env.VERSION_BOMS }} -Dversion.microprofile.bom=${{ env.VERSION_BOMS }} -Dversion.bom.microprofile=${{ env.VERSION_BOMS }} -Dversion.server.bootable-jar=${{ env.VERSION_SERVER }} -Dversion.server=${{ env.VERSION_SERVER }} - shell: bash - - name: Build Quickstarts bootable-jar profile with Server and BOMs Versions - run: | - cd quickstarts - mvn -U -B -fae clean package -Pbootable-jar -Dversion.server.bom=${{ env.VERSION_BOMS }} -Dversion.bom.ee=${{ env.VERSION_BOMS }} -Dversion.microprofile.bom=${{ env.VERSION_BOMS }} -Dversion.bom.microprofile=${{ env.VERSION_BOMS }} -Dversion.server.bootable-jar=${{ env.VERSION_SERVER }} -Dversion.server=${{ env.VERSION_SERVER }} - shell: bash - - name: Build Quickstarts openshift profile with Server and BOMs Versions - run: | - cd quickstarts - mvn -U -B -fae clean package -Popenshift -Dversion.server.bom=${{ env.VERSION_BOMS }} -Dversion.bom.ee=${{ env.VERSION_BOMS }} -Dversion.microprofile.bom=${{ env.VERSION_BOMS }} -Dversion.bom.microprofile=${{ env.VERSION_BOMS }} -Dversion.server.bootable-jar=${{ env.VERSION_SERVER }} -Dversion.server=${{ env.VERSION_SERVER }} - shell: bash - name: Build Quickstarts Release with Server and BOMs Versions run: | cd quickstarts diff --git a/.github/workflows/quickstart_helloworld_ci.yml b/.github/workflows/quickstart_helloworld_ci.yml new file mode 100644 index 0000000000..7adf0522f2 --- /dev/null +++ b/.github/workflows/quickstart_helloworld_ci.yml @@ -0,0 +1,78 @@ +name: WildFly ${{ env.QUICKSTART_PATH }} Quickstart CI + +env: + QUICKSTART_PATH: helloworld + MICROPROFILE: false + +on: + pull_request: + types: [opened, synchronize, reopened, ready_for_review] +# paths: +# - '$QUICKSTART_PATH/**' + +jobs: + Test-build-default-matrix: + name: ${{ env.QUICKSTART_PATH }} - BUILD DEFAULT - JDK${{ matrix.jdk }} - ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + jdk: [11, 17] + os: [ubuntu-20.04, windows-latest] + steps: + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + - uses: actions/checkout@v2 + with: + path: quickstarts + - name: Set up JDK ${{ matrix.java }} + uses: AdoptOpenJDK/install-jdk@v1 + with: + version: ${{ matrix.jdk }} + impl: hotspot + - name: Build ${{ env.QUICKSTART_PATH }} Quickstart for Release + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + mvn -U -B -fae clean install -Drelease + shell: bash + - name: Build, run & test ${{ env.QUICKSTART_PATH }} Quickstart with provisioned-server profile + if: ${{ env.MICROPROFILE == 'false' }} + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + echo "Building provisioned server..." + mvn -U -B -fae clean package -Pprovisioned-server + echo "Starting provisioned server..." + mvn -U -B -fae wildfly:start -DjbossHome=target/server + echo "Testing provisioned server..." + mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing + echo "Shutting down provisioned server..." + mvn -U -B -fae wildfly:shutdown + shell: bash + - name: Build, run & test ${{ env.QUICKSTART_PATH }} Quickstart with bootable-jar profile + if: ${{ env.MICROPROFILE == 'true' }} + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + echo "Building bootable jar..." + mvn -U -B -fae clean package -Pbootable-jar + echo "Starting bootable jar..." + mvn -U -B -fae wildfly-jar:start -Djar-file-name=target/${{ env.QUICKSTART_PATH }}-bootable.jar + echo "Testing bootable jar..." + mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing + echo "Shutting down bootable jar..." + mvn -U -B -fae wildfly-jar:shutdown + shell: bash + - name: Build ${{ env.QUICKSTART_PATH }} Quickstart with openshift profile + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + mvn -U -B -fae clean package -Popenshift + shell: bash + - uses: actions/upload-artifact@v3 + if: failure() + with: + name: surefire-reports-JDK${{ matrix.jdk }}-${{ matrix.os }} + path: 'quickstarts/$QUICKSTART_PATH/**/surefire-reports/*.txt' \ No newline at end of file diff --git a/.github/workflows/quickstart_microprofile-config_ci.yml b/.github/workflows/quickstart_microprofile-config_ci.yml new file mode 100644 index 0000000000..4af634e388 --- /dev/null +++ b/.github/workflows/quickstart_microprofile-config_ci.yml @@ -0,0 +1,78 @@ +name: WildFly ${{ env.QUICKSTART_PATH }} Quickstart CI + +env: + QUICKSTART_PATH: microprofile-config + MICROPROFILE: true + +on: + pull_request: + types: [opened, synchronize, reopened, ready_for_review] +# paths: +# - '$QUICKSTART_PATH/**' + +jobs: + Test-build-default-matrix: + name: ${{ env.QUICKSTART_PATH }} - BUILD DEFAULT - JDK${{ matrix.jdk }} - ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + jdk: [11, 17] + os: [ubuntu-20.04, windows-latest] + steps: + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + - uses: actions/checkout@v2 + with: + path: quickstarts + - name: Set up JDK ${{ matrix.java }} + uses: AdoptOpenJDK/install-jdk@v1 + with: + version: ${{ matrix.jdk }} + impl: hotspot + - name: Build ${{ env.QUICKSTART_PATH }} Quickstart for Release + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + mvn -U -B -fae clean install -Drelease + shell: bash + - name: Build, run & test ${{ env.QUICKSTART_PATH }} Quickstart with provisioned-server profile + if: ${{ env.MICROPROFILE == 'false' }} + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + echo "Building provisioned server..." + mvn -U -B -fae clean package -Pprovisioned-server + echo "Starting provisioned server..." + mvn -U -B -fae wildfly:start -DjbossHome=target/server + echo "Testing provisioned server..." + mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing + echo "Shutting down provisioned server..." + mvn -U -B -fae wildfly:shutdown + shell: bash + - name: Build, run & test ${{ env.QUICKSTART_PATH }} Quickstart with bootable-jar profile + if: ${{ env.MICROPROFILE == 'true' }} + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + echo "Building bootable jar..." + mvn -U -B -fae clean package -Pbootable-jar + echo "Starting bootable jar..." + mvn -U -B -fae wildfly-jar:start -Djar-file-name=target/${{ env.QUICKSTART_PATH }}-bootable.jar + echo "Testing bootable jar..." + mvn -U -B -fae verify -Dserver.host=http://localhost:8080 -Pintegration-testing + echo "Shutting down bootable jar..." + mvn -U -B -fae wildfly-jar:shutdown + shell: bash + - name: Build ${{ env.QUICKSTART_PATH }} Quickstart with openshift profile + run: | + cd quickstarts + cd ${{ env.QUICKSTART_PATH }} + mvn -U -B -fae clean package -Popenshift + shell: bash + - uses: actions/upload-artifact@v3 + if: failure() + with: + name: surefire-reports-JDK${{ matrix.jdk }}-${{ matrix.os }} + path: 'quickstarts/$QUICKSTART_PATH/**/surefire-reports/*.txt' \ No newline at end of file