hvm: v0.126.5 #1073
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
on: | |
release: | |
types: [published] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
name: api-release-prod | |
jobs: | |
check-api-released: | |
runs-on: [ARM64, self-hosted, Linux] | |
steps: | |
- name: Check Release | |
id: api_released | |
uses: actions/github-script@v5 | |
with: | |
result-encoding: string | |
script: return context.ref.includes('refs/tags/api-v') | |
outputs: | |
api_released: ${{ steps.api_released.outputs.result }} | |
release-api: | |
runs-on: [ARM64, self-hosted, Linux] | |
if: ${{ needs.check-api-released.outputs.api_released == 'true' }} | |
needs: | |
- check-api-released | |
permissions: | |
id-token: write | |
contents: read | |
steps: | |
- name: Assume happy-api deployement role | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-region: us-west-2 | |
role-to-assume: ${{ secrets.AWS_ROLE_TO_ASSUME_PROD }} | |
role-duration-seconds: 1200 | |
role-session-name: HappyApiUpdateProd | |
- name: Parse Version | |
id: parse_version | |
uses: actions/github-script@v5 | |
with: | |
result-encoding: string | |
script: return context.ref.replace('refs/tags/api-', '') | |
- name: Update prod | |
uses: chanzuckerberg/github-actions/.github/actions/[email protected] | |
with: | |
tfe-token: ${{ secrets.TFE_TOKEN }} | |
env: prod | |
create-tag: true | |
stack-name: hapi | |
working-directory: api | |
version-lock-file: api/.happy/version.lock | |
env: | |
RELEASE_VERSION: ${{ steps.parse_version.outputs.result }} | |
create_and_release_jira_version: | |
# only run for api releases | |
if: ${{ needs.check-api-released.outputs.api_released == 'true' }} | |
needs: | |
- check-api-released | |
- release-api # we need to wait for the release to finish before creating the jira version | |
uses: chanzuckerberg/github-actions/.github/workflows/[email protected] | |
with: | |
projectID: '10006' | |
projectKey: CCIE | |
jiraVersionPrefix: 'Happy' | |
secrets: | |
jiraToken: ${{ secrets.JIRA_TOKEN }} |