Skip to content

ci(health): manual, read-only health check that flags personal tokens - #6

Merged
Seungpyo1007 merged 2 commits into
developfrom
feat/health-personal-tokens
Oct 31, 2026
Merged

Seungpyo1007 merged 2 commits into
developfrom
feat/health-personal-tokens

Conversation

@Seungpyo1007

@Seungpyo1007 Seungpyo1007 commented Oct 29, 2026 •

Copy link
Copy Markdown
Member

The health check is now run by hand and writes nothing to GitHub. It also reports any workflow in the org that runs under a personal token.

Health check: manual and write-free

  • health.yml only has workflow_dispatch; the daily schedule is gone.
  • It no longer updates the Org health report issue, comments, or @-mentions anyone. --issue, the alert fingerprint and notify are removed, and the report goes to the run's step summary.
  • GITHUB_TOKEN keeps read-only permissions (contents: read, actions: read).

Personal-token check

  • Each active workflow file on every tracked branch is read. Any secret other than GITHUB_TOKEN is reported.
  • Disabling a workflow clears its finding.
  • allowed_secrets in repos.json permits a specific secret per repository. Only TechAPI uses it, for TECHENGINEBOT_TOKEN (its label-triggered final check).
  • Tests pin TechMachine's own workflows and generated satellite workflows to GITHUB_TOKEN only.

Actions

  • health.yml and test.yml use only GitHub-owned actions pinned by full SHA: checkout 3d3c42e (v7.0.1), setup-python 6d4fd22 (v7.1.0).
  • test.yml now declares contents: read.

Checked locally

  • python -m pytest -q: 18 passed.
  • python -m machine.health against the org: all clear.

Read each active workflow file on every tracked branch and flag any secret
other than GITHUB_TOKEN. Automation running under a personal token got a
maintainer's account suspended; this makes it visible the day it returns.

Disabled workflows are skipped, so turning one off in the Actions settings
clears the finding. A repository that genuinely needs another secret lists
it under allowed_secrets in repos.json.

The tests also pin TechMachine's own workflows and the generated satellite
workflows to GITHUB_TOKEN only.
The health check no longer runs on a schedule, updates the Org health
report issue, or mentions anyone. A person starts it from the Actions tab
and the report goes to the run's step summary. An account here was
suspended over automation, so nothing in this repository acts on its own.

The workflow keeps GITHUB_TOKEN with read-only permissions. Every action
in health.yml and test.yml is a GitHub-owned action pinned by full SHA.

TechAPI's label-triggered final check is the one sanctioned use of
TechEngineBot's token, so it is allowed for that repository only.
@Seungpyo1007 Seungpyo1007 added ci Workflows and CI enhancement New feature or request labels Oct 31, 2026
@Seungpyo1007 Seungpyo1007 added this to the Org tooling (2026) milestone Oct 31, 2026
@Seungpyo1007 Seungpyo1007 changed the title feat(health): report workflows that run under a personal token ci(health): manual, read-only health check that flags personal tokens Oct 31, 2026
@Seungpyo1007
Seungpyo1007 merged commit 9f52bb9 into develop Oct 31, 2026
1 check passed
@Seungpyo1007
Seungpyo1007 deleted the feat/health-personal-tokens branch October 31, 2026 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Workflows and CI enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants