Fill the Artifact Registry manifest Overview tab

What does this MR do and why?

The Overview tab on the container manifest detail page has been an empty panel since the tab set shipped. This fills it with the two pull commands the design shows: by tag when the manifest is tagged, and by digest always.

Three decisions worth a reviewer's attention:

  • Only the first section the snippet builder returns is rendered. The builder also returns a registry-setup section carrying a token placeholder, which belongs to the repository setup drawer; the design shows no sign-in block on this tab. installSnippetBlock was not reusable here because it returns one block and this tab renders two.
  • The format now reaches the container builder, so an OCI artifact pulls with oras. The arm is scoped to the by-digest branch, the only one this tab reaches. The tool list offers Docker and Podman for both container formats and is shared with the setup drawer, which addresses a tag, so widening the client choice to the whole builder would change that drawer for every OCI repository. There is a spec pinning the drawer's side of it, and I confirmed in the browser that an OCI repository's drawer still reads docker pull / docker push.
  • No panel heading and no tool selector, matching the design rather than the version detail page one route away. That page wraps its snippet in an "Install" panel with a tool selector, which earns its place there because a Maven or npm reader has a build tool to choose; a container reader on this tab does not.

The tag named by pull-by-tag is the first as served, which the contract delivers name-ascending, so two reads name the same tag.

A review pass by a second agent found five things worth fixing, all addressed here: the tab rendered a blank panel rather than a message when the builder's digest or charset guard rejected a value; a manifest arriving without a digest fell through to the builder's :tag placeholder arm (and lost the oras client with it); the snippet was composed from the route segment rather than the resolved repository.name; a manifest whose image did not resolve rendered a plausible-looking command naming a non-existent image; and the block label was a bold span rather than a p. There is now a single Pull commands are unavailable for this manifest. state covering all of the cases where no honest command can be built, wording that does not claim which one it hit.

Known inconsistency, not fixed here. The version list's row action opens a pull-command drawer built by a separate builder (pull_snippets.js), which emits a shell-quoted docker pull for OCI. After this MR the Overview tab and that drawer disagree on the client for the same manifest. Reconciling them means changing a surface this step does not own, so I have left it — happy to fold it in if you would rather.

EE-only and behind artifact_registry_ui, which is default-off, so there is no changelog trailer. No new externalized strings - the labels and copy-button titles were added when the builder was parameterized.

References

Screenshots or screen recordings

Before After
before after

Both full-page, same Docker manifest. The other two states:

Untagged (pull by digest alone) OCI (oras)
untagged oci

How to set up and validate locally

  1. In the Rails console, enable the flag:
    Feature.enable(:artifact_registry_ui)
  2. Open a container repository, note an image id from the artifacts list, and reach a manifest of it by URL - the seeded manifest ladder derives from the image id, and its digests are its own rather than the ones the manifests connection returns.
  3. A tagged index renders Pull by tag: and Pull by digest:; an untagged platform child renders pull-by-digest alone, with no literal :tag placeholder.
  4. An OCI repository renders oras pull, a Docker one docker pull.
  5. Open the same OCI repository's Setup instructions drawer and confirm it still reads docker pull / docker push - this MR does not change it.
  6. Storybook covers the untagged case as UntaggedOverview and the OCI case as OciIndex.

Jest passes on both Vue versions.

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Zack Cuddy

Merge request reports

Loading
Loading