Skip to content

Fix capitalisation of container registry image path

What does this MR do and why?

After enabling the [Feature flag] Rollout of `container_registry_s... (#366808 - closed) for gitlab-org group (related MR: Display container image shortened path with opt... (!91548 - merged)), noticed that some image names were capitalised, so MR fixes this issue.

Visible here: https://gitlab.com/groups/gitlab-org/-/container_registries Screen_Shot_2022-07-18_at_7.11.21_pm

Screenshots or screen recordings

Before After
Screen_Shot_2022-07-18_at_7.04.00_pm Screen_Shot_2022-07-18_at_7.05.37_pm

How to set up and validate locally

  1. Setup & enable Container Registry https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/registry.md
  2. Create a new project under gitlab-org with capital letters in the project path example CNG-mirror
  3. Run the following
    docker pull hello-world
    docker tag hello-world 127.0.0.1:5000/gitlab-org/cng-mirror
    docker push 127.0.0.1:5000/gitlab-org/cng-mirror
  4. Visit the container registry page for group http://gdk.test:3000/groups/gitlab-org/-/container_registries & make sure the images are listed & show their full path.
  5. Enable feature
    $ rails c
    > Feature.enable(:container_registry_show_shortened_path)
  6. Refresh above page to see button to expand shortened path & Make image path is not capitalised.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #364290 (closed)

Edited by Rahul Chanila

Merge request reports