Refactoring of Duo UI components before adding Duo with Amazon Q
What does this MR do and why?
We want to introduce Duo with Amazon Q to the Duo frontend. For this we want to make this change as easy as possible and because of that I want to introduce this refactoring here.
References
Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
- Contributes to https://gitlab.com/gitlab-org/gitlab/-/issues/517922
MR acceptance checklist
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 | After | |
|---|---|---|
| http://localhost:3000/admin/gitlab_duo | ![]() |
![]() |
| http://localhost:3000/admin/gitlab_duo/seat_utilization | ![]() |
![]() |
| http://localhost:3000/admin/gitlab_duo/configuration | ![]() |
![]() |
How to set up and validate locally
Simple verification
The logic does not change, so a green test suite is sufficient.
Extended verification
Requirement
- Local GitLab instance
- Self-Managed Ultimate license
Steps
- Start your GitLab instance in Self-Managed mode.
- Execute for that the following command
export GITLAB_SIMULATE_SAAS=0; gdk restart
- Execute for that the following command
- Ensure you have applied a Self-Managed Ultimate license
- You can add the license here http://localhost:3000/admin/subscription
- Provision yourself a Duo Enterprise add-on purchase
-
Go to the Rails console and execute the following command
GitlabSubscriptions::AddOnPurchase.create!( subscription_add_on_id: GitlabSubscriptions::AddOn.find_by(name: "duo_enterprise").id, expires_on: 1.month.from_now, quantity: 1, purchase_xid: 123, started_at: 1.day.ago, namespace_id: nil, organization: Organizations::Organization.first )
-
- Surf through the following pages and ensure that the components get rendered and you can assign and unassign seats





