Skip to content

PIPELINE-81/PIPELINE-79: Use re-usable workflow for tests and release… #184

PIPELINE-81/PIPELINE-79: Use re-usable workflow for tests and release…

PIPELINE-81/PIPELINE-79: Use re-usable workflow for tests and release… #184

Workflow file for this run

# This workflow is triggered every time a change is pushed to any branches
# Github actions command reference: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions
name: On merge to master
# The workflow could also be triggered on PRs
on:
push:
branches:
- 'master'
tags-ignore:
- '**'
jobs:
update-signature:
name: Update module signature
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: jahia/jahia-modules-action/update-signature@v2
with:
nexus_username: ${{ secrets.NEXUS_USERNAME }}
nexus_password: ${{ secrets.NEXUS_PASSWORD }}
build:
name: Build Module
needs: update-signature
runs-on: self-hosted
env:
NEXUS_INTERNAL_URL: ${{ secrets.NEXUS_INTERNAL_URL }}
container:
image: jahia/cimg-mvn-cache:ga_cimg_openjdk_11.0.20-node
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
steps:
- uses: actions/checkout@v4
- uses: jahia/jahia-modules-action/build@v2
with:
mvn_settings_filepath: '.github/maven.settings.xml'
nexus_username: ${{ secrets.NEXUS_USERNAME }}
nexus_password: ${{ secrets.NEXUS_PASSWORD }}
sbom:
name: SBOM processing
needs: build
runs-on: ubuntu-latest
container:
image: cyclonedx/cyclonedx-cli:0.24.2
steps:
- uses: jahia/jahia-modules-action/sbom-processing@v2
with:
dependencytrack_hostname: ${{ vars.DEPENDENCYTRACK_HOSTNAME }}
dependencytrack_apikey: ${{ secrets.DEPENDENCYTRACK_APIKEY }}
sbom_artifacts: 'build-artifacts'
integration-tests-standalone:
uses: Jahia/jahia-modules-action/.github/workflows/integration-tests.yml@v2
needs: build
secrets: inherit
with:
jahia_image: jahia/jahia-ee-dev:8-SNAPSHOT
module_id: graphql-dxm-provider
testrail_project: GraphQL Core module
pagerduty_skip_notification: true
provisioning_manifest: provisioning-manifest-build.yml
should_use_build_artifacts: true
pagerduty_incident_service: graphql-dxm-provider-JahiaSN
artifact_prefix: gql
publish:
name: Publish module
needs: [build]
if: github.ref == 'refs/heads/master'
runs-on: self-hosted
container:
image: jahia/cimg-mvn-cache:ga_cimg_openjdk_11.0.20-node
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
steps:
- uses: actions/checkout@v4
- uses: jahia/jahia-modules-action/publish@v2
with:
nexus_username: ${{ secrets.NEXUS_USERNAME }}
nexus_password: ${{ secrets.NEXUS_PASSWORD }}
mvn_settings_filepath: '.github/maven.settings.xml'