Skip to content

ateom-microvm: give the micro-VM guest DNS so name-based egress works#1

Closed
dims wants to merge 1 commit into
fix/microvm-large-rootfsfrom
fix/microvm-guest-dns
Closed

ateom-microvm: give the micro-VM guest DNS so name-based egress works#1
dims wants to merge 1 commit into
fix/microvm-large-rootfsfrom
fix/microvm-guest-dns

Conversation

@dims

@dims dims commented Jun 26, 2026

Copy link
Copy Markdown
Owner

Problem

A micro-VM (ateom-microvm) actor gets a guest interface, default route, and host NAT, but no /etc/resolv.conf: ateom-microvm drops atelet's resolv.conf bind (a host bind is meaningless inside a VM) and never sends CreateSandbox.Dns. The guest can reach IPs but not resolve names, so workloads doing name-based egress — e.g. the OpenShell helpdesk agent calling Ollama Cloud (/chat) — fail; only no-egress paths like /status work.

Fix

Write /etc/resolv.conf into the bundle rootfs before mkfs.ext4, in both the golden-boot (RunWorkload) and restore (RestoreWorkload) paths, copied verbatim from the worker pod's own resolv.conf (cluster DNS) — the same source the kata shim's getDNS uses — with a public-resolver guard only for a degenerate empty file. Also satisfies kata-agent's requirement that /etc/resolv.conf already exist.

Validation (kind on a KVM host)

  • helpdesk-microvm /chat returns real gpt-oss:20b-cloud completions and survives suspend/resume (chat history preserved).
  • counter-microvm and /status unaffected.

Stacks on fix/microvm-large-rootfs (the large-image mkfs fix is required for the ~3 GB helpdesk rootfs), so the base is set there to keep this to the single DNS change.

The guest got an interface, default route, and host NAT but no /etc/resolv.conf: ateom-microvm drops atelet's resolv.conf bind (a host bind is meaningless inside a VM) and never sends CreateSandbox.Dns, so the guest could reach IPs but not resolve names. Workloads doing name-based egress (e.g. the OpenShell helpdesk agent calling Ollama Cloud) failed; only no-egress paths like /status worked.

Write /etc/resolv.conf into the bundle rootfs before mkfs.ext4 in both the golden-boot (RunWorkload) and restore (RestoreWorkload) paths, copied verbatim from the worker pod's own resolv.conf (cluster DNS) -- the same source the kata shim's getDNS uses -- with a public-resolver guard only for a degenerate empty file. Mirrors what the kata shim achieves and satisfies kata-agent's requirement that /etc/resolv.conf pre-exist.

Verified on bigbox: helpdesk-microvm /chat returns real gpt-oss:20b-cloud completions and survives suspend/resume; counter-microvm and /status unaffected.
@dims

dims commented Jun 26, 2026

Copy link
Copy Markdown
Owner Author

Superseding with a single-commit PR against upstream agent-substrate/substrate:main (PR agent-substrate#287 is merged, so this rebases cleanly onto main).

@dims dims closed this Jun 26, 2026
@dims dims deleted the fix/microvm-guest-dns branch June 26, 2026 02:40
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.

1 participant