From 2b86947e40ac78793832a6c2c5a7aa2202fdd7ec Mon Sep 17 00:00:00 2001 From: Omry Yadan Date: Sun, 8 Nov 2026 03:25:25 +0800 Subject: [PATCH 1/2] Check fleet setup after relevant Node configuration changes --- .github/workflows/node-fleet-check.yml | 7 +++++++ docs/node-fleet-setup.md | 7 +++++++ node/tests/test_fleet_setup.py | 13 ++++++++++++- 3 files changed, 26 insertions(+), 1 deletion(-) diff --git a/.github/workflows/node-fleet-check.yml b/.github/workflows/node-fleet-check.yml index 2bf7f9e..ce8e88d 100644 --- a/.github/workflows/node-fleet-check.yml +++ b/.github/workflows/node-fleet-check.yml @@ -1,5 +1,12 @@ name: Node maintenance setup check 'on': + push: + branches: [main] + paths: + - .github/workflows/node-*.yml + - defaults/node-maintenance.json + - defaults/node-repositories.json + - node/** schedule: - cron: '0 3 * * 1' workflow_call: diff --git a/docs/node-fleet-setup.md b/docs/node-fleet-setup.md index 2e3057e..d8d771e 100644 --- a/docs/node-fleet-setup.md +++ b/docs/node-fleet-setup.md @@ -209,6 +209,13 @@ run to exercise installation, project checks, and publication. ## Change the weekly schedule +This repository also runs its setup check after pushes to `main` that change +`.github/workflows/node-*.yml`, `node/**`, `defaults/node-maintenance.json`, or +`defaults/node-repositories.json`. These triggers observe changes in this host; +the periodic scan still covers changes in the listed repositories. Other hosts +can add a push trigger for their own workflow and inventory paths while keeping +their existing schedule and manual trigger. + This repository checks its inventory every Monday at 03:00 UTC (11:00 in Singapore). The caller example above uses the same weekly schedule. To change it, edit the `schedule` block in the host workflow: diff --git a/node/tests/test_fleet_setup.py b/node/tests/test_fleet_setup.py index ec59d73..6c7f293 100644 --- a/node/tests/test_fleet_setup.py +++ b/node/tests/test_fleet_setup.py @@ -786,7 +786,18 @@ def test_workflow_splits_read_access_and_host_issue_write_access(): workflow = yaml.safe_load( (ROOT / ".github/workflows/node-fleet-check.yml").read_text() ) - assert {"workflow_call", "workflow_dispatch", "schedule"} == set(workflow["on"]) + assert {"workflow_call", "workflow_dispatch", "schedule", "push"} == set( + workflow["on"] + ) + assert workflow["on"]["push"] == { + "branches": ["main"], + "paths": [ + ".github/workflows/node-*.yml", + "defaults/node-maintenance.json", + "defaults/node-repositories.json", + "node/**", + ], + } assert workflow["on"]["schedule"] == [{"cron": "0 3 * * 1"}] assert workflow["name"] == "Node maintenance setup check" assert workflow["jobs"]["check"]["steps"][0]["with"]["inventory-path"] == ( From 59e5efe9a77391cb41ac77707a1dd24899c84e49 Mon Sep 17 00:00:00 2001 From: Omry Yadan Date: Sun, 8 Nov 2026 03:49:11 +0800 Subject: [PATCH 2/2] Clarify manual-only fleet setup checks Account for the host push trigger when explaining how to disable automatic setup checks. Remove both schedule and push event blocks, when present, while keeping workflow_dispatch available. --- docs/node-fleet-setup.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/node-fleet-setup.md b/docs/node-fleet-setup.md index d8d771e..d142477 100644 --- a/docs/node-fleet-setup.md +++ b/docs/node-fleet-setup.md @@ -227,8 +227,8 @@ To change it, edit the `schedule` block in the host workflow: workflow_dispatch: ``` -Remove the `schedule` block to run only manually. Keep `workflow_dispatch` for -on-demand checks. A reusable workflow uses its caller's schedule; it does not -inherit this repository's cron. This schedule is independent of the security -and upgrade cadences in each maintenance installation; do not add the fleet +Remove the `schedule` and `push` blocks, if present, to run only manually. Keep +`workflow_dispatch` for on-demand checks. A reusable workflow uses its caller's +schedule; it does not inherit this repository's cron. This schedule is independent +of the security and upgrade cadences in each maintenance installation; do not add the fleet cron to those installations' maintenance configuration.