File tree Expand file tree Collapse file tree
cmd/thv-operator/pkg/vmcpconfig Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -452,8 +452,15 @@ func (c *Converter) convertBackendAuthConfig(
452452 }, nil
453453 }
454454
455- // If type is "externalAuthConfigRef", resolve the MCPExternalAuthConfig
456- if crdConfig .Type == mcpv1alpha1 .BackendAuthTypeExternalAuthConfigRef {
455+ // Handle deprecated snake_case value
456+ if crdConfig .Type == mcpv1alpha1 .DeprecatedBackendAuthTypeExternalAuthConfigRef {
457+ log .FromContext (ctx ).Info ("backend auth type value \" external_auth_config_ref\" is deprecated, use \" externalAuthConfigRef\" instead" ,
458+ "backend" , backendName , "vmcp" , vmcp .Name )
459+ }
460+
461+ // If type is "externalAuthConfigRef" (or deprecated "external_auth_config_ref"), resolve the MCPExternalAuthConfig
462+ if crdConfig .Type == mcpv1alpha1 .BackendAuthTypeExternalAuthConfigRef ||
463+ crdConfig .Type == mcpv1alpha1 .DeprecatedBackendAuthTypeExternalAuthConfigRef {
457464 if crdConfig .ExternalAuthConfigRef == nil {
458465 return nil , fmt .Errorf ("backend %s: externalAuthConfigRef type requires externalAuthConfigRef field" , backendName )
459466 }
You can’t perform that action at this time.
0 commit comments