Switch notification to be per workflow instead of per action. This means that CI jobs that want to check the result of the binary publish step will need to do so manually after the step runs. --- #### Does this PR need a docs update or release note? - [ ] ✅ Yes, it's included - [ ] 🕐 Yes, but in a later PR - [x] ⛔ No #### Type of change - [ ] 🌻 Feature - [x] 🐛 Bugfix - [ ] 🗺️ Documentation - [ ] 🤖 Supportability/Tests - [x] 💻 CI/Deployment - [ ] 🧹 Tech Debt/Cleanup #### Issue(s) * closes #4758 #### Test Plan - [ ] 💪 Manual - [ ] ⚡ Unit test - [ ] 💚 E2E
45 lines
1.3 KiB
YAML
45 lines
1.3 KiB
YAML
name: Publish binary
|
|
on:
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
SetEnv:
|
|
environment: Testing
|
|
runs-on: ubuntu-latest
|
|
outputs:
|
|
version: ${{ steps.version.outputs.version }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Get version string
|
|
id: version
|
|
run: |
|
|
if ${{ startsWith(github.ref, 'refs/tags/') }}; then
|
|
echo "version=$(git describe --exact-match --tags $(git rev-parse HEAD))" | tee -a $GITHUB_OUTPUT
|
|
else
|
|
echo "version=$(echo unreleased-$(git rev-parse --short HEAD))" | tee -a $GITHUB_OUTPUT
|
|
fi
|
|
|
|
Publish-Binary:
|
|
needs: [SetEnv]
|
|
environment: Testing
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Publish Binary
|
|
uses: ./.github/actions/publish-binary
|
|
with:
|
|
version: ${{ needs.SetEnv.outputs.version }}
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
rudderstack_write_key: ${{ secrets.RUDDERSTACK_CORSO_WRITE_KEY }}
|
|
rudderstack_data_plane_url: ${{ secrets.RUDDERSTACK_CORSO_DATA_PLANE_URL }}
|
|
|
|
- name: Notify failure in teams
|
|
if: failure()
|
|
uses: ./.github/actions/teams-message
|
|
with:
|
|
msg: "[FAILED] Publishing Binary"
|
|
teams_url: ${{ secrets.TEAMS_CORSO_CI_WEBHOOK_URL }}
|