Skip to content

feat(harbor): harden adapted task execution - #587

Draft
jdchawla29 wants to merge 11 commits into
mainfrom
jaideep/harbor-adapter-hardening
Draft

feat(harbor): harden adapted task execution#587
jdchawla29 wants to merge 11 commits into
mainfrom
jaideep/harbor-adapter-hardening

Conversation

@jdchawla29

@jdchawla29 jdchawla29 commented Aug 15, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • make Harbor adaptation a pure, task-agnostic artifact transformation
  • carry task instructions, verifier configuration, artifact destinations, and deterministic Compose environment values through the task contract
  • harden Docker and Compose runtime routing, workspace collection, isolation, and startup behavior found by the Terminal-Bench audit
  • preserve runtime-owned actor-to-verifier handoff without baking task material into environment images

Validation

  • 274 SDK non-Docker tests passed before the final main merge
  • 4 focused Docker integration tests passed
  • Ruff and strict type checking passed

jdchawla29 and others added 11 commits August 13, 2026 00:42
- preserve actor and verifier placement requirements on their own task rows
- resolve deterministic Compose interpolation and artifact destinations and exclusions
- return partial adaptation results with structured per-task findings
- resolve zero- and multi-port sidecars without reserving workspace names
- transfer actor files across independently placed verifier runtimes
- route Compose control ports through network namespace owners
- enforce runtime disk requirements and remote daemon socket paths
- preserve isolated self-hostname and child-process discovery
- parse multiline Dockerfile stages and canonical Compose recipes
Harbor ArtifactConfig allows destination (host placement, no verifier-side
effect) and exclude (tar --exclude patterns applied when downloading
directory artifacts). The adapter rejected both with extra_forbidden, so
valid Harbor tasks failed to adapt. Accept destination with Harbor's own
validation, and prune excluded entries when staging directory artifacts so
the verifier sees what Harbor's verifier would see.
Compose environments stage the values into the launch-time override;
image environments pass them as --env arguments. Without this there is
no way to hand a local Compose run a host value at all (run_args is
rejected for Compose).
Harbor task env values that are exactly ${VAR} or ${VAR:-default}
resolve from the host environment when a trial starts. The adapter
passed them through verbatim, so agents and verifiers saw the literal
template string and LLM-judge verifiers silently failed auth.

Resolution happens in env.py at startup with Harbor's fullmatch
semantics, sourced from the container process env the runtime's
env_vars populate. Templates stay verbatim in the content-hashed
manifest and persisted task rows, so host secrets never enter an
image or a task file; a missing required variable aborts startup
naming the variable.
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