generated from hashicorp/terraform-provider-scaffolding
-
Notifications
You must be signed in to change notification settings - Fork 40
/
dynatrace_data_source.go
36 lines (31 loc) · 1012 Bytes
/
dynatrace_data_source.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
package connector
import (
"github.com/harness/terraform-provider-harness/helpers"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
)
func DatasourceConnectorDynatrace() *schema.Resource {
resource := &schema.Resource{
Description: "Datasource for looking up a Dynatrace connector.",
ReadContext: resourceConnectorDynatraceRead,
Schema: map[string]*schema.Schema{
"url": {
Description: "URL of the Dynatrace server.",
Type: schema.TypeString,
Computed: true,
},
"api_token_ref": {
Description: "The reference to the Harness secret containing the api token." + secret_ref_text,
Type: schema.TypeString,
Computed: true,
},
"delegate_selectors": {
Description: "Tags to filter delegates for connection.",
Type: schema.TypeSet,
Computed: true,
Elem: &schema.Schema{Type: schema.TypeString},
},
},
}
helpers.SetMultiLevelDatasourceSchemaIdentifierRequired(resource.Schema)
return resource
}