Sync Perses Dashboards #58
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: Sync Perses Dashboards | |
| on: | |
| schedule: | |
| - cron: '0 6 * * *' | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| sync: | |
| name: Check for upstream dashboard updates | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 | |
| with: | |
| persist-credentials: false | |
| - uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # v5.6.0 | |
| with: | |
| go-version-file: go.mod | |
| - name: Update upstream dependency | |
| run: | | |
| go get github.com/stolostron/multicluster-observability-addon/pkg/perses@latest | |
| go mod tidy | |
| - name: Regenerate dashboards | |
| run: make generate-perses-dashboards | |
| - name: Check for changes | |
| id: changes | |
| run: | | |
| if [ -n "$(git status --porcelain dashboards/perses/ go.mod go.sum)" ]; then | |
| echo "changed=true" >> "$GITHUB_OUTPUT" | |
| else | |
| echo "changed=false" >> "$GITHUB_OUTPUT" | |
| fi | |
| - name: Create pull request | |
| if: steps.changes.outputs.changed == 'true' | |
| uses: peter-evans/create-pull-request@22a9089034f40e5a961c8808d113e2c98fb63676 # v7.0.11 | |
| with: | |
| branch: automated/sync-perses-dashboards | |
| commit-message: "Update Perses dashboards from upstream" | |
| title: "chore: sync Perses dashboards from upstream" | |
| body: | | |
| Automated update of Perses single-cluster dashboards. | |
| Source: `github.com/stolostron/multicluster-observability-addon/pkg/perses/dashboards/virtualization` | |
| Generated by the daily sync workflow. | |
| labels: automated | |
| signoff: true | |
| delete-branch: true |