From 590114d46bd3a40bb78e096a90ac9dbe355263c7 Mon Sep 17 00:00:00 2001 From: Wojtek Piotrowiak Date: Wed, 2 Oct 2024 14:48:32 +0200 Subject: [PATCH] AAE-26208 Manual release (#2328) AAE-26208 Manual release --- .github/workflows/release.yml | 69 +++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..8199050d8 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,69 @@ +name: Dispatch Workflow + +on: + workflow_dispatch: + inputs: + alfresco-deployment-service-version: + description: 'Version for alfresco-deployment-service' + required: true + default: '7.19.0-alpha.179' + alfresco-modeling-service-version: + description: 'Version for alfresco-modeling-service' + required: true + default: '7.19.0-alpha.179' + alfresco-process-version: + description: 'Version for alfresco-process' + required: true + default: '7.19.0-alpha.93' + activiti-cloud-version: + description: 'Version for activiti-cloud' + required: true + default: '8.7.0-alpha.37' + tag-name: + description: 'Tag name for the release' + required: true + default: 'v7.19.0-alpha.93' + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 + + - name: Set up JDK 21 + uses: actions/setup-java@2dfa2011c5b2a0f1489bf9e433881c92c1631f88 # v4.3.0 + with: + java-version: '21' + distribution: 'temurin' + + - name: Update versions in pom.xml + run: | + mvn versions:set-property -Dproperty=alfresco-deployment-service.version -DnewVersion=${{ github.event.inputs.alfresco-deployment-service-version }} + mvn versions:set-property -Dproperty=alfresco-modeling-service.version -DnewVersion=${{ github.event.inputs.alfresco-modeling-service-version }} + mvn versions:set-property -Dproperty=alfresco-process.version -DnewVersion=${{ github.event.inputs.alfresco-process-version }} + mvn versions:set-property -Dproperty=activiti-cloud.version -DnewVersion=${{ github.event.inputs.activiti-cloud-version }} + mvn versions:set -DnewVersion=${{ github.event.inputs.tag-name }} + + - name: Build and verify code + run: mvn clean verify + + - name: Commit Changes + uses: Alfresco/alfresco-build-tools/.github/actions/git-commit-changes@9d00215f539f669b41c7fabf7b88ccc8f316926c # v6.0.1 + with: + username: ${{ secrets.BOT_GITHUB_USERNAME }} + commit-message: "Release ${VERSION}" + add-options: "." + + - name: Create GitHub tag + run: | + git tag ${{ github.event.inputs.tag-name }} + git push origin ${{ github.event.inputs.tag-name }} + + - name: Create Release + env: + GITHUB_TOKEN: ${{ secrets.BOT_GITHUB_TOKEN }} + VERSION: ${{ github.event.inputs.tag-name }} + run: | + gh release create ${VERSION} --title ${VERSION} --notes "Release ${VERSION}" --target ${VERSION}