Skip to content

Commit

Permalink
Refactor with github.ref_name and github.ref_type (#833)
Browse files Browse the repository at this point in the history
  • Loading branch information
int128 authored Jan 4, 2023
1 parent 26d3f24 commit f8886b4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ jobs:
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- run: kustomize edit set image controller="ghcr.io/int128/argocd-commenter:${GITHUB_REF##*/}"
- run: kustomize edit set image controller='ghcr.io/${{ github.repository }}:${{ github.ref_name }}'
working-directory: config/manager
- run: kustomize build config/default > /tmp/argocd-commenter.yaml
- run: cat /tmp/argocd-commenter.yaml

- run: gh release upload "${GITHUB_REF##*/}" /tmp/argocd-commenter.yaml --clobber
if: github.event_name == 'push'
- if: github.ref_type == 'tag'
run: gh release upload '${{ github.ref_name }}' /tmp/argocd-commenter.yaml --clobber
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit f8886b4

Please sign in to comment.