Promote to Stage #5
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: Promote to Stage | |
permissions: | |
# This is required for requesting the OIDC token | |
id-token: write | |
on: | |
workflow_dispatch: | |
inputs: | |
build-number: | |
type: number | |
description: Build number used to build artifact to be promoted | |
jobs: | |
validate-build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup jfrog shell | |
uses: jfrog/setup-jfrog-cli@v4 | |
env: | |
JF_URL: ${{ vars.JFROG_PLATFORM_URL }} | |
with: | |
oidc-provider-name: ${{ secrets.JFROG_OIDC_PROVIDER }} | |
oidc-audience: ${{ secrets.JFROG_OIDC_AUDIENCE }} | |
- name: Get info | |
id: get-build-info | |
run: | | |
echo build-info=$(jf rt curl /api/build/clients-java-push-to-dev/${{ inputs.build-number }}) >> $GITHUB_OUTPUT | |
- name: Get commit hash | |
id: get-commit-hash | |
run: | | |
echo build-commit-hash=$(steps.get-build-info.outputs.build-info | jq -r '.vcs[].revision') >> $GITHUB_OUTPUT | |
- name: Debug | |
run: | | |
echo ${{ steps.get-commit-hash.outputs.build-commit-hash }} |