in teamcity/cleaunp.go [52:102]
func (r *cleanupResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse) {
resp.Schema = schema.Schema{
Description: "[TeamCity clean-up](https://www.jetbrains.com/help/teamcity/teamcity-data-clean-up.html) functionality allows an automatic deletion of old and no longer necessary build data.",
Attributes: map[string]schema.Attribute{
"enabled": schema.BoolAttribute{
Required: true,
},
"max_duration": schema.Int64Attribute{
Required: true,
},
"daily": schema.SingleNestedAttribute{
Optional: true,
Attributes: map[string]schema.Attribute{
"hour": schema.Int64Attribute{
Required: true,
},
"minute": schema.Int64Attribute{
Required: true,
},
},
},
"cron": schema.SingleNestedAttribute{
Optional: true,
Attributes: map[string]schema.Attribute{
"minute": schema.StringAttribute{
Required: true,
},
"hour": schema.StringAttribute{
Required: true,
},
"day": schema.StringAttribute{
Required: true,
},
"month": schema.StringAttribute{
Required: true,
},
"day_week": schema.StringAttribute{
Required: true,
},
},
Validators: []validator.Object{
objectvalidator.ExactlyOneOf(
path.MatchRoot("daily"),
path.MatchRoot("cron"),
),
},
},
},
}
}