diff --git a/components/operator/apis/stack/v1beta3/stack_types.go b/components/operator/apis/stack/v1beta3/stack_types.go index 0e6ab97407..f320f3c56e 100644 --- a/components/operator/apis/stack/v1beta3/stack_types.go +++ b/components/operator/apis/stack/v1beta3/stack_types.go @@ -94,9 +94,6 @@ type StackAuthSpec struct { type StackStargateConfig struct { StargateServerURL string `json:"stargateServerURL"` - AuthClientID string `json:"authClientId"` - AuthClientSecret string `json:"authClientSecret"` - AuthIssuerURL string `json:"authIssuerURL"` } // StackSpec defines the desired state of Stack diff --git a/components/operator/config/crd/bases/stack.formance.com_stacks.yaml b/components/operator/config/crd/bases/stack.formance.com_stacks.yaml index b981e5faf5..fde07ddedd 100644 --- a/components/operator/config/crd/bases/stack.formance.com_stacks.yaml +++ b/components/operator/config/crd/bases/stack.formance.com_stacks.yaml @@ -1927,18 +1927,9 @@ spec: type: string stargate: properties: - authClientId: - type: string - authClientSecret: - type: string - authIssuerURL: - type: string stargateServerURL: type: string required: - - authClientId - - authClientSecret - - authIssuerURL - stargateServerURL type: object versions: diff --git a/components/operator/internal/handlers/handler_stargate.go b/components/operator/internal/handlers/handler_stargate.go index 72b231cf0e..0c16cc5e49 100644 --- a/components/operator/internal/handlers/handler_stargate.go +++ b/components/operator/internal/handlers/handler_stargate.go @@ -19,9 +19,9 @@ func init() { modules.Env("STACK_ID", stackID), modules.Env("STARGATE_SERVER_URL", resolveContext.Stack.Spec.Stargate.StargateServerURL), modules.Env("GATEWAY_URL", "http://gateway:"+strconv.Itoa(int(resolveContext.RegisteredModules["gateway"].Module.Services(resolveContext.Context)[0].Port))), - modules.Env("STARGATE_AUTH_CLIENT_ID", resolveContext.Stack.Spec.Stargate.AuthClientID), - modules.Env("STARGATE_AUTH_CLIENT_SECRET", resolveContext.Stack.Spec.Stargate.AuthClientSecret), - modules.Env("STARGATE_AUTH_ISSUER_URL", resolveContext.Stack.Spec.Stargate.AuthIssuerURL), + modules.Env("STARGATE_AUTH_CLIENT_ID", resolveContext.Stack.Spec.Auth.DelegatedOIDCServer.ClientID), + modules.Env("STARGATE_AUTH_CLIENT_SECRET", resolveContext.Stack.Spec.Auth.DelegatedOIDCServer.ClientSecret), + modules.Env("STARGATE_AUTH_ISSUER_URL", resolveContext.Stack.Spec.Auth.DelegatedOIDCServer.Issuer), ) } modules.Register("stargate", modules.Module{