8000 Register a fresh-instance host_ip grant box per creation · Issue #3007 · gominimal/minimal · GitHub
[go: up one dir, main page]

Skip to content

Register a fresh-instance host_ip grant box per creation #3007

Closed

Description

@norrietaylor

Situation

A host_ip box that declares a credentialed upstream registers for a host-minted id before its create (BEP-082, #2854 / #2861). activate_box registers under created_box_name(&request): the spec name, else --name, else the entry. minvmd holds that name in HostIpIds.by_name while the box is admitted.

No fresh-instance path registers today. Only min task run sets fresh_instance (crates/minimal/src/task.rs), and it sends BoxPolicy::default(), so it registers nothing. Spec 28 plans min box run <entry> (BCLI-010), and the architecture says run and --new create <name>-<n>.

When a fresh-instance path registers a grant box, two defects follow:

  1. A second concurrent fresh instance with the same base name is refused with NameAlreadyHeld (crates/minvmd/src/box_registry.rs, register_host_ip_box_as) and exits 2.
  2. minimald renames a fresh instance to <base>-<n> before its mint (crates/minimald/src/box_manager.rs). The mint looks up <base>-<n> and misses the registration under <base>, so ensure_registered_id refuses the box.

Raised by the arch review on #2861 (thread on box_registry.rs:4662). The owner chose to track it here instead of fixing it in T117.

Done when

A fresh-instance registration of a host_ip grant box is unique per creation. Two concurrent fresh instances with one base name both get their own minted id. The mint finds the registration after the <base>-<n> rename. A second create of the same fixed name, without a fresh instance, is still refused. A test drives two concurrent fresh-instance grant boxes and shows both admitted with distinct ids.

Land it with, or before, the first fresh-instance path that declares a credentialed upstream (min box run under spec 28).

Activity

  1. norrietaylor commented on Nov 5, 2026

    @norrietaylor
    MemberAuthor

    Planned as task T125, #3048, in epic #1501. This issue stays open as the residual record until #3048 lands.

  2. norrietaylor commented on Nov 6, 2026

    @norrietaylor
    MemberAuthor

    Done by T125 (#3053): a fresh-instance host_ip grant box registers under a creation key of its own, so concurrent instances get distinct ids. The in-VM daemon honours the key only for the create's own fresh base.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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

      0