Target
Provides a Spotinst Multai Target.
Example Usage
using Pulumi;
using SpotInst = Pulumi.SpotInst;
class MyStack : Stack
{
public MyStack()
{
var myTarget = new SpotInst.Multai.Target("myTarget", new SpotInst.Multai.TargetArgs
{
BalancerId = "b-12345",
Host = "host",
Port = 1338,
Tags =
{
new SpotInst.Multai.Inputs.TargetTagArgs
{
Key = "env",
Value = "prod",
},
},
TargetSetId = "l-98765",
Weight = 1,
});
}
}
Coming soon!
import pulumi
import pulumi_spotinst as spotinst
my_target = spotinst.multai.Target("myTarget",
balancer_id="b-12345",
host="host",
port=1338,
tags=[{
"key": "env",
"value": "prod",
}],
target_set_id="l-98765",
weight=1)import * as pulumi from "@pulumi/pulumi";
import * as spotinst from "@pulumi/spotinst";
const myTarget = new spotinst.multai.Target("my_target", {
balancerId: "b-12345",
host: "host",
port: 1338,
tags: [{
key: "env",
value: "prod",
}],
targetSetId: "l-98765",
weight: 1,
});Create a Target Resource
new Target(name: string, args: TargetArgs, opts?: CustomResourceOptions);def Target(resource_name, opts=None, balancer_id=None, host=None, name=None, port=None, tags=None, target_set_id=None, weight=None, __props__=None);func NewTarget(ctx *Context, name string, args TargetArgs, opts ...ResourceOption) (*Target, error)public Target(string name, TargetArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args TargetArgs
- 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 TargetArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TargetArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
Target Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The Target resource accepts the following input properties:
- Balancer
Id string The ID of the balancer.
- Host string
The address (IP or URL) of the targets to register
- Target
Set stringId The ID of the target set.
- Weight int
Defines how traffic is distributed between targets.
- Name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port the target will register to.
-
List<Pulumi.
Spot Inst. Multai. Inputs. Target Tag Args> A list of key:value paired tags.
- Balancer
Id string The ID of the balancer.
- Host string
The address (IP or URL) of the targets to register
- Target
Set stringId The ID of the target set.
- Weight int
Defines how traffic is distributed between targets.
- Name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port the target will register to.
-
[]Target
Tag A list of key:value paired tags.
- balancer
Id string The ID of the balancer.
- host string
The address (IP or URL) of the targets to register
- target
Set stringId The ID of the target set.
- weight number
Defines how traffic is distributed between targets.
- name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port number
The port the target will register to.
-
Target
Tag[] A list of key:value paired tags.
- balancer_
id str The ID of the balancer.
- host str
The address (IP or URL) of the targets to register
- target_
set_ strid The ID of the target set.
- weight float
Defines how traffic is distributed between targets.
- name str
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port float
The port the target will register to.
-
List[Target
Tag] A list of key:value paired tags.
Outputs
All input properties are implicitly available as output properties. Additionally, the Target resource produces the following output properties:
Look up an Existing Target Resource
Get an existing Target 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?: TargetState, opts?: CustomResourceOptions): Targetstatic get(resource_name, id, opts=None, balancer_id=None, host=None, name=None, port=None, tags=None, target_set_id=None, weight=None, __props__=None);func GetTarget(ctx *Context, name string, id IDInput, state *TargetState, opts ...ResourceOption) (*Target, error)public static Target Get(string name, Input<string> id, TargetState? 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.
- Host string
The address (IP or URL) of the targets to register
- Name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port the target will register to.
-
List<Pulumi.
Spot Inst. Multai. Inputs. Target Tag Args> A list of key:value paired tags.
- Target
Set stringId The ID of the target set.
- Weight int
Defines how traffic is distributed between targets.
- Balancer
Id string The ID of the balancer.
- Host string
The address (IP or URL) of the targets to register
- Name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- Port int
The port the target will register to.
-
[]Target
Tag A list of key:value paired tags.
- Target
Set stringId The ID of the target set.
- Weight int
Defines how traffic is distributed between targets.
- balancer
Id string The ID of the balancer.
- host string
The address (IP or URL) of the targets to register
- name string
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port number
The port the target will register to.
-
Target
Tag[] A list of key:value paired tags.
- target
Set stringId The ID of the target set.
- weight number
Defines how traffic is distributed between targets.
- balancer_
id str The ID of the balancer.
- host str
The address (IP or URL) of the targets to register
- name str
The name of the Target . Must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
- port float
The port the target will register to.
-
List[Target
Tag] A list of key:value paired tags.
- target_
set_ strid The ID of the target set.
- weight float
Defines how traffic is distributed between targets.
Supporting Types
TargetTag
Package Details
- Repository
- https://github.com/pulumi/pulumi-spotinst
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
spotinstTerraform Provider.