Skip to content

Start sessions automatically for new development clones - #705

Merged
ejc3 merged 4 commits into
mainfrom
fix/sessions-for-every-clone
Oct 27, 2026
Merged

ejc3 merged 4 commits into
mainfrom
fix/sessions-for-every-clone

Conversation

@ejc3

@ejc3 ejc3 commented Oct 27, 2026 •

Copy link
Copy Markdown
Owner

Newly cloned repositories on the development servers now get Claude and Codex sessions automatically once the checkout is complete and its owner is allowed. Linked worktrees still require the interactive marker, and internal agent worktrees remain excluded.

Both administrator jumpboxes retain the explicit marker requirement for both agents, including cold bootstrap. An allowed repository origin does not approve running its startup hooks with administrator credentials. When the admin policy changes, installers stop only the watcher before publishing the guarded policy and new code; policy writes are atomic, and failures stop installation. Existing interactive sessions remain independent of the watcher.

The upgrade records existing clones without opening sessions for all old checkouts. Unfinished clones are retried before recording an owner rejection, so a clone seen before its origin is written is detected when it finishes.

Validation: 69 focused ARM tests pass, plus Terraform formatting and helper shell syntax checks. Independent high code and security reviews passed. The clone-race, upgrade-baseline, admin-marker, and installer-ordering tests were observed failing when the corresponding guards were removed. Final CI passed all 69 tests, and Codex code and security reviews found no issues on the published head. CodeRabbit and Greptile provided no usable final-head review and were not counted as approvals.

CoderColton and others added 2 commits October 27, 2026 04:38
Treat completed allowed-owner clones under the configured roots as session candidates. Keep the interactive marker requirement for linked worktrees and continue excluding internal agent worktrees. Adopt existing unmarked clones on upgrade so the change starts sessions only for clones that appear afterward.
A clone seen before its origin was configured was permanently ignored. Wait for the checkout to finish before recording whether its owner is allowed, and cover the incomplete-to-finished transition with a real Git regression.
@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@codex security review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@greptileai review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-27T05:02:56.332014Z 72e9381 Manual request
🔒 Security Review ✅ Completed 2026-10-27T05:05:33.084761Z 72e9381 Manual request

Security findings

Advisory findings (1)

ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 27, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 843e5322-3192-4e49-93f9-f27de85fd6e8
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛡️ Codex Security Review

Here are some automated security review suggestions for this pull request.

Reviewed commit: 2582056c09

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

Comment thread scripts/agent-session-sync.py Outdated
ejc3 added 2 commits October 27, 2026 05:00
Keep automatic clone sessions on dev boxes while requiring the interactive marker for both agents on both admin jumpboxes. Fence the watcher before changing its policy and code, and publish policy files atomically so a failed update cannot enable unapproved startup hooks. Cover both admin installation paths and failure ordering without restarting interactive sessions.
@ejc3 ejc3 changed the title Start agent sessions for each new clone Start sessions automatically for new development clones Oct 27, 2026
@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@codex security review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

@greptileai review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. What shall we delve into next?

Reviewed commit: 72e93819fc

ℹ️ 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".

@chatgpt-codex-connector

Copy link
Copy Markdown

🛡️ Codex Security Review

Security review completed. No security issues were found in this pull request.

Reviewed commit: 72e93819fc

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

@ejc3
ejc3 merged commit 3ecf74b into main Oct 27, 2026
2 checks passed
@coderabbitai

coderabbitai Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
⚠️ Action not completed

Pull request is closed.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
⚠️ Action not completed

Pull request is closed.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
⚠️ Action not completed

Pull request is closed.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@ejc3

ejc3 commented Oct 27, 2026

Copy link
Copy Markdown
Owner Author

Merged and deployed as 3ecf74b. Terraform applied the six reviewed script updates and two administrator convergence triggers; the full follow-up plan is empty and /infra/applied-status is clean. All seven active watchers now run the merged code and have completed the upgrade baseline. Both jumpboxes enforce the marker in root-owned policy and actual process arguments. All 12 baseline administrator Claude/Codex processes survived; ARM and container watchers kept their PIDs. Existing clones were seeded without launching a burst of sessions. Colton is live on the new behavior. The stopped x86 host was left stopped, with its startup script updated for the next boot. The running ARM watcher was updated with an atomic copy of only the exact merged script, without package commands or a full bootstrap.

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