diff --git a/.github/workflows/notify-integration-release-via-manual.yaml b/.github/workflows/notify-integration-release-via-manual.yaml index f12f301..1ba92c8 100644 --- a/.github/workflows/notify-integration-release-via-manual.yaml +++ b/.github/workflows/notify-integration-release-via-manual.yaml @@ -1,15 +1,9 @@ -name: Notify Integration Release (Manual) +name: Notify Integration Release (Tag) on: - workflow_dispatch: - inputs: - version: - description: "The release version (semver)" - default: 0.0.1 - required: false - branch: - description: "A branch or SHA" - default: 'main' - required: false + push: + tags: + - '*.*.*' # Proper releases + - '*.*.*-*' # Pre releases jobs: notify-release: runs-on: ubuntu-latest @@ -17,7 +11,7 @@ jobs: - name: Checkout this repo uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 with: - ref: ${{ github.event.inputs.branch }} + ref: ${{ github.ref }} # Ensure that Docs are Compiled - uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0 - shell: bash @@ -40,7 +34,7 @@ jobs: - name: Notify Release uses: ./integration-release-action with: - integration_identifier: "packer/hashicorp/oneandone" - release_version: ${{ github.event.inputs.version }} - release_sha: ${{ github.event.inputs.branch }} + integration_identifier: 'packer/hashicorp/oneandone' + release_version: ${{ github.ref_name }} + release_sha: ${{ github.ref }} github_token: ${{ secrets.GITHUB_TOKEN }}