Manual release dispatch workflow #36
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Manual release dispatch workflow | |
on: | |
workflow_dispatch: | |
inputs: | |
alfresco-deployment-service-version: | |
description: 'Version for alfresco-deployment-service' | |
required: true | |
default: '7.19.0-alpha.190' | |
alfresco-modeling-service-version: | |
description: 'Version for alfresco-modeling-service' | |
required: true | |
default: '7.19.0-alpha.190' | |
alfresco-process-version: | |
description: 'Version for alfresco-process' | |
required: true | |
default: '7.19.0-alpha.102' | |
activiti-cloud-version: | |
description: 'Version for activiti-cloud' | |
required: true | |
default: '8.7.0-alpha.43' | |
tag-name: | |
description: 'Tag name for the release' | |
required: true | |
default: 'v7.19.0-alpha.93' | |
env: | |
MAVEN_PASSWORD: ${{ secrets.NEXUS_PASSWORD }} | |
MAVEN_USERNAME: ${{ secrets.NEXUS_USERNAME }} | |
MAVEN_CLI_OPTS: >- | |
--settings settings.xml | |
-V --no-transfer-progress -Dspring.main.banner-mode=off -Ddoclint=none | |
-Denvironment.host=${{ vars.ENVIRONMENT_HOST }} | |
-Denvironment.apa.host=${{ vars.ENVIRONMENT_APA_HOST }} | |
-Denvironment.application.name=${{ vars.ENVIRONMENT_APP }} | |
jobs: | |
pre-checks: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0 | |
- name: Check dependabot build | |
uses: Activiti/Activiti/.github/actions/check-ext-build@7700f0283a9ff5181581a350d2520e55c61c1c60 # 8.6.0 | |
- name: pre-commit | |
uses: Alfresco/alfresco-build-tools/.github/actions/pre-commit@209bb4275688720e13dc0703dbd17826bf677c5c # v6.1.0 | |
with: | |
skip_checkout: true | |
- name: Ensure SHA pinned actions | |
uses: zgosalvez/github-actions-ensure-sha-pinned-actions@b8f9a25a51fe633d9215ac7734854dc11cd299cb # v3.0.13 | |
set-versions-and-create-release-branch: | |
runs-on: ubuntu-latest | |
needs: | |
- pre-checks | |
steps: | |
- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0 | |
with: | |
ref: develop | |
- name: Create new release branch | |
run: | | |
git checkout -b release/${{ github.event.inputs.tag-name }} | |
git branch -M release/${{ github.event.inputs.tag-name }} | |
- name: Update versions in pom.xml | |
run: | | |
mvn versions:set-property -Dproperty=alfresco-deployment-service.version -DnewVersion=${{ github.event.inputs.alfresco-deployment-service-version }} -DgenerateBackupPoms=false | |
mvn versions:set-property -Dproperty=alfresco-modeling-service.version -DnewVersion=${{ github.event.inputs.alfresco-modeling-service-version }} -DgenerateBackupPoms=false | |
mvn versions:set-property -Dproperty=alfresco-process.version -DnewVersion=${{ github.event.inputs.alfresco-process-version }} -DgenerateBackupPoms=false | |
mvn versions:set-property -Dproperty=activiti-cloud.version -DnewVersion=${{ github.event.inputs.activiti-cloud-version }} -DgenerateBackupPoms=false | |
mvn versions:set -DnewVersion=${{ github.event.inputs.tag-name }} -DgenerateBackupPoms=false | |
- name: Commit Changes | |
env: | |
VERSION: ${{ github.event.inputs.tag-name }} | |
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: Push changes | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
git push | |
- name: Create Pull Request | |
run: | | |
gh pr create --title "Release ${{ github.event.inputs.tag-name }}" --body "This is an automated pull request to release version ${{ github.event.inputs.tag-name }}." --head release/${{ github.event.inputs.tag-name }} --base develop | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |