Skip to content

agentlab list: every lab on this machine — name, directory, cluster state, components, URLs, whether the lab CA is trusted #121

Description

@teemow

Part of #119. Builds on the registry of #120.

Problem

"Which labs do I have, and is the cluster running?" is answered today with docker ps, the kind CLI (which the binary no longer needs) and remembering directories.

Proposed solution

agentlab list (alias ls) prints one row per registered lab and marks the current directory's: the name, the directory, the cluster state — running, exited (the node container a down that lost its race with docker leaves behind, node.go), not created (no kind cluster of that name, kindClusters()) — the enabled components (platform, agents, observability, Backstage; the chart version, or chartPath while set), the URLs (Backstage, muster's MCP endpoint, with the port suffix when the edge is not on 443) and whether the lab CA is trusted on this machine (SystemTrusted()). kind clusters no lab claims are not listed — they are not agentlab's.

Nothing here needs the apiserver: the registry, the config files and docker answer, so list works while a lab is down. list never asks which lab — it is the command that shows them. -o json for scripts (should-have).

Acceptance criteria

  • With two labs, one up and one down, agentlab list shows both with the right state, marks the current directory's, and the URLs of the lab on port 8443 carry the suffix.
  • With no registered lab: one line saying so and that agentlab up in an empty directory creates one.
  • Unit tests on a registry fixture; the cluster-state probe is stubbed the way kindKubeconfigRaw is.
  • docs/cli.md lists it in the everyday-use group.

Activity

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

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions