Show Code Suggestions menu item for paid plans only on SM instance
What does this MR do and why?
Show Code Suggestions menu item for paid plans only on SM instance
Related to #435912
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.
Scenario | Before | After |
---|---|---|
Free plan | ||
Paid plan (no change) |
How to set up and validate locally
Application setup
- Customers Dot needs to be setup
- Start GDK in SM mode
GITLAB_SIMULATE_SAAS=0 gdk start
Feature flag
Run the following in your rails console using GITLAB_SIMULATE_SAAS=0 rails c
.
We don't need this feature flag for the menu item to not show up, but its to verify that the menu item doesn't show up despite the feature flag being in enabled state for SM.
Feature.enable(:self_managed_code_suggestions)
Subscription setup
- Make sure there is no active subscription on the instance by going to
Admin area
>Subscription
- If there is one, use
Remove license
to remove it
After the MR verification, if you need a license, you can follow the below steps to setup one:
- Buy
Self-Managed Ultimate 1 Year
subscription on Zuora Sandbox - Copy the license key from the subscription details page on local Customers Dot instance
- Paste the license key on your SM instance at
Admin Area > Settings > General > Add license
- Go to
Admin area
>Subscription
=> you should be able to see the new license
Code Suggestions menu item
- Log in to the SM instance as an admin, eg.
root
- Go to the menu under
Admin area
- Make sure the menu doesn't have an entry for
Code Suggestions
beneath Subscription.
Edited by Vamsi Vempati