Skip to content

Refines secret retrieval check to skip commented lines#40

Merged
lucas-koontz merged 8 commits into
mainfrom
chore/eng-1053-startup-failure-watchdog
Jul 27, 2026
Merged

Refines secret retrieval check to skip commented lines#40
lucas-koontz merged 8 commits into
mainfrom
chore/eng-1053-startup-failure-watchdog

Conversation

@lucas-koontz

Copy link
Copy Markdown
Contributor

Improves the workflow's secret retrieval check by ensuring it skips comments, preventing false positives when analyzing code. This enhances the security checks by focusing on executable commands, reducing unnecessary alerts.

Relates to ENG-1053

The dev/staging/prod trio was the same pipeline three times, and the drift it
hid was real: prod built its image without waiting for lint or tests, staging
and prod disagreed on deploy's needs list, and inference's prod migrate keyed
its concurrency group on a matrix it does not have.

One repo-local build-deploy.yml now holds the graph; the three callers hold the
trigger, the concurrency group, the checks the build waits on, the permission
ceiling, and the env knobs. migrate/deploy/integration-tests collapse to one
matrixed path gated on a has-envs boolean, because an empty matrix concludes
the whole run as failed with no failed job in it.

Also fixes what the pipelines were saying. Two pushes to staging had concluded
startup_failure with zero jobs -- a caller granted no pull-requests scope while
a callee declared one, and that cap is enforced when the file loads -- so
staging served the previous image for ten hours and nothing alerted, because
the notify job is a job inside the run. Prevention is a shared lint gate,
detection is a scheduled sweep; the same fix closed an unnoticed prod window.
Promotion PRs stop rebuilding images nothing deploys, and a release is one run
tree instead of two.
…NG-1053)

Replaces `workflow_permissions.py` with `workflow_graph.py` to incorporate additional static checks on workflow graphs, addressing issues with multiple run trees and uncalled reusables. Updates related workflow and test references. Introduces `.gitignore` to exclude common Python and IDE-specific files.
Update README to provide clear guidelines on choosing secret storage locations based on the type of secret, emphasizing security considerations and correcting misconceptions about Kubernetes as the default. Removes redundant compiled Python file.
…orkflow robustness (ENG-1053)

Enhances PR environment comment workflow by removing sensitive details, promoting security by linking to protected documentation, and refines permission declarations to prevent runtime failures. Updates README and test cases to reflect these changes, ensuring clarity and consistency. These improvements address previous detection gaps and enhance auditability for pull request-based operations.
…ments (ENG-1053)

Introduces a new input option to customize the heading text in PR environment comments, accommodating varied use cases such as installer artifacts. Simplifies message consistency by updating the subtext. These changes provide greater flexibility and clearer communication in pull request comments.
…1053)

Adjusts the grep command to ignore commented lines when checking for secret retrieval commands in scripts, preventing false positives. This ensures that only executable lines accessing secrets are flagged, enhancing the reliability of workflow audits.
@lucas-koontz
lucas-koontz requested a review from a team as a code owner July 27, 2026 00:09
@lucas-koontz
lucas-koontz merged commit bbc87bb into main Jul 27, 2026
5 checks passed
@lucas-koontz
lucas-koontz deleted the chore/eng-1053-startup-failure-watchdog branch July 27, 2026 00:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants