nr-ebpf-agent-1.4.8 #310
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Post-Release Tasks (nr-k8s-otel-collector) | |
| on: | |
| release: | |
| types: [released] | |
| env: | |
| ORIGINAL_REPO_NAME: ${{ github.event.repository.full_name }} | |
| RELEASE_FILE: RELEASE.md | |
| jobs: | |
| release-notes: | |
| if: startsWith(github.event.release.tag_name, 'nr-k8s-otel-collector-') | |
| name: Publish release notes | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Create release notes | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh pr list --search "${{ github.event.release.target_commitish }}" --state merged --json title,body,number | |
| scripts/get-pr-release-notes.sh ${{ github.event.release.target_commitish }} ${{ env.RELEASE_FILE }} | |
| gh release edit ${{ github.event.release.tag_name }} \ | |
| --notes-file ${{ env.RELEASE_FILE }} | |
| announce-release: | |
| if: startsWith(github.event.release.tag_name, 'nr-k8s-otel-collector-') | |
| name: Announce K8s OTEL release | |
| runs-on: ubuntu-latest | |
| needs: release-notes | |
| steps: | |
| - name: Notify release via Slack | |
| uses: archive/github-actions-slack@v3.1.0 | |
| with: | |
| slack-bot-user-oauth-access-token: ${{ secrets.K8S_AGENTS_SLACK_TOKEN }} | |
| slack-channel: ${{ secrets.HELP_K8S_AGENTS_SLACK_CHANNEL }} | |
| slack-text: "A new release of the New Relic Kubernetes OpenTelemetry Collector chart is available: <${{ github.event.release.html_url }}|${{ github.event.release.tag_name }}>" | |
| notify-failure: | |
| if: ${{ always() && failure() }} | |
| needs: [release-notes,announce-release] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Notify failure via Slack | |
| uses: archive/github-actions-slack@v3.1.0 | |
| with: | |
| slack-bot-user-oauth-access-token: ${{ secrets.K8S_AGENTS_SLACK_TOKEN }} | |
| slack-channel: ${{ secrets.K8S_AGENTS_SLACK_CHANNEL }} | |
| slack-text: "❌ `${{ env.ORIGINAL_REPO_NAME }}`: <${{ github.server_url }}/${{ env.ORIGINAL_REPO_NAME }}/actions/runs/${{ github.run_id }}|'Post Release Tasks (nr-k8s-otel-collector)' failed>." |