Skip to content

Handle HOME/WORKSPACE_DIR fallbacks in agynd (per 2026-04-24 spec) #100

Description

@rowan-stein

User request / architecture change

Architecture change doc: agynio/architecturechanges/2026-04-24-home-workspace-env.md.

  • Agents Orchestrator should not inject or reserve HOME / WORKSPACE_DIR.
  • Agent-specific fallbacks live in agynd.

Specification

1) Codex HOME fallback

If HOME is empty for the Codex subprocess environment, set HOME=/tmp before spawning (Codex resolves ~/.codex against HOME and needs a writable path).

  • This fallback is Codex-specific.

2) Init scripts workdir fallback

Run init scripts with working directory:

  • WORKSPACE_DIR when that variable is defined, otherwise
  • /tmp

(Implementation hint: internal/config/config.go currently defaults WORKSPACE_DIR to /workspace when unset; this should become /tmp so init scripts run in /tmp by default.)

Acceptance criteria

  • go test ./... passes.
  • When WORKSPACE_DIR is unset, init scripts run in /tmp.
  • When HOME is unset, Codex still starts (via HOME=/tmp fallback).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions