hcloud.LoadBalancerService
Explore with Pulumi AI
Define services for Hetzner Cloud Load Balancers.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as hcloud from "@pulumi/hcloud";
const loadBalancer = new hcloud.LoadBalancer("load_balancer", {
name: "my-load-balancer",
loadBalancerType: "lb11",
location: "nbg1",
});
const loadBalancerService = new hcloud.LoadBalancerService("load_balancer_service", {
loadBalancerId: loadBalancer.id,
protocol: "http",
http: {
stickySessions: true,
cookieName: "EXAMPLE_STICKY",
},
healthCheck: {
protocol: "http",
port: 80,
interval: 10,
timeout: 5,
http: {
domain: "example.com",
path: "/healthz",
response: "OK",
tls: true,
statusCodes: ["200"],
},
},
});
import pulumi
import pulumi_hcloud as hcloud
load_balancer = hcloud.LoadBalancer("load_balancer",
name="my-load-balancer",
load_balancer_type="lb11",
location="nbg1")
load_balancer_service = hcloud.LoadBalancerService("load_balancer_service",
load_balancer_id=load_balancer.id,
protocol="http",
http={
"sticky_sessions": True,
"cookie_name": "EXAMPLE_STICKY",
},
health_check={
"protocol": "http",
"port": 80,
"interval": 10,
"timeout": 5,
"http": {
"domain": "example.com",
"path": "/healthz",
"response": "OK",
"tls": True,
"status_codes": ["200"],
},
})
package main
import (
"github.com/pulumi/pulumi-hcloud/sdk/go/hcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
loadBalancer, err := hcloud.NewLoadBalancer(ctx, "load_balancer", &hcloud.LoadBalancerArgs{
Name: pulumi.String("my-load-balancer"),
LoadBalancerType: pulumi.String("lb11"),
Location: pulumi.String("nbg1"),
})
if err != nil {
return err
}
_, err = hcloud.NewLoadBalancerService(ctx, "load_balancer_service", &hcloud.LoadBalancerServiceArgs{
LoadBalancerId: loadBalancer.ID(),
Protocol: pulumi.String("http"),
Http: &hcloud.LoadBalancerServiceHttpArgs{
StickySessions: pulumi.Bool(true),
CookieName: pulumi.String("EXAMPLE_STICKY"),
},
HealthCheck: &hcloud.LoadBalancerServiceHealthCheckArgs{
Protocol: pulumi.String("http"),
Port: pulumi.Int(80),
Interval: pulumi.Int(10),
Timeout: pulumi.Int(5),
Http: &hcloud.LoadBalancerServiceHealthCheckHttpArgs{
Domain: pulumi.String("example.com"),
Path: pulumi.String("/healthz"),
Response: pulumi.String("OK"),
Tls: pulumi.Bool(true),
StatusCodes: pulumi.StringArray{
pulumi.String("200"),
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using HCloud = Pulumi.HCloud;
return await Deployment.RunAsync(() =>
{
var loadBalancer = new HCloud.LoadBalancer("load_balancer", new()
{
Name = "my-load-balancer",
LoadBalancerType = "lb11",
Location = "nbg1",
});
var loadBalancerService = new HCloud.LoadBalancerService("load_balancer_service", new()
{
LoadBalancerId = loadBalancer.Id,
Protocol = "http",
Http = new HCloud.Inputs.LoadBalancerServiceHttpArgs
{
StickySessions = true,
CookieName = "EXAMPLE_STICKY",
},
HealthCheck = new HCloud.Inputs.LoadBalancerServiceHealthCheckArgs
{
Protocol = "http",
Port = 80,
Interval = 10,
Timeout = 5,
Http = new HCloud.Inputs.LoadBalancerServiceHealthCheckHttpArgs
{
Domain = "example.com",
Path = "/healthz",
Response = "OK",
Tls = true,
StatusCodes = new[]
{
"200",
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.hcloud.LoadBalancer;
import com.pulumi.hcloud.LoadBalancerArgs;
import com.pulumi.hcloud.LoadBalancerService;
import com.pulumi.hcloud.LoadBalancerServiceArgs;
import com.pulumi.hcloud.inputs.LoadBalancerServiceHttpArgs;
import com.pulumi.hcloud.inputs.LoadBalancerServiceHealthCheckArgs;
import com.pulumi.hcloud.inputs.LoadBalancerServiceHealthCheckHttpArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var loadBalancer = new LoadBalancer("loadBalancer", LoadBalancerArgs.builder()
.name("my-load-balancer")
.loadBalancerType("lb11")
.location("nbg1")
.build());
var loadBalancerService = new LoadBalancerService("loadBalancerService", LoadBalancerServiceArgs.builder()
.loadBalancerId(loadBalancer.id())
.protocol("http")
.http(LoadBalancerServiceHttpArgs.builder()
.stickySessions(true)
.cookieName("EXAMPLE_STICKY")
.build())
.healthCheck(LoadBalancerServiceHealthCheckArgs.builder()
.protocol("http")
.port(80)
.interval(10)
.timeout(5)
.http(LoadBalancerServiceHealthCheckHttpArgs.builder()
.domain("example.com")
.path("/healthz")
.response("OK")
.tls(true)
.statusCodes("200")
.build())
.build())
.build());
}
}
resources:
loadBalancer:
type: hcloud:LoadBalancer
name: load_balancer
properties:
name: my-load-balancer
loadBalancerType: lb11
location: nbg1
loadBalancerService:
type: hcloud:LoadBalancerService
name: load_balancer_service
properties:
loadBalancerId: ${loadBalancer.id}
protocol: http
http:
stickySessions: true
cookieName: EXAMPLE_STICKY
healthCheck:
protocol: http
port: 80
interval: 10
timeout: 5
http:
domain: example.com
path: /healthz
response: OK
tls: true
statusCodes:
- '200'
Create LoadBalancerService Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new LoadBalancerService(name: string, args: LoadBalancerServiceArgs, opts?: CustomResourceOptions);
@overload
def LoadBalancerService(resource_name: str,
args: LoadBalancerServiceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def LoadBalancerService(resource_name: str,
opts: Optional[ResourceOptions] = None,
load_balancer_id: Optional[str] = None,
protocol: Optional[str] = None,
destination_port: Optional[int] = None,
health_check: Optional[LoadBalancerServiceHealthCheckArgs] = None,
http: Optional[LoadBalancerServiceHttpArgs] = None,
listen_port: Optional[int] = None,
proxyprotocol: Optional[bool] = None)
func NewLoadBalancerService(ctx *Context, name string, args LoadBalancerServiceArgs, opts ...ResourceOption) (*LoadBalancerService, error)
public LoadBalancerService(string name, LoadBalancerServiceArgs args, CustomResourceOptions? opts = null)
public LoadBalancerService(String name, LoadBalancerServiceArgs args)
public LoadBalancerService(String name, LoadBalancerServiceArgs args, CustomResourceOptions options)
type: hcloud:LoadBalancerService
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args LoadBalancerServiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args LoadBalancerServiceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args LoadBalancerServiceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args LoadBalancerServiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args LoadBalancerServiceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var loadBalancerServiceResource = new HCloud.LoadBalancerService("loadBalancerServiceResource", new()
{
LoadBalancerId = "string",
Protocol = "string",
DestinationPort = 0,
HealthCheck = new HCloud.Inputs.LoadBalancerServiceHealthCheckArgs
{
Interval = 0,
Port = 0,
Protocol = "string",
Timeout = 0,
Http = new HCloud.Inputs.LoadBalancerServiceHealthCheckHttpArgs
{
Domain = "string",
Path = "string",
Response = "string",
StatusCodes = new[]
{
"string",
},
Tls = false,
},
Retries = 0,
},
Http = new HCloud.Inputs.LoadBalancerServiceHttpArgs
{
Certificates = new[]
{
0,
},
CookieLifetime = 0,
CookieName = "string",
RedirectHttp = false,
StickySessions = false,
},
ListenPort = 0,
Proxyprotocol = false,
});
example, err := hcloud.NewLoadBalancerService(ctx, "loadBalancerServiceResource", &hcloud.LoadBalancerServiceArgs{
LoadBalancerId: pulumi.String("string"),
Protocol: pulumi.String("string"),
DestinationPort: pulumi.Int(0),
HealthCheck: &hcloud.LoadBalancerServiceHealthCheckArgs{
Interval: pulumi.Int(0),
Port: pulumi.Int(0),
Protocol: pulumi.String("string"),
Timeout: pulumi.Int(0),
Http: &hcloud.LoadBalancerServiceHealthCheckHttpArgs{
Domain: pulumi.String("string"),
Path: pulumi.String("string"),
Response: pulumi.String("string"),
StatusCodes: pulumi.StringArray{
pulumi.String("string"),
},
Tls: pulumi.Bool(false),
},
Retries: pulumi.Int(0),
},
Http: &hcloud.LoadBalancerServiceHttpArgs{
Certificates: pulumi.IntArray{
pulumi.Int(0),
},
CookieLifetime: pulumi.Int(0),
CookieName: pulumi.String("string"),
RedirectHttp: pulumi.Bool(false),
StickySessions: pulumi.Bool(false),
},
ListenPort: pulumi.Int(0),
Proxyprotocol: pulumi.Bool(false),
})
var loadBalancerServiceResource = new LoadBalancerService("loadBalancerServiceResource", LoadBalancerServiceArgs.builder()
.loadBalancerId("string")
.protocol("string")
.destinationPort(0)
.healthCheck(LoadBalancerServiceHealthCheckArgs.builder()
.interval(0)
.port(0)
.protocol("string")
.timeout(0)
.http(LoadBalancerServiceHealthCheckHttpArgs.builder()
.domain("string")
.path("string")
.response("string")
.statusCodes("string")
.tls(false)
.build())
.retries(0)
.build())
.http(LoadBalancerServiceHttpArgs.builder()
.certificates(0)
.cookieLifetime(0)
.cookieName("string")
.redirectHttp(false)
.stickySessions(false)
.build())
.listenPort(0)
.proxyprotocol(false)
.build());
load_balancer_service_resource = hcloud.LoadBalancerService("loadBalancerServiceResource",
load_balancer_id="string",
protocol="string",
destination_port=0,
health_check={
"interval": 0,
"port": 0,
"protocol": "string",
"timeout": 0,
"http": {
"domain": "string",
"path": "string",
"response": "string",
"status_codes": ["string"],
"tls": False,
},
"retries": 0,
},
http={
"certificates": [0],
"cookie_lifetime": 0,
"cookie_name": "string",
"redirect_http": False,
"sticky_sessions": False,
},
listen_port=0,
proxyprotocol=False)
const loadBalancerServiceResource = new hcloud.LoadBalancerService("loadBalancerServiceResource", {
loadBalancerId: "string",
protocol: "string",
destinationPort: 0,
healthCheck: {
interval: 0,
port: 0,
protocol: "string",
timeout: 0,
http: {
domain: "string",
path: "string",
response: "string",
statusCodes: ["string"],
tls: false,
},
retries: 0,
},
http: {
certificates: [0],
cookieLifetime: 0,
cookieName: "string",
redirectHttp: false,
stickySessions: false,
},
listenPort: 0,
proxyprotocol: false,
});
type: hcloud:LoadBalancerService
properties:
destinationPort: 0
healthCheck:
http:
domain: string
path: string
response: string
statusCodes:
- string
tls: false
interval: 0
port: 0
protocol: string
retries: 0
timeout: 0
http:
certificates:
- 0
cookieLifetime: 0
cookieName: string
redirectHttp: false
stickySessions: false
listenPort: 0
loadBalancerId: string
protocol: string
proxyprotocol: false
LoadBalancerService Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The LoadBalancerService resource accepts the following input properties:
- Load
Balancer stringId - Id of the load balancer this service belongs to.
- Protocol string
- Protocol of the service.
http
,https
ortcp
- Destination
Port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - Health
Check Pulumi.HCloud. Inputs. Load Balancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - Http
Pulumi.
HCloud. Inputs. Load Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - Listen
Port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Proxyprotocol bool
- Enable proxyprotocol.
- Load
Balancer stringId - Id of the load balancer this service belongs to.
- Protocol string
- Protocol of the service.
http
,https
ortcp
- Destination
Port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - Health
Check LoadBalancer Service Health Check Args - Health Check configuration when
protocol
ishttp
orhttps
. - Http
Load
Balancer Service Http Args - HTTP configuration when
protocol
ishttp
orhttps
. - Listen
Port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Proxyprotocol bool
- Enable proxyprotocol.
- load
Balancer StringId - Id of the load balancer this service belongs to.
- protocol String
- Protocol of the service.
http
,https
ortcp
- destination
Port Integer - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check LoadBalancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port Integer - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - proxyprotocol Boolean
- Enable proxyprotocol.
- load
Balancer stringId - Id of the load balancer this service belongs to.
- protocol string
- Protocol of the service.
http
,https
ortcp
- destination
Port number - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check LoadBalancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port number - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - proxyprotocol boolean
- Enable proxyprotocol.
- load_
balancer_ strid - Id of the load balancer this service belongs to.
- protocol str
- Protocol of the service.
http
,https
ortcp
- destination_
port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health_
check LoadBalancer Service Health Check Args - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http Args - HTTP configuration when
protocol
ishttp
orhttps
. - listen_
port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - proxyprotocol bool
- Enable proxyprotocol.
- load
Balancer StringId - Id of the load balancer this service belongs to.
- protocol String
- Protocol of the service.
http
,https
ortcp
- destination
Port Number - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check Property Map - Health Check configuration when
protocol
ishttp
orhttps
. - http Property Map
- HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port Number - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - proxyprotocol Boolean
- Enable proxyprotocol.
Outputs
All input properties are implicitly available as output properties. Additionally, the LoadBalancerService resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing LoadBalancerService Resource
Get an existing LoadBalancerService resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: LoadBalancerServiceState, opts?: CustomResourceOptions): LoadBalancerService
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
destination_port: Optional[int] = None,
health_check: Optional[LoadBalancerServiceHealthCheckArgs] = None,
http: Optional[LoadBalancerServiceHttpArgs] = None,
listen_port: Optional[int] = None,
load_balancer_id: Optional[str] = None,
protocol: Optional[str] = None,
proxyprotocol: Optional[bool] = None) -> LoadBalancerService
func GetLoadBalancerService(ctx *Context, name string, id IDInput, state *LoadBalancerServiceState, opts ...ResourceOption) (*LoadBalancerService, error)
public static LoadBalancerService Get(string name, Input<string> id, LoadBalancerServiceState? state, CustomResourceOptions? opts = null)
public static LoadBalancerService get(String name, Output<String> id, LoadBalancerServiceState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Destination
Port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - Health
Check Pulumi.HCloud. Inputs. Load Balancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - Http
Pulumi.
HCloud. Inputs. Load Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - Listen
Port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Load
Balancer stringId - Id of the load balancer this service belongs to.
- Protocol string
- Protocol of the service.
http
,https
ortcp
- Proxyprotocol bool
- Enable proxyprotocol.
- Destination
Port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - Health
Check LoadBalancer Service Health Check Args - Health Check configuration when
protocol
ishttp
orhttps
. - Http
Load
Balancer Service Http Args - HTTP configuration when
protocol
ishttp
orhttps
. - Listen
Port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Load
Balancer stringId - Id of the load balancer this service belongs to.
- Protocol string
- Protocol of the service.
http
,https
ortcp
- Proxyprotocol bool
- Enable proxyprotocol.
- destination
Port Integer - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check LoadBalancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port Integer - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - load
Balancer StringId - Id of the load balancer this service belongs to.
- protocol String
- Protocol of the service.
http
,https
ortcp
- proxyprotocol Boolean
- Enable proxyprotocol.
- destination
Port number - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check LoadBalancer Service Health Check - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http - HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port number - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - load
Balancer stringId - Id of the load balancer this service belongs to.
- protocol string
- Protocol of the service.
http
,https
ortcp
- proxyprotocol boolean
- Enable proxyprotocol.
- destination_
port int - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health_
check LoadBalancer Service Health Check Args - Health Check configuration when
protocol
ishttp
orhttps
. - http
Load
Balancer Service Http Args - HTTP configuration when
protocol
ishttp
orhttps
. - listen_
port int - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - load_
balancer_ strid - Id of the load balancer this service belongs to.
- protocol str
- Protocol of the service.
http
,https
ortcp
- proxyprotocol bool
- Enable proxyprotocol.
- destination
Port Number - Port the service connects to the targets on, required if protocol is
tcp
. Can be everything between1
and65535
. - health
Check Property Map - Health Check configuration when
protocol
ishttp
orhttps
. - http Property Map
- HTTP configuration when
protocol
ishttp
orhttps
. - listen
Port Number - Port the service listen on, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - load
Balancer StringId - Id of the load balancer this service belongs to.
- protocol String
- Protocol of the service.
http
,https
ortcp
- proxyprotocol Boolean
- Enable proxyprotocol.
Supporting Types
LoadBalancerServiceHealthCheck, LoadBalancerServiceHealthCheckArgs
- Interval int
- Interval how often the health check will be performed, in seconds.
- Port int
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Protocol string
- Protocol the health check uses.
http
ortcp
- Timeout int
- Timeout when a health check try will be canceled if there is no response, in seconds.
- Http
Pulumi.
HCloud. Inputs. Load Balancer Service Health Check Http - HTTP configuration. Required if
protocol
ishttp
. - Retries int
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
- Interval int
- Interval how often the health check will be performed, in seconds.
- Port int
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - Protocol string
- Protocol the health check uses.
http
ortcp
- Timeout int
- Timeout when a health check try will be canceled if there is no response, in seconds.
- Http
Load
Balancer Service Health Check Http - HTTP configuration. Required if
protocol
ishttp
. - Retries int
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
- interval Integer
- Interval how often the health check will be performed, in seconds.
- port Integer
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - protocol String
- Protocol the health check uses.
http
ortcp
- timeout Integer
- Timeout when a health check try will be canceled if there is no response, in seconds.
- http
Load
Balancer Service Health Check Http - HTTP configuration. Required if
protocol
ishttp
. - retries Integer
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
- interval number
- Interval how often the health check will be performed, in seconds.
- port number
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - protocol string
- Protocol the health check uses.
http
ortcp
- timeout number
- Timeout when a health check try will be canceled if there is no response, in seconds.
- http
Load
Balancer Service Health Check Http - HTTP configuration. Required if
protocol
ishttp
. - retries number
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
- interval int
- Interval how often the health check will be performed, in seconds.
- port int
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - protocol str
- Protocol the health check uses.
http
ortcp
- timeout int
- Timeout when a health check try will be canceled if there is no response, in seconds.
- http
Load
Balancer Service Health Check Http - HTTP configuration. Required if
protocol
ishttp
. - retries int
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
- interval Number
- Interval how often the health check will be performed, in seconds.
- port Number
- Port the health check tries to connect to, required if protocol is
tcp
. Can be everything between1
and65535
. Must be unique per Load Balancer. - protocol String
- Protocol the health check uses.
http
ortcp
- timeout Number
- Timeout when a health check try will be canceled if there is no response, in seconds.
- http Property Map
- HTTP configuration. Required if
protocol
ishttp
. - retries Number
- Number of tries a health check will be performed until a target will be listed as
unhealthy
.
LoadBalancerServiceHealthCheckHttp, LoadBalancerServiceHealthCheckHttpArgs
- Domain string
- Domain we try to access when performing the Health Check.
- Path string
- Path we try to access when performing the Health Check.
- Response string
- Response we expect to be included in the Target response when a Health Check was performed.
- Status
Codes List<string> - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - Tls bool
- Enable TLS certificate checking.
- Domain string
- Domain we try to access when performing the Health Check.
- Path string
- Path we try to access when performing the Health Check.
- Response string
- Response we expect to be included in the Target response when a Health Check was performed.
- Status
Codes []string - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - Tls bool
- Enable TLS certificate checking.
- domain String
- Domain we try to access when performing the Health Check.
- path String
- Path we try to access when performing the Health Check.
- response String
- Response we expect to be included in the Target response when a Health Check was performed.
- status
Codes List<String> - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - tls Boolean
- Enable TLS certificate checking.
- domain string
- Domain we try to access when performing the Health Check.
- path string
- Path we try to access when performing the Health Check.
- response string
- Response we expect to be included in the Target response when a Health Check was performed.
- status
Codes string[] - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - tls boolean
- Enable TLS certificate checking.
- domain str
- Domain we try to access when performing the Health Check.
- path str
- Path we try to access when performing the Health Check.
- response str
- Response we expect to be included in the Target response when a Health Check was performed.
- status_
codes Sequence[str] - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - tls bool
- Enable TLS certificate checking.
- domain String
- Domain we try to access when performing the Health Check.
- path String
- Path we try to access when performing the Health Check.
- response String
- Response we expect to be included in the Target response when a Health Check was performed.
- status
Codes List<String> - We expect that the target answers with these status codes. If not the target is marked as
unhealthy
. - tls Boolean
- Enable TLS certificate checking.
LoadBalancerServiceHttp, LoadBalancerServiceHttpArgs
- Certificates List<int>
- List of IDs from certificates which the Load Balancer has.
- int
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- string
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- Redirect
Http bool - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - Sticky
Sessions bool - Enable sticky sessions
- Certificates []int
- List of IDs from certificates which the Load Balancer has.
- int
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- string
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- Redirect
Http bool - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - Sticky
Sessions bool - Enable sticky sessions
- certificates List<Integer>
- List of IDs from certificates which the Load Balancer has.
- Integer
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- String
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- redirect
Http Boolean - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - sticky
Sessions Boolean - Enable sticky sessions
- certificates number[]
- List of IDs from certificates which the Load Balancer has.
- number
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- string
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- redirect
Http boolean - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - sticky
Sessions boolean - Enable sticky sessions
- certificates Sequence[int]
- List of IDs from certificates which the Load Balancer has.
- int
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- str
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- redirect_
http bool - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - sticky_
sessions bool - Enable sticky sessions
- certificates List<Number>
- List of IDs from certificates which the Load Balancer has.
- Number
- Lifetime of the cookie for sticky session (in seconds). Default:
300
- String
- Name of the cookie for sticky session. Default:
HCLBSTICKY
- redirect
Http Boolean - Redirect HTTP to HTTPS traffic. Only supported for services with
protocol
https
using the default HTTP port80
. - sticky
Sessions Boolean - Enable sticky sessions
Import
Load Balancer Service entries can be imported using a compound ID with the following format:
<load-balancer-id>__<listen-port>
$ pulumi import hcloud:index/loadBalancerService:LoadBalancerService myloadbalancernetwork 123__80
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Hetzner Cloud pulumi/pulumi-hcloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
hcloud
Terraform Provider.