Skip to content

datasource_service

ArthurHlt edited this page Dec 11, 2019 · 4 revisions

cloudfoundry_service

Gets information on a Cloud Foundry service definition.

Example Usage

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}"  
}

Argument Reference

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)

Attributes Reference

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>"
Clone this wiki locally