mirror of
https://github.com/rancher/types.git
synced 2025-08-31 21:00:16 +00:00
disable keycloak auth
This commit is contained in:
@@ -417,14 +417,14 @@ func authnTypes(schemas *types.Schemas) *types.Schemas {
|
||||
MustImport(&Version, v3.FreeIpaTestAndApplyInput{}).
|
||||
// Saml Config
|
||||
// Ping-Saml Config
|
||||
MustImportAndCustomize(&Version, v3.PingConfig{}, configSchema).
|
||||
MustImportAndCustomize(&Version, v3.ADFSConfig{}, configSchema).
|
||||
MustImportAndCustomize(&Version, v3.KeyCloakConfig{}, configSchema).
|
||||
MustImportAndCustomize(&Version, v3.PingConfig{}, configSchemaEnable).
|
||||
MustImportAndCustomize(&Version, v3.ADFSConfig{}, configSchemaEnable).
|
||||
MustImportAndCustomize(&Version, v3.KeyCloakConfig{}, configSchemaDisable).
|
||||
MustImport(&Version, v3.SamlConfigTestInput{}).
|
||||
MustImport(&Version, v3.SamlConfigTestOutput{})
|
||||
}
|
||||
|
||||
func configSchema(schema *types.Schema) {
|
||||
func configSchemaEnable(schema *types.Schema) {
|
||||
schema.BaseType = "authConfig"
|
||||
schema.ResourceActions = map[string]types.Action{
|
||||
"disable": {},
|
||||
@@ -437,6 +437,19 @@ func configSchema(schema *types.Schema) {
|
||||
schema.ResourceMethods = []string{http.MethodGet, http.MethodPut}
|
||||
}
|
||||
|
||||
func configSchemaDisable(schema *types.Schema) {
|
||||
schema.BaseType = "authConfig"
|
||||
schema.ResourceActions = map[string]types.Action{
|
||||
"disable": {},
|
||||
"testAndEnable": {
|
||||
Input: "samlConfigTestInput",
|
||||
Output: "samlConfigTestOutput",
|
||||
},
|
||||
}
|
||||
schema.CollectionMethods = []string{}
|
||||
schema.ResourceMethods = []string{}
|
||||
}
|
||||
|
||||
func userTypes(schema *types.Schemas) *types.Schemas {
|
||||
return schema.
|
||||
MustImportAndCustomize(&Version, v3.Preference{}, func(schema *types.Schema) {
|
||||
|
Reference in New Issue
Block a user