We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 507c98b commit 46e60f3Copy full SHA for 46e60f3
.github/workflows/latest.yml
@@ -38,14 +38,22 @@ jobs:
38
needs: [ docker-latest ]
39
runs-on: ubuntu-latest
40
steps:
41
+
42
+ - name: Get current branch
43
+ id: branch
44
+ run: |
45
+ echo "branch_name=${GITHUB_REF#refs/heads/}" >> $GITHUB_OUTPUT
46
47
- name: Trigger AWS Kubernetes deployment
48
uses: actions/github-script@v6
49
+ env:
50
+ BRANCH: ${{ steps.branch.outputs.branch_name }}
51
with:
52
github-token: ${{ secrets.GITHUB_TOKEN }}
53
script: |
54
await github.rest.actions.createWorkflowDispatch({
55
owner: context.repo.owner,
56
repo: context.repo.repo,
57
workflow_id: 'kubernetes-deploy-to-cluster.yml',
- ref: 'main'
58
+ ref: process.env.BRANCH
59
})
0 commit comments