-
Notifications
You must be signed in to change notification settings - Fork 87
datasource_service
ArthurHlt edited this page Aug 31, 2020
·
4 revisions
Gets information on a Cloud Foundry service definition.
The following example looks up a service definition named 'p-redis', globally.
data "cloudfoundry_service" "redis" {
name = "p-redis"
}
The following example looks up a service named 'p-redis', registered as a space-scoped service within the specified Space id
data "cloudfoundry_service" "redis" {
name = "p-redis"
space = cloudfoundry_space.dev.id
}
The following example looks up a service named 'p-redis', registered as a space-scoped service within the specified Space id provided by a specific service broker (its guid is hardcoded here because service brokers are not always visible to non admin users of cloud foundry).
data "cloudfoundry_service" "redis" {
name = "p-redis"
space = cloudfoundry_space.dev.id
service_broker_guid = "5716f06c-b3a2-4e8a-893f-39870b0c9f42"
}
The following arguments are supported:
-
name
- (Required) The name of the service to look up -
space
- (Optional) The space within which the service is defined (as a space-scoped service) -
service_broker_guid
- (Optional) The guid of the service broker which offers the service. You can use this to filter two equally named services from different brokers.
The following attributes are exported:
-
id
- The GUID of the service -
service_plans
- Map of service plan GUIDs keyed by service "<service name>/<plan name>" -
service_broker_name
- The name of the service broker that offers the service.
- cloudfoundry_app
- cloudfoundry_asg
- cloudfoundry_domain
- cloudfoundry_info
- cloudfoundry_isolation_segment
- cloudfoundry_org
- cloudfoundry_org_quota
- cloudfoundry_route
- cloudfoundry_router_group
- cloudfoundry_service
- cloudfoundry_service_instance
- cloudfoundry_service_key
- cloudfoundry_space
- cloudfoundry_space_quota
- cloudfoundry_stack
- cloudfoundry_user
- cloudfoundry_user_provided_service
- cloudfoundry_app
- cloudfoundry_asg
- cloudfoundry_buildpack
- cloudfoundry_default_asg
- cloudfoundry_domain
- cloudfoundry_evg
- cloudfoundry_feature_flag
- cloudfoundry_isolation_segment
- cloudfoundry_isolation_segment_entitlement
- cloudfoundry_network_policy
- cloudfoundry_org
- cloudfoundry_org_quota
- cloudfoundry_org_users
- cloudfoundry_private_domain_access
- cloudfoundry_route
- cloudfoundry_route_service_binding
- cloudfoundry_service_broker
- cloudfoundry_service_instance
- cloudfoundry_service_key
- cloudfoundry_service_plan_access
- cloudfoundry_space
- cloudfoundry_space_quota
- cloudfoundry_space_users
- cloudfoundry_user
- cloudfoundry_user_provided_service