Versions in this module Expand all Collapse all v0 v0.18.0 Sep 22, 2026 Changes in this version + const DrainGrace + const ExitCannotStart + const ExitNotFound + const ExitSyntaxError + const ExitTimeout + const PolicyLaunchBurst + const PolicyLaunchInterval + const SandboxNotRunningHint + const SocketEnvVar + const TerminateGrace + var ErrExecdUnavailable = errors.New("exec daemon is not available") + func SendStdio(uc *net.UnixConn, s Stdio) error + func WriteError(w io.Writer, msg string) error + func WriteExit(w io.Writer, code int) error + func WriteFrame(w io.Writer, ch Channel, payload []byte) error + func WriteRequest(w io.Writer, req Request) error + func WriteSignal(w io.Writer, sig syscall.Signal) error + type Channel byte + const ChanError + const ChanExit + const ChanSignal + type Client struct + func NewClient(sockPath string) *Client + func NewClientFromEnv() (*Client, error) + func (c *Client) RunCommand(ctx context.Context, command string, stdio Stdio, opts RunOptions) (int, error) + type Executor interface + Execute func(ctx context.Context, req Request, stdio Stdio) (int, error) + type Frame struct + Channel Channel + Payload []byte + func ReadFrame(r io.Reader) (Frame, error) + func (f Frame) ExitCode() int + func (f Frame) Signal() (syscall.Signal, bool) + type Job struct + func NewJob(stdio Stdio) *Job + func (j *Job) Signal(sig syscall.Signal) + func (j *Job) Start(cmd *exec.Cmd) error + func (j *Job) Stdio() Stdio + func (j *Job) Terminate() + type Request struct + Command string + Cwd string + TimeoutMs int + func ReadRequest(r io.Reader) (Request, error) + type RunOptions struct + Signals <-chan syscall.Signal + TimeoutMs int + type Server struct + func NewServer(sockPath string, exec Executor) (*Server, error) + func (s *Server) Close() error + func (s *Server) Serve() + func (s *Server) SocketPath() string + type ShellExecutor struct + func NewShellExecutor() *ShellExecutor + func (e *ShellExecutor) Execute(ctx context.Context, req Request, stdio Stdio) (int, error) + func (e *ShellExecutor) ExecuteWithSignals(ctx context.Context, req Request, stdio Stdio, sigs <-chan syscall.Signal) (int, error) + func (e *ShellExecutor) Run(ctx context.Context, command, cwd string, stdio Stdio) (int, error) + type Stdio struct + Err *os.File + In *os.File + Out *os.File + func RecvStdio(uc *net.UnixConn) (Stdio, error) + func (s Stdio) Close()