Introduce default configuration profiles in the Example App
MR: Pending
Description
The Example App is a great way to quickly test changes to the Web IDE without having to generate a package locally and updating it in the GitLab Rails app. We can also connect to different environments/profiles, such as gdk and/or gitlab.com via the configuration form UI. It is also used in the Web IDE MR pipeline to verify the functionality without checking things out locally.
Most of the time, we don't need to change these configurations. We could greatly benefit from file-based default configuration profiles to bypass the need of filling out the form. For iterative purposes, we will start with supporting authType: none only.
Acceptance Criteria
-
When running yarn start:examplewith aprofileflag, we will start the Web IDE based on default configs set for that profile without seeing the config form UI. -
When running yarn start:examplewithout aprofileflag, the config form is displayed.
Technical Requirements
- Create a
profile.jsonwith default configs based on the ExampleConfig type for GDK andgitlab.comprofiles. - Update
vite.config.tsto check for presence ofprofileflag and store as global variable [doc]. - Modify
App.vueto read fromprofile.jsonbased on the profile flag if it exists and set to config state. Also want to setrunWebIdeto true if the profile exists.
Edited by Victoria Owusu