Only use armory sdk (#524) #15
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: '@app/armory Production CI' | |
on: | |
push: | |
tags: | |
- armory-v* | |
jobs: | |
release: | |
name: Release Prod | |
runs-on: ubuntu-latest | |
permissions: | |
id-token: write | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure AWS credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ vars.ACTIONS_ECR_ROLE_ARN }} # Organization variable | |
aws-region: ${{ vars.ACTIONS_ECR_REGION }} # Organization variable | |
- name: Login to Amazon ECR | |
id: login-ecr | |
uses: aws-actions/amazon-ecr-login@v2 | |
- name: Get short SHA | |
id: slug | |
run: echo "sha7=${GITHUB_SHA::7}" >> $GITHUB_ENV | |
# Strip the "armory-v" prefix from the tag, so we just get the version number | |
- name: Get tag | |
id: tag | |
run: echo "tag=${GITHUB_REF#refs/*/armory-v}" >> $GITHUB_OUTPUT | |
- name: Promote image to production version tag | |
uses: abronin/ecr-retag-action@v1 | |
with: | |
repository: armory/armory | |
tag: ${{ env.sha7 }} | |
new-tags: ${{ steps.tag.outputs.tag }} | |
- id: update-helm-version | |
name: 'Update Helm Version' | |
uses: ./.github/actions/update-helm-version | |
with: | |
appId: ${{ vars.NARVAL_HELM_APP_ID }} | |
privateKey: ${{ secrets.NARVAL_HELM_PRIVATE_KEY }} | |
valueFile: 'apps/charts/armory/values-prod.yaml' | |
propertyPath: 'image.tag' | |
value: ${{ steps.tag.outputs.tag }} | |
message: 'Update Armory Production Image Version to ${{ steps.tag.outputs.tag }}' | |
- name: Send Slack notification on failure | |
if: failure() | |
uses: 8398a7/action-slack@v3 | |
with: | |
username: GitHub | |
author_name: '@app/armory Production CI release failed' | |
status: ${{ job.status }} | |
fields: message,commit,author | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} |