Skip to content

Commit

Permalink
adapt autocommit workflow for marlowe-runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
tshaynik committed Nov 14, 2023
1 parent abfaef3 commit b33bacf
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions .github/workflows/autocommit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ on:
push:
branches:
- main
- production
- PLT-6842-autodeploy
create:
tags:
- '*'

jobs:
run:
Expand All @@ -14,19 +17,21 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v2
with:
ref: main
# ref: main
ref: PLT-6842-autodeploy

- name: Update publish version
id: update
run: |
VERSION=${GITHUB_SHA::8}
if [ "$GITHUB_REF" = refs/heads/production ]; then
TYPE=production
if [ "${{ github.event_name }}" = push ]; then
TYPE=qa
else
TYPE=staging
TYPE=demo
fi
echo ::set-output name=VERSION::${VERSION}
sed -i "s|${TYPE}Tag:.*|${TYPE}Tag: \"$VERSION\"|g" deploy/values.yaml
echo name=VERSION::${VERSION} >> $GITHUB_OUTPUT
yq e -i '.instances.${TYPE}.tag = "${VERSION}"' deploy/marlowe-runtime/values.yaml
yq e -i '.instances.${TYPE}.webTag = "${VERSION}"' deploy/marlowe-runtime/values.yaml
- name: Commit changes
uses: EndBug/add-and-commit@v7
Expand Down

0 comments on commit b33bacf

Please sign in to comment.