Repository navigation
Review round: restart the Windows service on an error exit, deps, cuts, docs - #17
Merged
Merged
Conversation
…cteru2/core v0.1.3→v0.1.5, golang.org/x/sys v0.47.0→v0.48.0
SCM queues failure actions for a STOPPED status with a non-zero exit code only when the failure-actions flag is set; serve returns exit code 1 after the 2-minute listen retry or a permanent accept error. The failure actions and the flag now apply on both fresh installs and re-runs over an existing service.
…ilities below the method set they build
… test conn embeds net.Conn
…oon VMs with cocoon vm exec
…AF_VSOCK The subcommand came in 06dee79 for the pre-integration kernel-vsock design. Six hours later cocoon 7174e76 reached the agent over Cloud Hypervisor hybrid vsock (per-VM Unix socket plus CONNECT, constant guest CID 3), so the subcommand never had a target. Nothing in the workspace calls it; the client Go package stays because cocoon imports it.
The agent borrows only core/log; the round's bump moved core and its sentry-go without a reason. vsock, x/sys and the grpc security fix stay.
It moved only with the reverted core bump and is not linked into the binary.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Whole-repo review round: dependency bump, one Windows service fix, review and cut commits, and docs the code contradicted.
Commits
build:mdlayher/vsock v1.3.0, x/sys v0.48.0, grpc v1.83.2 (GO-2026-6443; grpc is linked through core/log). projecteru2/core stays at v0.1.3: only its log package is borrowed.net.ErrClosed.Servealready handles a listener closed by the ctx, so nothing changes.fix:restart the Windows service after an error exit, not only after a crash.servereturns an error after the 2-minute vsock listen retry runs out, or on a permanent accept error.Executethen returns exit code 1, so the SCM seesSERVICE_STOPPEDwith a non-zero exit code.Restart=always.sc.exe failureplussc.exe failureflag 1now run after the create/update branch, so a fresh install and a re-run over an existing service converge to the same settings.FAILURE_ACTIONS_ON_NONCRASH_FAILURES: FALSEtoday. It needs a re-bake after the next agent release.review:the Linux vsock constructors move below the listener type they build, matching the Windows file (review: json.Encoder frames, mergeEnv cut, comment budget across the agent #12). Layout only.review:errors.AsTypefor the exit code; the serve log tag iscmd.serve(Cobra dispatch rule); the host-peer test conn embedsnet.Conn.cut:the Windows process controller folds intosetupProcessclosures. The syscalls, their order, and the single job close are unchanged.docs:vhost_vsock.cocoon vm exec.cut:drop theclientsubcommand.CONNECT, constant guest CID 3. So host AF_VSOCK never had a cocoon VM to reach, and the guest-side dial is refused by the host-only listeners.clientGo package stays (cocoon imports it). WithdialVsockgone, the WindowsnewVsockSockethelper had one caller and is inlined.usage.md,configuration.md,index.mdand the README highlights now describecocoon vm execas the host path.Numbers
Evidence
Gates on the final HEAD:
Windows guest run: win11:25h2 cloudimg, 16 vCPU, cloud-hypervisor. The agent was swapped in place as a service through a SYSTEM scheduled task, and the installed binary's
--versionrev was checked before each arm. Arms:main= 5afc189,round= this branch's HEAD, both built with the Makefile ldflags.Installer, run over the image's existing service (the update branch):
Error-exit restart. binPath is set to
serve --bogus, soExecutereturns exit code 1 on every start. Each arm is onesc startplus 32 s, with SCM events read from the System log:Job and exec matrix. The
ping.exedetector was checked with a positive control first: a live session running ping is seen.Exec latency: 50 sequential
cmd.exe /c echoper batch, arms interleaved by swapping the service binary:Windows smoke of the cut (5b03f5c) on a fresh win11:25h2 guest, agent swapped in as the service: