func()

in teamcity/auth.go [63:181]


func (r *authResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse) {
	resp.Schema = schema.Schema{
		Description: "TeamCity can authenticate users via an internal database, or can integrate into your system and use external authentication sources such as Windows Domain, LDAP, or Git hosting providers. More details [here](https://www.jetbrains.com/help/teamcity/configuring-authentication-settings.html)",
		Attributes: map[string]schema.Attribute{
			"allow_guest": schema.BoolAttribute{
				Required: true,
			},
			"guest_username": schema.StringAttribute{
				Required: true,
			},
			"welcome_text": schema.StringAttribute{
				Required: true,
			},
			"collapse_login_form": schema.BoolAttribute{
				Required: true,
			},
			//"two_factor_mode": schema.StringAttribute{
			//	Required: true,
			//	Validators: []validator.String{
			//		stringvalidator.OneOf([]string{"DISABLED", "OPTIONAL", "MANDATORY"}...),
			//	},
			//},
			"per_project_permissions": schema.BoolAttribute{
				Required: true,
			},
			"email_verification": schema.BoolAttribute{
				Required: true,
			},
			"modules": schema.SingleNestedAttribute{
				Required: true,
				Attributes: map[string]schema.Attribute{
					"token": schema.SingleNestedAttribute{
						Required: true,
					},
					"built_in": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"registration": schema.BoolAttribute{
								Required: true,
							},
							"change_passwords": schema.BoolAttribute{
								Required: true,
							},
							"reset_passwords": schema.BoolAttribute{
								Optional: true,
							},
						},
					},
					"basic_http": schema.SingleNestedAttribute{
						Optional: true,
					},
					"google": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
							"all_domains": schema.BoolAttribute{
								Required: true,
							},
							"domains": schema.StringAttribute{
								Optional: true,
							},
						},
					},
					"github_app": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
							"organizations": schema.StringAttribute{
								Required: true,
							},
						},
					},
					"github": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
							"organizations": schema.StringAttribute{
								Required: true,
							},
						},
					},
					"github_enterprise": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
							"organizations": schema.StringAttribute{
								Required: true,
							},
						},
					},
					"ldap": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
						},
					},
					"jetbrains_space": schema.SingleNestedAttribute{
						Optional: true,
						Attributes: map[string]schema.Attribute{
							"create_new_users": schema.BoolAttribute{
								Required: true,
							},
						},
					},
				},
			},
		},
	}
}