CDN distribution: add string validator for backend type (#798)
* CDN distribution: add string validator for backend type * Update stackit/internal/services/cdn/distribution/resource.go Co-authored-by: Rüdiger Schmitz <ruediger.schmitz@inovex.de> * fix suggestion apply --------- Co-authored-by: Malte Ehrlen <malte.ehrlen@freiheit.com> Co-authored-by: Rüdiger Schmitz <ruediger.schmitz@inovex.de>
This commit is contained in:
parent
30a01c3037
commit
89fa6e5777
4 changed files with 10 additions and 5 deletions
|
|
@ -73,6 +73,7 @@ func (r *distributionDataSource) Metadata(_ context.Context, req datasource.Meta
|
|||
}
|
||||
|
||||
func (r *distributionDataSource) Schema(_ context.Context, _ datasource.SchemaRequest, resp *datasource.SchemaResponse) {
|
||||
backendOptions := []string{"http"}
|
||||
resp.Schema = schema.Schema{
|
||||
MarkdownDescription: features.AddBetaDescription("CDN distribution data source schema."),
|
||||
Description: "CDN distribution data source schema.",
|
||||
|
|
@ -147,7 +148,7 @@ func (r *distributionDataSource) Schema(_ context.Context, _ datasource.SchemaRe
|
|||
Attributes: map[string]schema.Attribute{
|
||||
"type": schema.StringAttribute{
|
||||
Computed: true,
|
||||
Description: schemaDescriptions["config_backend_type"],
|
||||
Description: schemaDescriptions["config_backend_type"] + utils.SupportedValuesDocumentation(backendOptions),
|
||||
},
|
||||
"origin_url": schema.StringAttribute{
|
||||
Computed: true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue