Verify Staged Artifacts #14
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: Verify Staged Artifacts | |
on: | |
workflow_dispatch: | |
inputs: | |
releaseVersion: | |
description: 'Release version like 5.0.0-M1, 5.1.0-RC1, 5.2.0 etc.' | |
required: true | |
type: string | |
env: | |
ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }} | |
ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }} | |
jobs: | |
verify-staged-with-sample: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Sample Directory | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref_name }} | |
sparse-checkout: 'samples/time-spel-log' | |
sparse-checkout-cone-mode: false | |
show-progress: false | |
- name: Set up Gradle | |
uses: spring-io/spring-gradle-build-action@v2 | |
- name: Prepare Sample project against Staging | |
run: | | |
cd samples/time-spel-log | |
printf "allprojects { | |
repositories { | |
maven { | |
url 'https://repo.spring.io/libs-staging-local' | |
credentials { | |
username = '$ARTIFACTORY_USERNAME' | |
password = '$ARTIFACTORY_PASSWORD' | |
} | |
} | |
} | |
}" > staging-repo-init.gradle | |
sed -i "1,/springFunctionsCatalogVersion.*/s/springFunctionsCatalogVersion.*/springFunctionsCatalogVersion='${{ inputs.releaseVersion }}'/" build.gradle | |
- name: Verify time-spel-log sample against staged release | |
run: cd samples/time-spel-log && gradle check --init-script staging-repo-init.gradle |