ci: fix Codex permission profile handoff#721
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the monthly Go version review automation to ensure the unprivileged Codex process can reliably load the checked-in permission profile across the sudo boundary used by the unprivileged-user safety strategy.
Changes:
- Move the Codex home/profile install location from a workspace-relative path to the unprivileged user’s default Codex home (
/home/codex/.codex). - Pre-create the per-run proxy handoff file and let
codex-actionresolve the Codex home without an explicitcodex-homeinput. - Clarify comments in the Codex permission profile TOML to match the new installation behavior.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
.github/workflows/go-version-review.yml |
Installs the permission profile into the unprivileged user’s default Codex home and adjusts setup to support unprivileged-user execution. |
.github/codex/go-version-review-config.toml |
Updates commentary to reflect the new workflow installation path and isolation approach. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2d87853cda
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
df1a06f to
e484773
Compare
HAYDEN-OAI
left a comment
There was a problem hiding this comment.
One security-boundary issue remains at this head, so I am leaving a COMMENT review rather than approving. The rest of the audited split looks sound: proposal token/secret scope, disabled command network, fresh credential-free publisher with allowlist/content validation, and the isolated dispatch job.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (2)
.github/workflows/go-version-review.yml:68
- The pinned
actions/checkouthash is annotated as# v6.0.2here, but other workflows in this repo annotate the same pinned hash as# v6(e.g.,.github/workflows/ci.yml:42,codeql.yml:37). For consistency (and to avoid implying the hash maps to a specific patch tag), align this comment with the established convention.
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
.github/workflows/go-version-review.yml:254
- The pinned
actions/checkouthash is annotated as# v6.0.2here, but other workflows in this repo annotate the same pinned hash as# v6(e.g.,.github/workflows/ci.yml:42,codeql.yml:37). For consistency (and to avoid implying the hash maps to a specific patch tag), align this comment with the established convention.
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 993f0c87af
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
993f0c8 to
ac00155
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (1)
.github/workflows/go-version-review.yml:100
CODEX_AUTOMATION_DIR(the workspace.codex-automationdirectory) is no longer created in this step after movingCODEX_AUTOMATION_HOMEto/home/codex/.codex. Later steps write$GO_RELEASE_FEEDand other paths under.codex-automation, so the workflow will fail if the directory doesn't already exist.
# The action normally creates this home itself. We create it first so
# the named permission profile is present before Codex starts. Root
# ownership plus the sticky bit lets the runner-group members create
# their own disposable state without replacing one another's files.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ac00155702
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
c323a2c to
f29c5f4
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f29c5f4cd5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@HAYDEN-OAI ME GRIMLOCK FIX ALL OPEN FINDINGS IN 13eba7e. KEY STAY LOCKED AWAY, LOOPBACK STAY CLOSED, FULL TESTS RUN BEFORE GITHUB TOKEN. CI GREEN. PLEASE RE-REVIEW AND STAMP. |
|
Security review completed. No security issues were found in this pull request. Reviewed commit: ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
|
Codex Review: Didn't find any major issues. Bravo. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
HAYDEN-OAI
left a comment
There was a problem hiding this comment.
Thermo-nuclear review complete at 13eba7e. No substantive structural, maintainability, boundary, or correctness issues found. I validated the pinned codex-action home/proxy semantics, reviewed the current discussion and permission boundary, reran actionlint v1.7.9 and git diff --check, and confirmed the repository checks are green.
Summary
Fix the monthly Go version review so the unprivileged Codex process loads its checked-in permission profile.
The workflow now installs the profile at the target user's real default Codex home, lets
codex-actionresolve that home itself, and pre-creates the proxy's per-run handoff file with runner-only write access.Root cause
The workflow passed a workspace-relative
codex-hometocodex-action. With theunprivileged-usersafety strategy, the action launches Codex throughsudo -u codex;sudoresets the explicitCODEX_HOME, so Codex searched its actual user home and could not see the named[permissions]table.The production dispatch failed closed with:
The publisher and CI-dispatch jobs were skipped, and no branch or pull request was created.
Security impact
This does not loosen the action's GitHub permissions, environment/secret scope, network denial, generated-file allowlist, or publisher isolation. The permission profile is installed read-only, and only the runner-owned proxy can write its per-run handoff file before the action changes that file to root-owned, read-only mode.
Validation
actionlintv1.7.9git diff --checkgo-version-reviewprofile from a read-only default home and advanced to the intentionally invalid model-provider check