Skip to content

Set Up Admin Routes for GitLab Duo LP and Seat Utilization Pages

Lindsey Shelton requested to merge admin-update-duo-usage-routes into master

What does this MR do and why?

The purpose of this MR is to reconfigure the current routes for the GitLab Duo page for Admin to /gitlab_duo/seat_utilization while work is being done to create the new landing page under /gitlab_duo.

We also want to be sure that all old paths redirect to the new gitlab_duo/seat_utilization page for now.

Related Issues:

  • #496289 (closed) - Duo Settings Page - Reroute GitLab Duo as Seat Utilization Page
  • #497585 (closed) - Create new Routes for GitLab Duo for Admin to direct to new Seat Utilization Page

Related MRs:

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

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before on Admin After on Admin After Screen Recording on Admin
Screenshot_2024-10-02_at_8.47.11_PM Screenshot_2024-10-04_at_3.14.16_PM Screen_Recording_2024-10-04_at_3.13.44_PM

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

For frontend changes:

You will need an GitLab Ultimate license for these changes as well as a connection to CustomersDot.

In gitlab-development-kit

  • env.runit example
export GITLAB_SIMULATE_SAAS=0
export GITLAB_LICENSE_MODE=test
export LLM_DEBUG=1
export AI_GATEWAY_URL=http://0.0.0.0:5052
export CLOUD_CONNECTOR_SELF_SIGN_TOKENS=1
export CUSTOMER_PORTAL_URL=https://customers.staging.gitlab.com/
  • gdk.yml example to set up CDot
license:
  customer_portal_url: https://customers.staging.gitlab.com
  license_mode: test

Admin - SM Instance 0. Run GITLAB_SIMULATE_SAAS=0 gdk restart in your GDK.

  1. Go to Admin > GitLab Duo.
  2. Validate page redirects to admin/gitlab_duo/seat_utilization.
  3. Validate title now says Seat utilization and that breadcrumbs exist.
  4. Use the following path admin/code_suggestions, and validate that it also redirects to admin/gitlab_duo_seat_utilization.

For backend changes:

  1. Run `bundle exec rspec ee/spec/lib/sidebars/admin/menus/code_suggestions_menu_spec.rb
  2. Run bundle exec rspec ee/spec/lib/sidebars/admin/panel_spec.rb
  3. Run bundle exec rspec ee/spec/requests/admin/gitlab_duo/seat_utilization_controller_spec.rb
Edited by Lindsey Shelton

Merge request reports

Loading