Skip to content

Gen Latest Dev Snapshot - MCE 2.6 #244

Gen Latest Dev Snapshot - MCE 2.6

Gen Latest Dev Snapshot - MCE 2.6 #244

name: Gen Latest Dev Snapshot - MCE 2.6
on:
workflow_dispatch: {}
schedule:
- cron: '0 9 * * *' # 5:00AM EST every day (UTC-4) - 4 hours after 2.15
- cron: '0 15 * * *' # 11:00AM EST every day (UTC-4) - 4 hours after 2.15
- cron: '30 22 * * *' # 6:30PM EST every day (UTC-4) - 30 min before 2.15 last run
- cron: '0 3 * * *' # 11:00PM EST every day (UTC-4) - 4 hours before 2.15
jobs:
snapshot:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
branch: ['backplane-2.6']
include:
- branch: backplane-2.6
release-plan: "dev-publish-mce-26"
steps:
- name: Checkout tooling branch
uses: actions/checkout@v3
with:
ref: tooling
# Run the snapshot collector script and create a PR with the latest snapshot in the correct branch
- name: Run snapshot collection and file handling
env:
SA_TOKEN: ${{ secrets.KONFLUX_SERVICE_ACCOUNT_TOKEN }}
run: |
chmod +x snapshot-collector.sh
./snapshot-collector.sh ${{ matrix.release-plan }} "$SA_TOKEN"
- name: Generate GitHub token for workflow actions
id: gen-workflow-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.WORKFLOW_BOT_APP_ID }}
private-key: ${{ secrets.WORKFLOW_BOT_PRIVATE_KEY }}
owner: ${{ github.repository_owner }}
# Create Pull Request
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
branch: "update-snapshot-${{ matrix.branch }}"
base: "${{ matrix.branch }}"
delete-branch: true
title: "Gen Latest Snapshot [${{ matrix.branch }}]"
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
token: ${{ steps.gen-workflow-token.outputs.token }}