Skip to content

feat(apply): report sandbox service URLs - #14024

Merged
cv merged 3 commits into
v1from
feat/report-service-urls
Oct 31, 2026
Merged

cv merged 3 commits into
v1from
feat/report-service-urls

Conversation

@kaofelix

Copy link
Copy Markdown
Collaborator

Closes #13996. Follows #13972 (PR #13981).

Failure

A sandbox's serviceExposures makes a loopback listener reachable at a URL the OpenShell gateway reports, but nemoclaw apply didn't show it. The user had to install the OpenShell CLI, select the gateway and workspace, and run openshell service list, although the URLs were already in OpenTofu state as openshell_sandbox's computed service_urls (#13311).

Decision

  • After a successful apply, the SDK reads state again and reports each sandbox's URLs in OperationResult.service_urls (serviceUrls in JSON), keyed by sandbox and service name. The field is left out when no sandbox has exposures, so existing JSON is unchanged. Plan, destroy, and failure results never set it.
  • An unchanged apply reports them too: the provider refreshes service_urls from the gateway on every read, so they describe current state.
  • The CLI lists them under Service URLs after the gateway and workspace lines, one sandbox/service: URL per line, escaped like other terminal text. OpenShell's unnamed endpoint, the empty service key, is listed as sandbox: URL, matching the host name OpenShell gives it; JSON keeps the "" key.
  • The apply's changes are saved before the URLs are read. A failed or cancelled read leaves the field out and adds a warning to run apply again, instead of reporting a saved apply as failed. A deployment without exposures skips the read, so it neither runs an extra tofu show nor warns.
  • docs/interfaces.md replaces the openshell service list step; docs/reference/cli.md and docs/sdk.md describe the field, including that the URLs carry no credential. The verify-yaml-deployment skill drops its known gap for Report sandbox service URLs in apply output #13996 and takes the dashboard URL from apply output.

Validation

  • New SDK tests over scripted OpenTofu (crates/nemoclaw-sdk/tests/service_urls.rs): URLs on the first and an unchanged apply, none on plan, success with a warning when the read fails or is cancelled, and no read or warning without exposures. Each failed before the change it covers (serviceUrls was null; no warning; a warning without exposures).
  • A state test parses service_urls that is present, null, and absent. Without the null-tolerant deserializer it fails with OpenTofu binding is unreadable.
  • New formatter test: the URL section's placement and labels, the unnamed endpoint, escaping, and JSON. It failed before the change (no section).
  • The lifecycle test network_grants_and_service_exposures_apply_export_and_reapply_unchanged now checks the fixture gateway's URLs reach the first apply and the unchanged re-apply of the export, which export_and_reapply_unchanged now returns instead of discarding. With the post-apply read disabled, it failed with left: {}; with it, it passes.
  • cargo ci passes locally on linux/arm64: fmt, clippy, build, test, schema, bundle, and lifecycle.
  • Not run: live-docker and live-kind. The change reads existing state and formats output; it changes nothing that runs in images or on Kubernetes.

A successful apply reads each sandbox's service_urls from OpenTofu state
and reports them as OperationResult.service_urls (serviceUrls in JSON),
keyed by sandbox and service name. The CLI lists them under "Service
URLs" after the gateway and workspace lines; the unnamed endpoint is
listed under the sandbox's name. Plan doesn't report them.

The apply's changes are saved before the read, so a failed or cancelled
read leaves the URLs out with a warning instead of failing the apply.

Closes #13996.
@kaofelix

Copy link
Copy Markdown
Collaborator Author
Authoring session — opening
Field Status Value Evidence or limit
Harness recorded pi (session format v3), codemode typescript tool Session metadata; the harness version isn't in the record
Skills recorded interrogate (injected); test-driven-development (complete read); nemoclaw-contributor-create-pr (complete read) Skill injections and reads to the cutoff; gob and the hc manual were read only in part and are not counted
Instruction files recorded AGENTS.md (injected); WRITING.md (complete read); .github/PULL_REQUEST_TEMPLATE.md (complete read); .github/SESSION_REPORT_TEMPLATE.md (complete read) System prompt injection and reads to the cutoff
Tool calls partial typescript: 218 (8 failed) Active branch to the cutoff, including the earlier interrogation of #13996 and the issue edit; nested git, gh, cargo, hc, and shell calls inside each program aren't counted; the interrogation's three adversary sessions and one Opus code-review session are separate sessions and excluded
Session window recorded 2026-10-30T13:21Z to 2026-10-30T16:37Z; 3 h 16 min First event to the cutoff, including idle time; implementation began at 15:43Z
Compactions recorded 0 Complete record to the cutoff; two context summaries replaced earlier turns before implementation began
Models recorded deepseek/deepseek-v4.1-flash-1017; claude-opus-5-5 Model changes, in order; the switch was at 15:04Z, before implementation; the separate code review also used claude-opus-5-5
Reasoning levels recorded medium One thinking-level setting, no changes

@github-actions

Copy link
Copy Markdown
Contributor

@wscurran wscurran added area: cli Command line interface, flags, terminal UX, or output area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery feature PR adds or expands user-visible functionality v1 NemoClaw v1 branch labels Oct 30, 2026
Apply now lists each exposure's URL under Service URLs, so the verify
skill reads it there instead of composing it from the workspace name.

- openclaw-dashboard: DB1 takes the URL from apply output and checks it
  matches the origin the patched image allows; openshell service list is
  only needed for the authorization mode, which apply doesn't print.
- export-reapply: EX2 checks the unchanged reapply lists the same URLs in
  text and JSON, with no warnings.
- exposure-change: XC2 checks the changed exposure's URL in apply output.
- SKILL.md says apply lists the URLs and plan never does.
- The OpenClaw proof row records the run at 783b7ae.

Driven live on a DGX Spark with this branch's bundle; see the PR comment.
@kaofelix

Copy link
Copy Markdown
Collaborator Author

Live check on a DGX Spark (linux/arm64, OpenShell 0.1.6) with a bundle built from 783b7ae, following verify-yaml-deployment for OpenClaw against an existing vLLM. I took the dashboard URL only from apply output and didn't run openshell service list to find it.

  • First apply printed Service URLs: with assistant/dashboard: http://nc-49699e4e2e750cba--assistant--dashboard.openshell.localhost:17913/ after the gateway and workspace lines. It matched the origin derived from the workspace, sandbox, service, and port.
  • The URL works. The Control UI page loaded; the chat endpoint returned 401 without the gateway token and a reply with it; headless Chromium signed in and got a reply to a fresh word. The Control UI needs the one-line adapter patch from [Enhancement]: OpenClaw adapter: browser dashboard and chat NeMo-Fabric#541, and the token came from the host (Question: how does a user sign in to an OpenClaw dashboard? #13973).
  • Unchanged reapply of the export: No resource changes., the same sandbox, and the same Service URLs section. With -o json: changes: 0, serviceUrls with the same URL, warnings: null.
  • Plan printed no URLs, and plan JSON has no serviceUrls field.
  • After changing the exposure's mode, apply replaced the sandbox and listed the URL again; the new sandbox answered.
  • Destroy confirmed, and no object with the run's UID remained.

Not driven live: the warning when the post-apply read fails, and the unnamed endpoint's sandbox: URL label; the unit tests here cover both.

6cac530 updates the skill to read the URL from apply output and to check it on reapply and after an exposure change. I checked the new steps against this run's evidence, not in a second deployment.

@wscurran wscurran added the area: skills Skills, agent behaviors, prompts, or skill packaging label Oct 30, 2026
# Conflicts:
#	crates/nemoclaw-e2e/tests/hosted_parity.rs
#	crates/nemoclaw-sdk/src/deployment/mod.rs
#	crates/nemoclaw-sdk/src/state/mod.rs
@cv
cv enabled auto-merge (squash) October 31, 2026 04:27
@cv
cv merged commit 530e53d into v1 Oct 31, 2026
90 of 92 checks passed
@cv
cv deleted the feat/report-service-urls branch October 31, 2026 04:55
cv added a commit that referenced this pull request Oct 31, 2026
<!-- SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION &
AFFILIATES. All rights reserved. -->
<!-- SPDX-License-Identifier: Apache-2.0 -->

## Failure

`linux_amd64 / Live / Kind` failed intermittently after #14036 and
#14037, on #14037 and #14024 (both passed on rerun). In
`kubernetes_live::on_openshift_three_agents_keep_separate_identities_run_as_the_namespace_uid_and_answer_after_each_reapply`,
one of three OpenClaw sandboxes failed with `start_failed`, and CI never
showed why, because Fabric's message stayed in the runner's temporary
directory.

The cause is CPU starvation. Three agents start at once on four vCPUs,
and each OpenClaw start took about 39 s on that runner, measured from
the supervisor's relay logs. Fabric's OpenClaw adapter gave each startup
step its own 30 s timeout, so the Gateway's readiness wait ran out at
random. Local `live-kind` runs reproduced the same error with a shorter
timeout, and start time tracked the Kind node's CPUs: about 7.5 s with
20, 11.4 s with 4 and 26 s with 2. The denied `catalog.openclaw.ai`
lookup in the logs isn't the cause: OpenClaw starts it in the background
after the Gateway is ready, and timing showed no difference with and
without it.

## Decision

- **Fix in Fabric's OpenClaw adapter, not NemoClaw.**
`startup_timeout_seconds` is now one deadline for all of `start`, from
checking the `openclaw` command to the Gateway becoming ready, with a 60
s default and the existing 75 s maximum. That's the rule
NVIDIA/NeMo-Fabric#547 (L3) already sets for adapters that gain the
setting. It's in the reference implementation as
cv/NeMo-Fabric@a7c5d024. This PR pins Fabric
`21ca8d3e`, which includes it, through NVIDIA's codeload URL as before.
The catalog changes only OpenClaw's default and description, plus the
revision and checksum. The HCL e2e cases' catalog-derived names and
image digest are updated.
- **Make the next failure diagnosable.** When a live Kubernetes apply
fails, the test prints one redacted, length-limited line from each
`diagnostics/fabric-SANDBOX.json`: stage, code, effects and message.
Fabric's runtime server currently replaces the adapter's error with
"Fabric could not establish an active runtime", so naming the cause also
needs a Fabric change.
- **Didn't raise a NemoClaw budget.** Setting `startup_timeout_seconds`
in the live documents, or running fewer Kind tests in parallel, would
have hidden the adapter's tight default for everyone else.
- **One test adjusted:**
`journey_tree_preview::invalid_fabric_setting_is_labeled_without_printing_its_value`
checks that the value `42` never appears in the preview. The new
revision contains "42", so the test now skips the "Fabric revision:"
line, as it already skipped `sha256:` lines.

## Validation

- Rebased on `v1` at `530e53d706` (#14024), then `cargo ci`: fmt,
clippy, build, test 1791/1791, schema, bundle, lifecycle 161/161.
- Before the rebase, on linux_arm64:
- `cargo ci live-kind` passed three times, 7/7 each, once with the Kind
node limited to 4 CPUs;
  - `cargo ci live-docker` passed.
- The diagnostics unit test failed against an empty stub before the
implementation.
- `cargo metadata --locked` passes. `Cargo.lock` changes only the source
line, because `cargo update -p nemo-fabric-core` also downgraded
`windows-sys`.
- Deferred to CI: `linux_amd64 / Live / Kind`, where the flake happened,
since this machine is arm64.

Part of #14011.

---------

Signed-off-by: Carlos Villela <[email protected]>
cv added a commit that referenced this pull request Nov 11, 2026
…ms (#14413)

The release notes now list every user-visible change on `v1` since the
`v0.1.0-rc9` tag, including the breaking ones, and four example pages
drop claims that later changes made false.

## Problem

`docs/about/release-notes.md` listed three breaking changes and none of
the features, fixes, and onboarding changes that reached `v1` after
`v0.1.0-rc9`; it didn't name the configuration shapes the parser now
rejects or the intent record version `v0.1.0-rc9` writes.
Some example claims went stale:

- `examples/spark/README.md` said the pinned OpenShell has the Podman
TLS initialization blocker, ai-openshell/openshell#3427; its fix merged before
OpenShell 0.1.0, and `v1` pins 0.1.7.
- `examples/station/README.md` and `examples/gtc-dc/README.md` required
exactly one visible GPU on the host; since #13929,
`container.gpuDevices` lets a service on a host with more GPUs request
one.
- `examples/hcl/travel-team` said Fabric's Deep Agents adapter can't
turn reasoning off, NVIDIA/NeMo-Fabric#433; NVIDIA/NeMo-Fabric#439 fixed
that, and the pinned catalog's Deep Agents `reasoning_effort` accepts
`none`.
- The travel team cited #13313 for the booking key its service doesn't
receive, but #13313 closed when `openshell_api` landed.

## Change

- `docs/about/release-notes.md` gains "Changes Since v0.1.0-rc9",
grouped by area, from the commits in `v0.1.0-rc9..origin/v1`; where a
later commit changed an earlier one, the entry describes the current
code, and changes added and removed after the tag aren't listed:
- Agents and interfaces: #14037, #14038, #14269, #13981, #14024, #14186,
#14052, #14385, #13971, #13858, #13947, #14039, #14042, #14044, #14343.
- Inference: #13929, #14391, #14396, #14398, #14400, #13963, #13912,
#13964, #14388, #14390, #14397.
- Gateways and Kubernetes: #13909, #13970, #13922 (an existing
namespace, refused at plan by #13756, is now bound; cluster-wide reads
dropped), #14014, #14169, #13921.
- Plan, apply, and diagnostics: #14224, #13756, #14141, #14133, #14135,
#13775, #13744, #13701.
- Onboarding: #13693, #13695, #13741, #13757, #13851, #13978, #14228,
#14233, #14334, #14336.
- Examples and builds: #14166, #14184, #14188, #14191, #14192, #14200,
#13889, #14267, #14312, #14315, #14355, b30e9b4, #13781, #13813,
#14246, and the pins in `versions.json` and `image/fabric/Dockerfile`.
- Its breaking changes since the tag:
- the intent record moving from 15, which `v0.1.0-rc9` writes, through
16 (#14266), 17 (#14343), 18 (#13929), 19 (#14391) and 20 (#14394);
  - name-keyed `sandboxes` and `inferenceProviders` (#13703, #13705);
- a recipe `compatibility.gpu` outside every hardware profile (#13912);
- model tuning the adapter doesn't accept (#14111), and Hermes's
`max_tokens` losing its default (#14296);
  - `skills.paths` resolution (#14296);
  - endpoint and `networkCIDR` validation (#13847, #14081);
- the HCL `gateway_values` attribute (#14014), and Kubernetes ownership
receipts from before #13922 and #14014.
  The two earlier items stay, under their own heading.
- `examples/spark/README.md` replaces the closed OpenShell#3427 blocker
with the Podman and remote-model limits in `docs/resources/limits.md`.
- `examples/station/README.md` and `examples/gtc-dc/README.md` require
one GPU visible in the model container, and point to
`container.gpuDevices` for a host with more.
- `examples/hcl/travel-team/README.md` and `WALKTHROUGH.md` drop the
NeMo-Fabric#433 limitation, and the travel team's booking-key statements
link #14417 instead of #13313.

Not listed, because both changes landed after the tag: Deep Agents Code
(#14043, #14250), `compatibility.gpuCount` (#14391, #14394), and the
"Creating infrastructure state" progress step (#14169, #14248).

Checked and left unchanged: the root `README.md`,
`crates/nemoclaw-onboarding/README.md`,
`crates/nemoclaw-cli/assets/README.md`, `internal-docs/README.md`, the
other example READMEs, and every example YAML header comment. The GPU
autoscaling README and `load.sh` read the JSON fields `OperationResult`
serializes, and ai-openshell/openshell#4287 is fixed only after the pinned
0.1.7. The two pre-tag release-note items still match the schema and
SDK. `docs/README.md` is left to #14412, which retires the stale field
reference snapshot it describes.

Not verified: whether Hermes sends the booking key's placeholder to MCP
servers; #14417 tracks the live check.

## Beyond CI

Each relative link and anchor in the changed files resolves to an
existing file and heading.
@cv cv added this to the Roadmap: GTC DC 2026 milestone Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: cli Command line interface, flags, terminal UX, or output area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery area: skills Skills, agent behaviors, prompts, or skill packaging feature PR adds or expands user-visible functionality v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants