Skip to content

Commit

Permalink
ci: update major release tag
Browse files Browse the repository at this point in the history
Signed-off-by: Rishav Dhar <[email protected]>
  • Loading branch information
rdhar committed Sep 13, 2024
1 parent 68511cc commit 7fa364a
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 3 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/ci_release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
name: CI Release Tag

on:
release:
types: [created]

jobs:
tag:
runs-on: ubuntu-24.04

steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
persist-credentials: false

- name: Fetch major version tag and update it
shell: bash
run: |
VERSION=${GITHUB_REF#refs/tags/}
MAJOR=${VERSION%%.*}
git config --global user.name 'Rishav Dhar'
git config --global user.email '[email protected]'
git tag -fa "${MAJOR}" -m 'Update major version tag'
git push origin "${MAJOR}" --force
6 changes: 4 additions & 2 deletions .github/workflows/tf_sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ env:
TF_VAR_PREFIX: sample

jobs:
TF:
runs-on: ubuntu-latest
iac:
runs-on: ubuntu-24.04

permissions:
actions: read # Required to download repository artifact.
Expand All @@ -35,6 +35,8 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
persist-credentials: false

- name: Authenticate AWS
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/tf_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
tests:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

permissions:
actions: read # Required to download repository artifact.
Expand Down Expand Up @@ -40,6 +40,8 @@ jobs:

- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
persist-credentials: false

- name: Provision TF
id: tf
Expand Down

0 comments on commit 7fa364a

Please sign in to comment.