TargetSet
Provides a Spotinst Multai Target Set.
Example Usage
using Pulumi;
using SpotInst = Pulumi.SpotInst;
class MyStack : Stack
{
public MyStack()
{
var myTargetSet = new SpotInst.Multai.TargetSet("myTargetSet", new SpotInst.Multai.TargetSetArgs
{
BalancerId = "b-12345",
DeploymentId = "dp-12345",
HealthCheck = new SpotInst.Multai.Inputs.TargetSetHealthCheckArgs
{
HealthyThreshold = 3,
Interval = 20,
Path = "/",
Port = 3001,
Protocol = "http",
Timeout = 5,
UnhealthyThreshold = 3,
},
Port = 1338,
Protocol = "http",
Tags =
{
new SpotInst.Multai.Inputs.TargetSetTagArgs
{
Key = "env",
Value = "prod",
},
},
Weight = 2,
});
}
}
Coming soon!
import pulumi
import pulumi_spotinst as spotinst
my_target_set = spotinst.multai.TargetSet("myTargetSet",
balancer_id="b-12345",
deployment_id="dp-12345",
health_check={
"healthyThreshold": 3,
"interval": 20,
"path": "/",
"port": 3001,
"protocol": "http",
"timeout": 5,
"unhealthyThreshold": 3,
},
port=1338,
protocol="http",
tags=[{
"key": "env",
"value": "prod",
}],
weight=2)import * as pulumi from "@pulumi/pulumi";
import * as spotinst from "@pulumi/spotinst";
const myTargetSet = new spotinst.multai.TargetSet("my_target_set", {
balancerId: "b-12345",
deploymentId: "dp-12345",
healthCheck: {
healthyThreshold: 3,
interval: 20,
path: "/",
port: 3001,
protocol: "http",
timeout: 5,
unhealthyThreshold: 3,
},
port: 1338,
protocol: "http",
tags: [{
key: "env",
value: "prod",
}],
weight: 2,
});Create a TargetSet Resource
new TargetSet(name: string, args: TargetSetArgs, opts?: CustomResourceOptions);def TargetSet(resource_name, opts=None, balancer_id=None, deployment_id=None, health_check=None, name=None, port=None, protocol=None, tags=None, weight=None, __props__=None);func NewTargetSet(ctx *Context, name string, args TargetSetArgs, opts ...ResourceOption) (*TargetSet, error)public TargetSet(string name, TargetSetArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args TargetSetArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args TargetSetArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TargetSetArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
TargetSet Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The TargetSet resource accepts the following input properties:
- Balancer
Id string The id of the balancer.
- Deployment
Id string The id of the deployment.
- Health
Check Pulumi.Spot Inst. Multai. Inputs. Target Set Health Check Args - Protocol string
The protocol to allow connections to the target for the health check.
- Weight int
Defines how traffic is distributed between the Target Set.
- Name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port on which the load balancer is listening.
-
List<Pulumi.
Spot Inst. Multai. Inputs. Target Set Tag Args> A list of key:value paired tags.
- Balancer
Id string The id of the balancer.
- Deployment
Id string The id of the deployment.
- Health
Check TargetSet Health Check - Protocol string
The protocol to allow connections to the target for the health check.
- Weight int
Defines how traffic is distributed between the Target Set.
- Name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port on which the load balancer is listening.
-
[]Target
Set Tag A list of key:value paired tags.
- balancer
Id string The id of the balancer.
- deployment
Id string The id of the deployment.
- health
Check TargetSet Health Check - protocol string
The protocol to allow connections to the target for the health check.
- weight number
Defines how traffic is distributed between the Target Set.
- name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port number
The port on which the load balancer is listening.
-
Target
Set Tag[] A list of key:value paired tags.
- balancer_
id str The id of the balancer.
- deployment_
id str The id of the deployment.
- health_
check Dict[TargetSet Health Check] - protocol str
The protocol to allow connections to the target for the health check.
- weight float
Defines how traffic is distributed between the Target Set.
- name str
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port float
The port on which the load balancer is listening.
-
List[Target
Set Tag] A list of key:value paired tags.
Outputs
All input properties are implicitly available as output properties. Additionally, the TargetSet resource produces the following output properties:
Look up an Existing TargetSet Resource
Get an existing TargetSet 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?: TargetSetState, opts?: CustomResourceOptions): TargetSetstatic get(resource_name, id, opts=None, balancer_id=None, deployment_id=None, health_check=None, name=None, port=None, protocol=None, tags=None, weight=None, __props__=None);func GetTargetSet(ctx *Context, name string, id IDInput, state *TargetSetState, opts ...ResourceOption) (*TargetSet, error)public static TargetSet Get(string name, Input<string> id, TargetSetState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Balancer
Id string The id of the balancer.
- Deployment
Id string The id of the deployment.
- Health
Check Pulumi.Spot Inst. Multai. Inputs. Target Set Health Check Args - Name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port on which the load balancer is listening.
- Protocol string
The protocol to allow connections to the target for the health check.
-
List<Pulumi.
Spot Inst. Multai. Inputs. Target Set Tag Args> A list of key:value paired tags.
- Weight int
Defines how traffic is distributed between the Target Set.
- Balancer
Id string The id of the balancer.
- Deployment
Id string The id of the deployment.
- Health
Check TargetSet Health Check - Name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port on which the load balancer is listening.
- Protocol string
The protocol to allow connections to the target for the health check.
-
[]Target
Set Tag A list of key:value paired tags.
- Weight int
Defines how traffic is distributed between the Target Set.
- balancer
Id string The id of the balancer.
- deployment
Id string The id of the deployment.
- health
Check TargetSet Health Check - name string
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port number
The port on which the load balancer is listening.
- protocol string
The protocol to allow connections to the target for the health check.
-
Target
Set Tag[] A list of key:value paired tags.
- weight number
Defines how traffic is distributed between the Target Set.
- balancer_
id str The id of the balancer.
- deployment_
id str The id of the deployment.
- health_
check Dict[TargetSet Health Check] - name str
The name of the Target Set. Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port float
The port on which the load balancer is listening.
- protocol str
The protocol to allow connections to the target for the health check.
-
List[Target
Set Tag] A list of key:value paired tags.
- weight float
Defines how traffic is distributed between the Target Set.
Supporting Types
TargetSetHealthCheck
- Healthy
Threshold int Total number of allowed healthy Targets.
- Interval int
The interval for the health check.
- Path string
The path to perform the health check.
- Protocol string
The protocol to allow connections to the target for the health check.
- Timeout int
The time out for the health check.
- Unhealthy
Threshold int Total number of allowed unhealthy Targets.
- Port int
The port on which the load balancer is listening.
- Healthy
Threshold int Total number of allowed healthy Targets.
- Interval int
The interval for the health check.
- Path string
The path to perform the health check.
- Protocol string
The protocol to allow connections to the target for the health check.
- Timeout int
The time out for the health check.
- Unhealthy
Threshold int Total number of allowed unhealthy Targets.
- Port int
The port on which the load balancer is listening.
- healthy
Threshold number Total number of allowed healthy Targets.
- interval number
The interval for the health check.
- path string
The path to perform the health check.
- protocol string
The protocol to allow connections to the target for the health check.
- timeout number
The time out for the health check.
- unhealthy
Threshold number Total number of allowed unhealthy Targets.
- port number
The port on which the load balancer is listening.
- healthy
Threshold float Total number of allowed healthy Targets.
- interval float
The interval for the health check.
- path str
The path to perform the health check.
- protocol str
The protocol to allow connections to the target for the health check.
- timeout float
The time out for the health check.
- unhealthy
Threshold float Total number of allowed unhealthy Targets.
- port float
The port on which the load balancer is listening.
TargetSetTag
Package Details
- Repository
- https://github.com/pulumi/pulumi-spotinst
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
spotinstTerraform Provider.