Documentation
¶
Overview ¶
Package quietexec starts helper programs (nvidia-smi, schtasks) without putting a window on the operator's screen.
Why it exists: release builds of flockd.exe are GUI-subsystem programs (.goreleaser.yaml, cmd/flockd/console_windows.go), so the daemon has no console. When a program without a console starts a console program, Windows gives the child a new console of its own, and that console is a visible window. It opens and closes within a fraction of a second, but it takes the keyboard focus on the way, which drops a full-screen game to the desktop. The daemon measures VRAM with nvidia-smi every 30 seconds (internal/modelops housekeeping), so on an NVIDIA machine that happened twice a minute for as long as the node ran.
CommandContext is exec.CommandContext plus the one flag that prevents it. Every helper the daemon or tera starts goes through it; a test in this package fails when a file that builds for Windows calls os/exec directly. internal/runtime/llamacpp sets its own flags for llama-server (it also needs a process group) and follows the same rule.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CommandContext ¶
CommandContext is exec.CommandContext for a helper whose output is read through pipes. On Windows the child gets no console window when this process has no console to share; when it has one (tera in a terminal) the child shares it, as with os/exec. Elsewhere it is exec.CommandContext unchanged.
Types ¶
This section is empty.