[ACA-4653] Migrate release workflow to GHA (#3027)

* [ACA-4653] Run ACA upstream on schedule

* [ACA-4653] Migrate release workflow to GHA

* [ACA-4653] Consistency in naming

* [ACA-4653] Use GH action to configure GH author

* [ACA-4653] Dedicated sh for publish Docker image job

* [ACA-4653] Add missing variables

* [ACA-4653] Delete Travis.yml

* [ACA-4653] CR fixes

* [ACA-4653] Add branch name as action input

* [ACA-4653] Proper env var usage in workflow
This commit is contained in:
MichalKinas
2023-03-03 12:40:37 -05:00
committed by GitHub
parent 3294606fc0
commit e38e72a8e0
10 changed files with 394 additions and 129 deletions
+36
View File
@@ -0,0 +1,36 @@
name: "Publish Docker Images"
description: "Publish Docker image to quay.io or dockerhub or another domain - only publish the version on master - elsewhere version and branch"
inputs:
domain:
description: 'domain to publish image to'
required: true
type: string
username:
description: 'login username'
required: true
type: string
password:
description: 'login password'
required: true
type: string
dry-run:
description: dry run flag
required: true
type: boolean
runs:
using: "composite"
steps:
- name: Get docker image tag name
shell: bash
run: |
if [[ $BRANCH_NAME == "master" ]]; then
TAG_VERSION=$(grep -m1 version package.json | awk '{ print $2 }' | sed 's/[", ]//g')
else
TAG_VERSION=$BRANCH_NAME-${{ github.run_id }}
fi
echo "TAG_VERSION=$TAG_VERSION" >> $GITHUB_ENV
- name: Publish image
shell: bash
run: ./scripts/travis/deploy/publish.sh ${{ inputs.domain }} ${{ inputs.username }} ${{ inputs.password }} $TAG_VERSION $BRANCH_NAME ${{ inputs.dry-run }}