/
edgegateways_schema.go
76 lines (72 loc) · 2.53 KB
/
edgegateways_schema.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
// Package edgegw provides a Terraform resource to manage edge gateways.
package edgegw
import (
"context"
schemaD "github.com/hashicorp/terraform-plugin-framework/datasource/schema"
superschema "github.com/FrangipaneTeam/terraform-plugin-framework-superschema"
)
func edgeGatewaysSuperSchema(_ context.Context) superschema.Schema {
return superschema.Schema{
DataSource: superschema.SchemaDetails{
MarkdownDescription: "The edge gateways data source show the list of edge gateways of an organization.",
},
Attributes: superschema.Attributes{
"id": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "Generated ID of the resource.",
},
},
"edge_gateways": superschema.SuperListNestedAttributeOf[edgeGatewayDataSourceModelEdgeGateway]{
DataSource: &schemaD.ListNestedAttribute{
Computed: true,
MarkdownDescription: "A list of Edge Gateways.",
},
Attributes: superschema.Attributes{
"tier0_vrf_name": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The name of the Tier-0 VRF to which the Edge Gateway is attached.",
},
},
"name": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The name of the Edge Gateway.",
},
},
"id": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The ID of the Edge Gateway.",
},
},
"owner_type": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The type of the Edge Gateway owner. Must be vdc or vdc-group.",
},
},
"owner_name": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The name of the Edge Gateway owner.",
},
},
"description": superschema.SuperStringAttribute{
DataSource: &schemaD.StringAttribute{
Computed: true,
MarkdownDescription: "The description of the Edge Gateway.",
},
},
"lb_enabled": superschema.SuperBoolAttribute{
DataSource: &schemaD.BoolAttribute{
Computed: true,
MarkdownDescription: "Load Balancing state on the Edge Gateway.",
},
},
},
},
},
}
}