This page documents the language specification for the hcloud package. If you're looking for help working with the inputs, outputs, or functions of hcloud resources in a Pulumi program, please see the resource documentation for examples and API reference.
Pulumi HCloud¶
This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-hcloud repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-hcloud repo.
- class
pulumi_hcloud.AwaitableGetCertificateResult(certificate=None, created=None, domain_names=None, fingerprint=None, id=None, labels=None, name=None, not_valid_after=None, not_valid_before=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetDatacenterResult(available_server_type_ids=None, description=None, id=None, location=None, name=None, supported_server_type_ids=None)¶
- class
pulumi_hcloud.AwaitableGetDatacentersResult(datacenter_ids=None, descriptions=None, id=None, names=None)¶
- class
pulumi_hcloud.AwaitableGetFloatingIpResult(description=None, home_location=None, id=None, ip_address=None, ip_network=None, labels=None, name=None, selector=None, server_id=None, type=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetImageResult(created=None, deprecated=None, description=None, id=None, labels=None, most_recent=None, name=None, os_flavor=None, os_version=None, rapid_deploy=None, selector=None, type=None, with_selector=None, with_statuses=None)¶
- class
pulumi_hcloud.AwaitableGetLoadBalancerResult(algorithm=None, id=None, ipv4=None, ipv6=None, labels=None, load_balancer_type=None, location=None, name=None, network_zone=None, services=None, targets=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetLocationResult(city=None, country=None, description=None, id=None, latitude=None, longitude=None, name=None)¶
- class
pulumi_hcloud.AwaitableGetLocationsResult(descriptions=None, id=None, location_ids=None, names=None)¶
- class
pulumi_hcloud.AwaitableGetNetworkResult(id=None, ip_range=None, labels=None, name=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetServerResult(backup_window=None, backups=None, datacenter=None, id=None, image=None, ipv4_address=None, ipv6_address=None, ipv6_network=None, iso=None, labels=None, location=None, name=None, rescue=None, selector=None, server_type=None, status=None, with_selector=None, with_statuses=None)¶
- class
pulumi_hcloud.AwaitableGetSshKeyResult(fingerprint=None, id=None, labels=None, name=None, public_key=None, selector=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetSshKeysResult(id=None, ssh_keys=None, with_selector=None)¶
- class
pulumi_hcloud.AwaitableGetVolumeResult(id=None, labels=None, linux_device=None, location=None, name=None, selector=None, server=None, size=None, with_selector=None, with_statuses=None)¶
- class
pulumi_hcloud.Certificate(resource_name, opts=None, certificate=None, labels=None, name=None, private_key=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Clould Certificate to represent a TLS certificate in the Hetzner Cloud.
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, certificate=None, created=None, domain_names=None, fingerprint=None, labels=None, name=None, not_valid_after=None, not_valid_before=None, private_key=None)¶ Get an existing Certificate resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.FloatingIp(resource_name, opts=None, description=None, home_location=None, labels=None, name=None, server_id=None, type=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Floating IP to represent a publicly-accessible static IP address that can be mapped to one of your servers.
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", image="debian-9", server_type="cx11") master = hcloud.FloatingIp("master", server_id=node1.id, type="ipv4")
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, description=None, home_location=None, ip_address=None, ip_network=None, labels=None, name=None, server_id=None, type=None)¶ Get an existing FloatingIp resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.FloatingIpAssignment(resource_name, opts=None, floating_ip_id=None, server_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Floating IP Assignment to assign a Floating IP to a Hetzner Cloud Server. Deleting a Floating IP Assignment will unassign the Floating IP from the Server.
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", datacenter="fsn1-dc8", image="debian-9", server_type="cx11") master = hcloud.FloatingIp("master", home_location="nbg1", type="ipv4") main = hcloud.FloatingIpAssignment("main", floating_ip_id=master.id, server_id=node1.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, floating_ip_id=None, server_id=None)¶ Get an existing FloatingIpAssignment resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.GetCertificateResult(certificate=None, created=None, domain_names=None, fingerprint=None, id=None, labels=None, name=None, not_valid_after=None, not_valid_before=None, with_selector=None)¶ A collection of values returned by getCertificate.
- class
pulumi_hcloud.GetDatacenterResult(available_server_type_ids=None, description=None, id=None, location=None, name=None, supported_server_type_ids=None)¶ A collection of values returned by getDatacenter.
- class
pulumi_hcloud.GetDatacentersResult(datacenter_ids=None, descriptions=None, id=None, names=None)¶ A collection of values returned by getDatacenters.
id= None¶The provider-assigned unique ID for this managed resource.
- class
pulumi_hcloud.GetFloatingIpResult(description=None, home_location=None, id=None, ip_address=None, ip_network=None, labels=None, name=None, selector=None, server_id=None, type=None, with_selector=None)¶ A collection of values returned by getFloatingIp.
- class
pulumi_hcloud.GetImageResult(created=None, deprecated=None, description=None, id=None, labels=None, most_recent=None, name=None, os_flavor=None, os_version=None, rapid_deploy=None, selector=None, type=None, with_selector=None, with_statuses=None)¶ A collection of values returned by getImage.
- class
pulumi_hcloud.GetLoadBalancerResult(algorithm=None, id=None, ipv4=None, ipv6=None, labels=None, load_balancer_type=None, location=None, name=None, network_zone=None, services=None, targets=None, with_selector=None)¶ A collection of values returned by getLoadBalancer.
- class
pulumi_hcloud.GetLocationResult(city=None, country=None, description=None, id=None, latitude=None, longitude=None, name=None)¶ A collection of values returned by getLocation.
- class
pulumi_hcloud.GetLocationsResult(descriptions=None, id=None, location_ids=None, names=None)¶ A collection of values returned by getLocations.
id= None¶The provider-assigned unique ID for this managed resource.
- class
pulumi_hcloud.GetNetworkResult(id=None, ip_range=None, labels=None, name=None, with_selector=None)¶ A collection of values returned by getNetwork.
- class
pulumi_hcloud.GetServerResult(backup_window=None, backups=None, datacenter=None, id=None, image=None, ipv4_address=None, ipv6_address=None, ipv6_network=None, iso=None, labels=None, location=None, name=None, rescue=None, selector=None, server_type=None, status=None, with_selector=None, with_statuses=None)¶ A collection of values returned by getServer.
- class
pulumi_hcloud.GetSshKeyResult(fingerprint=None, id=None, labels=None, name=None, public_key=None, selector=None, with_selector=None)¶ A collection of values returned by getSshKey.
- class
pulumi_hcloud.GetSshKeysResult(id=None, ssh_keys=None, with_selector=None)¶ A collection of values returned by getSshKeys.
id= None¶The provider-assigned unique ID for this managed resource.
- class
pulumi_hcloud.GetVolumeResult(id=None, labels=None, linux_device=None, location=None, name=None, selector=None, server=None, size=None, with_selector=None, with_statuses=None)¶ A collection of values returned by getVolume.
- class
pulumi_hcloud.LoadBalancer(resource_name, opts=None, algorithm=None, labels=None, load_balancer_type=None, location=None, name=None, network_zone=None, targets=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Load Balancer to represent a Load Balancer in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud myserver = hcloud.Server("myserver", image="ubuntu-18.04", server_type="cx11") load_balancer = hcloud.LoadBalancer("loadBalancer", load_balancer_type="lb11", location="nbg1", targets=[{ "server_id": myserver.id, "type": "server", }])
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
The algorithm object supports the following:
type(pulumi.Input[str])
The targets object supports the following:
server_id(pulumi.Input[float])type(pulumi.Input[str])use_private_ip(pulumi.Input[bool])
- static
get(resource_name, id, opts=None, algorithm=None, ipv4=None, ipv6=None, labels=None, load_balancer_type=None, location=None, name=None, network_id=None, network_ip=None, network_zone=None, targets=None)¶ Get an existing LoadBalancer resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
The algorithm object supports the following:
type(pulumi.Input[str])
The targets object supports the following:
server_id(pulumi.Input[float])type(pulumi.Input[str])use_private_ip(pulumi.Input[bool])
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.LoadBalancerNetwork(resource_name, opts=None, enable_public_interface=None, ip=None, load_balancer_id=None, network_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Load Balancer Network to represent a private network on a Load Balancer in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud lb1 = hcloud.LoadBalancer("lb1", load_balancer_type="lb11", network_zone="eu-central") mynet = hcloud.Network("mynet", ip_range="10.0.0.0/8") foonet = hcloud.NetworkSubnet("foonet", ip_range="10.0.1.0/24", network_id=mynet.id, network_zone="eu-central", type="cloud") srvnetwork = hcloud.LoadBalancerNetwork("srvnetwork", ip="10.0.1.5", load_balancer_id=lb1.id, network_id=mynet.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, enable_public_interface=None, ip=None, load_balancer_id=None, network_id=None)¶ Get an existing LoadBalancerNetwork resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.LoadBalancerService(resource_name, opts=None, destination_port=None, health_check=None, http=None, listen_port=None, load_balancer_id=None, protocol=None, proxyprotocol=None, __props__=None, __name__=None, __opts__=None)¶ Define services for Hetzner Cloud Load Balancers.
import pulumi import pulumi_hcloud as hcloud load_balancer = hcloud.LoadBalancer("loadBalancer", load_balancer_type="lb11", location="nbg1") load_balancer_service = hcloud.LoadBalancerService("loadBalancerService", load_balancer_id=hcloud_load_balancer["test_load_balancer"]["id"], protocol="http")
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
The health_check object supports the following:
http(pulumi.Input[dict])domain(pulumi.Input[str])path(pulumi.Input[str])response(pulumi.Input[str])statusCodes(pulumi.Input[list])tls(pulumi.Input[bool])
interval(pulumi.Input[float])port(pulumi.Input[float])protocol(pulumi.Input[str])retries(pulumi.Input[float])timeout(pulumi.Input[float])
The http object supports the following:
certificates(pulumi.Input[list])cookieLifetime(pulumi.Input[float])cookieName(pulumi.Input[str])redirectHttp(pulumi.Input[bool])stickySessions(pulumi.Input[bool])
- static
get(resource_name, id, opts=None, destination_port=None, health_check=None, http=None, listen_port=None, load_balancer_id=None, protocol=None, proxyprotocol=None)¶ Get an existing LoadBalancerService resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
The health_check object supports the following:
http(pulumi.Input[dict])domain(pulumi.Input[str])path(pulumi.Input[str])response(pulumi.Input[str])statusCodes(pulumi.Input[list])tls(pulumi.Input[bool])
interval(pulumi.Input[float])port(pulumi.Input[float])protocol(pulumi.Input[str])retries(pulumi.Input[float])timeout(pulumi.Input[float])
The http object supports the following:
certificates(pulumi.Input[list])cookieLifetime(pulumi.Input[float])cookieName(pulumi.Input[str])redirectHttp(pulumi.Input[bool])stickySessions(pulumi.Input[bool])
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.LoadBalancerTarget(resource_name, opts=None, load_balancer_id=None, server_id=None, type=None, use_private_ip=None, __props__=None, __name__=None, __opts__=None)¶ Adds a target to a Hetzner Cloud Load Balancer.
import pulumi import pulumi_hcloud as hcloud my_server = hcloud.Server("myServer", image="ubuntu-18.04", server_type="cx11") load_balancer = hcloud.LoadBalancer("loadBalancer", load_balancer_type="lb11", location="nbg1") load_balancer_target = hcloud.LoadBalancerTarget("loadBalancerTarget", load_balancer_id=hcloud_load_balancer["load_balcancer"]["id"], server_id=my_server.id, type="server")
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, load_balancer_id=None, server_id=None, type=None, use_private_ip=None)¶ Get an existing LoadBalancerTarget resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.Network(resource_name, opts=None, ip_range=None, labels=None, name=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Network to represent a Network in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud priv_net = hcloud.Network("privNet", ip_range="10.0.1.0/24")
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, ip_range=None, labels=None, name=None)¶ Get an existing Network resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.NetworkRoute(resource_name, opts=None, destination=None, gateway=None, network_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Network Route to represent a Network route in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud mynet = hcloud.Network("mynet", ip_range="10.0.0.0/8") priv_net = hcloud.NetworkRoute("privNet", destination="10.100.1.0/24", gateway="10.0.1.1", network_id=mynet.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, destination=None, gateway=None, network_id=None)¶ Get an existing NetworkRoute resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.NetworkSubnet(resource_name, opts=None, ip_range=None, network_id=None, network_zone=None, type=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Network Subnet to represent a Subnet in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud mynet = hcloud.Network("mynet", ip_range="10.0.0.0/8") foonet = hcloud.NetworkSubnet("foonet", ip_range="10.0.1.0/24", network_id=mynet.id, network_zone="eu-central", type="cloud")
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, gateway=None, ip_range=None, network_id=None, network_zone=None, type=None)¶ Get an existing NetworkSubnet resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.Provider(resource_name, opts=None, endpoint=None, token=None, __props__=None, __name__=None, __opts__=None)¶ The provider type for the hcloud package. By default, resources use package-wide configuration settings, however an explicit
Providerinstance may be created and passed during resource construction to achieve fine-grained programmatic control over provider settings. See the documentation for more information.- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
token (pulumi.Input[str]) – The API token to access the Hetzner cloud.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.Rdns(resource_name, opts=None, dns_ptr=None, floating_ip_id=None, ip_address=None, server_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Reverse DNS Entry to create, modify and reset reverse dns entries for Hetzner Cloud Floating IPs or servers.
For servers:
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", image="debian-9", server_type="cx11") master = hcloud.Rdns("master", dns_ptr="example.com", ip_address=node1.ipv4_address, server_id=node1.id)
For Floating IPs:
import pulumi import pulumi_hcloud as hcloud floating1 = hcloud.FloatingIp("floating1", home_location="nbg1", type="ipv4") floating_master = hcloud.Rdns("floatingMaster", dns_ptr="example.com", floating_ip_id=floating1.id, ip_address=floating1.ip_address)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, dns_ptr=None, floating_ip_id=None, ip_address=None, server_id=None)¶ Get an existing Rdns resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.Server(resource_name, opts=None, backups=None, datacenter=None, image=None, iso=None, keep_disk=None, labels=None, location=None, name=None, rescue=None, server_type=None, ssh_keys=None, user_data=None, __props__=None, __name__=None, __opts__=None)¶ Create a Server resource with the given unique name, props, and options. :param str resource_name: The name of the resource. :param pulumi.ResourceOptions opts: Options for the resource.
- static
get(resource_name, id, opts=None, backup_window=None, backups=None, datacenter=None, image=None, ipv4_address=None, ipv6_address=None, ipv6_network=None, iso=None, keep_disk=None, labels=None, location=None, name=None, rescue=None, server_type=None, ssh_keys=None, status=None, user_data=None)¶ Get an existing Server resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- static
- class
pulumi_hcloud.ServerNetwork(resource_name, opts=None, alias_ips=None, ip=None, network_id=None, server_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Server Network to represent a private network on a server in the Hetzner Cloud.
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", image="debian-9", server_type="cx11") mynet = hcloud.Network("mynet", ip_range="10.0.0.0/8") foonet = hcloud.NetworkSubnet("foonet", ip_range="10.0.1.0/24", network_id=mynet.id, network_zone="eu-central", type="cloud") srvnetwork = hcloud.ServerNetwork("srvnetwork", ip="10.0.1.5", network_id=mynet.id, server_id=node1.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, alias_ips=None, ip=None, mac_address=None, network_id=None, server_id=None)¶ Get an existing ServerNetwork resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.SshKey(resource_name, opts=None, labels=None, name=None, public_key=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud SSH key resource to manage SSH keys for server access.
import pulumi import pulumi_hcloud as hcloud # Create a new SSH key default = hcloud.SshKey("default", public_key=(lambda path: open(path).read())("~/.ssh/id_rsa.pub"))
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, fingerprint=None, labels=None, name=None, public_key=None)¶ Get an existing SshKey resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.Volume(resource_name, opts=None, automount=None, format=None, labels=None, location=None, name=None, server_id=None, size=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud volume resource to manage volumes.
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", image="debian-9", server_type="cx11") master = hcloud.Volume("master", automount=True, server_id=node1.id, size=50)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, automount=None, format=None, labels=None, linux_device=None, location=None, name=None, server_id=None, size=None)¶ Get an existing Volume resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_hcloud.VolumeAttachment(resource_name, opts=None, automount=None, server_id=None, volume_id=None, __props__=None, __name__=None, __opts__=None)¶ Provides a Hetzner Cloud Volume attachment to attach a Volume to a Hetzner Cloud Server. Deleting a Volume Attachment will detach the Volume from the Server.
import pulumi import pulumi_hcloud as hcloud node1 = hcloud.Server("node1", datacenter="nbg1-dc3", image="debian-9", server_type="cx11") master = hcloud.Volume("master", location="nbg1", size=10) main = hcloud.VolumeAttachment("main", automount=True, server_id=node1.id, volume_id=master.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
- static
get(resource_name, id, opts=None, automount=None, server_id=None, volume_id=None)¶ Get an existing VolumeAttachment resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
pulumi_hcloud.get_certificate(id=None, name=None, with_selector=None, opts=None)¶Provides details about a specific Hetzner Cloud Certificate.
pulumi_hcloud.get_datacenter(id=None, name=None, opts=None)¶Provides details about a specific Hetzner Cloud Datacenter. Use this resource to get detailed information about specific datacenter.
import pulumi import pulumi_hcloud as hcloud ds1 = hcloud.get_datacenter(name="fsn1-dc8") ds2 = hcloud.get_datacenter(id=4)
pulumi_hcloud.get_datacenters(datacenter_ids=None, opts=None)¶Provides a list of available Hetzner Cloud Datacenters. This resource may be useful to create highly available infrastructure, distributed across several datacenters.
import pulumi import pulumi_hcloud as hcloud ds = hcloud.get_datacenters() workers = [] for range in [{"value": i} for i in range(0, 3)]: workers.append(hcloud.Server(f"workers-{range['value']}", datacenter=ds.names[range["value"]], image="debian-9", server_type="cx31"))
pulumi_hcloud.get_floating_ip(id=None, ip_address=None, name=None, selector=None, with_selector=None, opts=None)¶Provides details about a Hetzner Cloud Floating IP.
This resource can be useful when you need to determine a Floating IP ID based on the IP address.
Provides details about a Hetzner Cloud Floating IP. This resource can be useful when you need to determine a Floating IP ID based on the IP address.
import pulumi import pulumi_hcloud as hcloud ip1 = hcloud.get_floating_ip(ip_address="1.2.3.4") image2 = hcloud.get_floating_ip(with_selector="key=value") main = [] for range in [{"value": i} for i in range(0, var.counter)]: main.append(hcloud.FloatingIpAssignment(f"main-{range['value']}", floating_ip_id=ip1.id, server_id=hcloud_server["main"]["id"]))
pulumi_hcloud.get_image(id=None, most_recent=None, name=None, selector=None, with_selector=None, with_statuses=None, opts=None)¶Use this data source to access information about an existing resource.
pulumi_hcloud.get_load_balancer(id=None, name=None, with_selector=None, opts=None)¶Provides details about a specific Hetzner Cloud Server.
import pulumi import pulumi_hcloud as hcloud lb1 = hcloud.get_load_balancer(name="my-load-balancer") lb2 = hcloud.get_load_balancer(id="123") lb3 = hcloud.get_load_balancer(with_selector="key=value")
pulumi_hcloud.get_location(id=None, name=None, opts=None)¶Provides details about a specific Hetzner Cloud Location. Use this resource to get detailed information about specific location.
import pulumi import pulumi_hcloud as hcloud l1 = hcloud.get_location(name="fsn1") l2 = hcloud.get_location(id=1)
pulumi_hcloud.get_locations(location_ids=None, opts=None)¶Provides a list of available Hetzner Cloud Locations. This resource may be useful to create highly available infrastructure, distributed across several locations.
import pulumi import pulumi_hcloud as hcloud ds = hcloud.get_locations() workers = [] for range in [{"value": i} for i in range(0, 3)]: workers.append(hcloud.Server(f"workers-{range['value']}", image="debian-9", location=ds.names[range["value"]], server_type="cx31"))
pulumi_hcloud.get_network(id=None, ip_range=None, labels=None, name=None, with_selector=None, opts=None)¶Use this data source to access information about an existing resource.
pulumi_hcloud.get_server(id=None, name=None, selector=None, with_selector=None, with_statuses=None, opts=None)¶Use this data source to access information about an existing resource.
pulumi_hcloud.get_ssh_key(fingerprint=None, id=None, name=None, selector=None, with_selector=None, opts=None)¶Use this data source to access information about an existing resource.
pulumi_hcloud.get_ssh_keys(with_selector=None, opts=None)¶Use this data source to access information about an existing resource.
pulumi_hcloud.get_volume(id=None, location=None, name=None, selector=None, server=None, with_selector=None, with_statuses=None, opts=None)¶Use this data source to access information about an existing resource.