chore(release): release the Identus documentation portal 1.102.1 #177
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: Deployment | |
# Trigger deployment when a new tag is pushed | |
# to a service component | |
on: | |
workflow_call: | |
inputs: | |
version: | |
required: true | |
type: string | |
env: | |
required: false | |
type: string | |
default: "staging" | |
workflow_dispatch: | |
inputs: | |
version: | |
description: "Document tag to deploy, e.g v1.76.1" | |
required: true | |
env: | |
description: "Target environment: staging or production" | |
required: false | |
default: "staging" | |
push: | |
tags: | |
- "v*" | |
permissions: | |
contents: write | |
jobs: | |
trigger-deployment: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Parse input parameters | |
id: parse-params | |
run: | | |
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then | |
echo "VERSION=${{ github.event.inputs.version }}" >> "${GITHUB_OUTPUT}" | |
echo "ENV=${{ github.event.inputs.env }}" >> "${GITHUB_OUTPUT}" | |
elif [[ "${{ github.event_name }}" == "workflow_call" ]]; then | |
echo "VERSION=${{ inputs.version }}" >> "${GITHUB_OUTPUT}" | |
echo "ENV=${{ inputs.env }}" >> "${GITHUB_OUTPUT}" | |
else | |
echo "VERSION=${GITHUB_REF#refs/tags/}" >> "${GITHUB_OUTPUT}" | |
echo "ENV=staging" >> "${GITHUB_OUTPUT}" | |
fi | |
- name: Trigger deployment | |
uses: peter-evans/repository-dispatch@v3 | |
with: | |
token: ${{ secrets.ATALA_GITHUB_TOKEN }} # Personal access token that triggers the deployment (Hyperledger => IOG) | |
repository: input-output-hk/atala-prism-non-prod-argocd-state | |
event-type: trigger-prism-documentation-deployment | |
client-payload: '{"version": "${{ steps.parse-params.outputs.VERSION }}", "env": "${{ steps.parse-params.outputs.ENV }}"}' |