Skip to content

Test release process nightly #760

Test release process nightly

Test release process nightly #760

name: Test release process nightly
on:
schedule:
- cron: "0 0 * * *" # Run every day at midnight (UTC)
workflow_dispatch: # Allow running manually on demand
env:
RELEASE_TAG: v9.9.9-fake
GH_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
jobs:
nightly-test-release:
name: Test release
strategy:
fail-fast: false
matrix:
branch: [ main, release-0.23]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
ref: ${{ matrix.branch }}
fetch-depth: 0
- name: Set env
run: echo "RELEASE_TAG=v9.9.9-fake" >> $GITHUB_ENV
- name: Set fake tag for release
run: |
git tag ${{ env.RELEASE_TAG }}
- name: setupGo
uses: actions/[email protected]
with:
go-version-file: go.mod
- name: Test release
run: |
make release
notify-failure:
name: Notify failure in Slack
needs: [nightly-test-release]
if: ${{ failure() || cancelled() }}
runs-on: ubuntu-latest
steps:
- uses: slackapi/[email protected]
with:
payload: |
{
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "Rancher turtles RELEASE test failed."
},
"accessory": {
"type": "button",
"text": {
"type": "plain_text",
"text": ":github:",
"emoji": true
},
"url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
}
]
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK