Rails: Add validation for image_pull_secrets when using shared namespace mode
-
Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA. As a benefit of being a GitLab Community Contributor, you receive complimentary access to GitLab Duo.
What does this MR do and why?
- Add model validation in
RemoteDevelopment::WorkspacesAgentConfigto ensure every item inimage_pull_secretsin theworkspace_agent_configstable, thenamespaceattribute should be the same asshared_namespacecolumn on theworkspace_agent_configstable ifshared_namespaceis not nil. - Update the unit tests at
ee/spec/models/remote_development/workspaces_agent_config_spec.rband the integration tests atee/spec/models/remote_development/workspace_spec.rb.
References
Rails: Add validation for image_pull_secrets wh... (#519276 - closed) • Vishal Tak, jp-govau • 18.0
Screenshots or screen recordings
| Before | After |
|---|---|
How to set up and validate locally
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Edited by Chad Woolley