Hetzner Cloud v1.20.4 published on Tuesday, Sep 24, 2024 by Pulumi
hcloud.getDatacenters
Explore with Pulumi AI
Provides a list of available Hetzner Cloud Datacenters. This resource may be useful to create highly available infrastructure, distributed across several datacenters.
Using getDatacenters
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getDatacenters(args: GetDatacentersArgs, opts?: InvokeOptions): Promise<GetDatacentersResult>
function getDatacentersOutput(args: GetDatacentersOutputArgs, opts?: InvokeOptions): Output<GetDatacentersResult>
def get_datacenters(datacenter_ids: Optional[Sequence[str]] = None,
descriptions: Optional[Sequence[str]] = None,
id: Optional[str] = None,
names: Optional[Sequence[str]] = None,
opts: Optional[InvokeOptions] = None) -> GetDatacentersResult
def get_datacenters_output(datacenter_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
descriptions: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
id: Optional[pulumi.Input[str]] = None,
names: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDatacentersResult]
func GetDatacenters(ctx *Context, args *GetDatacentersArgs, opts ...InvokeOption) (*GetDatacentersResult, error)
func GetDatacentersOutput(ctx *Context, args *GetDatacentersOutputArgs, opts ...InvokeOption) GetDatacentersResultOutput
> Note: This function is named GetDatacenters
in the Go SDK.
public static class GetDatacenters
{
public static Task<GetDatacentersResult> InvokeAsync(GetDatacentersArgs args, InvokeOptions? opts = null)
public static Output<GetDatacentersResult> Invoke(GetDatacentersInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDatacentersResult> getDatacenters(GetDatacentersArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: hcloud:index/getDatacenters:getDatacenters
arguments:
# arguments dictionary
The following arguments are supported:
- Datacenter
Ids List<string> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - Descriptions List<string>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - Id string
- Names List<string>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- Datacenter
Ids []string - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - Descriptions []string
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - Id string
- Names []string
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenter
Ids List<String> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions List<String>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id String
- names List<String>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenter
Ids string[] - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions string[]
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id string
- names string[]
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenter_
ids Sequence[str] - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions Sequence[str]
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id str
- names Sequence[str]
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenter
Ids List<String> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions List<String>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id String
- names List<String>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
getDatacenters Result
The following output properties are available:
- Datacenters
List<Pulumi.
HCloud. Outputs. Get Datacenters Datacenter> - (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - Datacenter
Ids List<string> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - Descriptions List<string>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - Id string
- Names List<string>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- Datacenters
[]Get
Datacenters Datacenter - (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - Datacenter
Ids []string - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - Descriptions []string
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - Id string
- Names []string
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenters
List<Get
Datacenters Datacenter> - (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - datacenter
Ids List<String> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions List<String>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id String
- names List<String>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenters
Get
Datacenters Datacenter[] - (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - datacenter
Ids string[] - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions string[]
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id string
- names string[]
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenters
Sequence[Get
Datacenters Datacenter] - (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - datacenter_
ids Sequence[str] - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions Sequence[str]
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id str
- names Sequence[str]
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
- datacenters List<Property Map>
- (list) List of all datacenters. See
data.hcloud_datacenter
for schema. - datacenter
Ids List<String> - (list) List of unique datacenter identifiers. Deprecated: Use
datacenters
attribute instead. - descriptions List<String>
- (list) List of all datacenter descriptions. Deprecated: Use
datacenters
attribute instead. - id String
- names List<String>
- (list) List of datacenter names. Deprecated: Use
datacenters
attribute instead.
Supporting Types
GetDatacentersDatacenter
- Available
Server List<int>Type Ids - Description string
- Id int
- Location Dictionary<string, string>
- Name string
- Supported
Server List<int>Type Ids
- Available
Server []intType Ids - Description string
- Id int
- Location map[string]string
- Name string
- Supported
Server []intType Ids
- available
Server List<Integer>Type Ids - description String
- id Integer
- location Map<String,String>
- name String
- supported
Server List<Integer>Type Ids
- available
Server number[]Type Ids - description string
- id number
- location {[key: string]: string}
- name string
- supported
Server number[]Type Ids
- available_
server_ Sequence[int]type_ ids - description str
- id int
- location Mapping[str, str]
- name str
- supported_
server_ Sequence[int]type_ ids
- available
Server List<Number>Type Ids - description String
- id Number
- location Map<String>
- name String
- supported
Server List<Number>Type Ids
Package Details
- Repository
- Hetzner Cloud pulumi/pulumi-hcloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
hcloud
Terraform Provider.