mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[PR #322] fix(tools-image): map guest hostname in /etc/hosts #346
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#346
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/kvcache-ai/AgentENV/pull/322
Author: @LSX-s-Software
Created: 9/27/2026
Status: 🔄 Open
Base:
main← Head:fix/tools📝 Commits (2)
4773102fix(tools-image): map guest hostname in/etc/hosts137f99brevert(tools-image): revert version update📊 Changes
4 files changed (+41 additions, -9 deletions)
View changed files
📝
tools-image/Dockerfile(+2 -2)📝
tools-image/Makefile(+1 -1)📝
tools-image/README.md(+6 -6)📝
tools-image/pivot-init(+32 -0)📄 Description
What
Fix guest self-hostname resolution for tools-image bootstrap (issue #319).
pivot-initnow appends an idempotent127.0.1.1 <hostname>mapping when the existing/etc/hostsdoes not contain the guest hostname.Why
Firecracker sets the guest hostname to
instance, but images with a non-empty/etc/hostsmay not contain that name. Files-only lookup and JavaInetAddress.getLocalHost()then fail. A loopback mapping remains valid when a sandbox resumes with a different guest IP.Related issue
Closes #319
Scope and non-goals
The change is limited to tools-image bootstrap behavior and the immutable tools drive release metadata. It does not change host networking, the Firecracker
ip=format, or any public API.Design and behavior changes
pivot-initreads the current guest hostname, ignores empty or invalid names, checks existing hosts aliases, and appends a loopback entry only when needed. Existing image-provided hosts entries are preserved and repeated boots do not add duplicates.Compatibility and operations
0.1.1to immutable version0.1.2; the new image must be published before rollout.0.1.2before deploying the manifest update. Rollback can restore the previous manifest version; existing snapshots remain version-pinned.Validation
make fmtmake clippymake test-unitmake -C services test(not applicable; no services changes)Commands and results:
Skipped checks and reasons:
Rust workspace format, clippy, and unit suites were not run because this PR changes only shell bootstrap code, tools-image build metadata, documentation, and the dependency manifest. The focused image build and real guest validation covered the changed behavior.
Risks and reviewer notes
The GHCR tools image tag is immutable. The release workflow is manual;
ghcr.io/kvcache-ai/agentenv-tools:0.1.2must exist before nodes using the updated manifest are deployed. The tested guest resolvedinstancelocally as127.0.1.1on cold start and after pause/resume.Checklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.