OceanLaunchSpec

Provides a custom Spotinst Ocean ECS Launch Spec resource.

Example Usage

using Pulumi;
using SpotInst = Pulumi.SpotInst;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new SpotInst.Ecs.OceanLaunchSpec("example", new SpotInst.Ecs.OceanLaunchSpecArgs
        {
            Attributes = 
            {
                new SpotInst.Ecs.Inputs.OceanLaunchSpecAttributeArgs
                {
                    Key = "fakeKey",
                    Value = "fakeValue",
                },
            },
            AutoscaleHeadrooms = 
            {
                new SpotInst.Ecs.Inputs.OceanLaunchSpecAutoscaleHeadroomArgs
                {
                    CpuPerUnit = 1000,
                    MemoryPerUnit = 2048,
                    NumOfUnits = 5,
                },
            },
            IamInstanceProfile = "iam-profile",
            ImageId = "ami-123456",
            OceanId = "o-123456",
            SecurityGroupIds = 
            {
                "awseb-12345",
            },
            Tags = 
            {
                new SpotInst.Ecs.Inputs.OceanLaunchSpecTagArgs
                {
                    Key = "Env",
                    Value = "production",
                },
            },
            UserData = "echo hello world",
        });
    }

}

Coming soon!

import pulumi
import pulumi_spotinst as spotinst

example = spotinst.ecs.OceanLaunchSpec("example",
    attributes=[{
        "key": "fakeKey",
        "value": "fakeValue",
    }],
    autoscale_headrooms=[{
        "cpuPerUnit": 1000,
        "memoryPerUnit": 2048,
        "numOfUnits": 5,
    }],
    iam_instance_profile="iam-profile",
    image_id="ami-123456",
    ocean_id="o-123456",
    security_group_ids=["awseb-12345"],
    tags=[{
        "key": "Env",
        "value": "production",
    }],
    user_data="echo hello world")
import * as pulumi from "@pulumi/pulumi";
import * as spotinst from "@pulumi/spotinst";

const example = new spotinst.ecs.OceanLaunchSpec("example", {
    attributes: [{
        key: "fakeKey",
        value: "fakeValue",
    }],
    autoscaleHeadrooms: [{
        cpuPerUnit: 1000,
        memoryPerUnit: 2048,
        numOfUnits: 5,
    }],
    iamInstanceProfile: "iam-profile",
    imageId: "ami-123456",
    oceanId: "o-123456",
    securityGroupIds: ["awseb-12345"],
    tags: [{
        key: "Env",
        value: "production",
    }],
    userData: "echo hello world",
});

Create a OceanLaunchSpec Resource

def OceanLaunchSpec(resource_name, opts=None, attributes=None, autoscale_headrooms=None, iam_instance_profile=None, image_id=None, name=None, ocean_id=None, security_group_ids=None, tags=None, user_data=None, __props__=None);
name string
The unique name of the resource.
args OceanLaunchSpecArgs
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 OceanLaunchSpecArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args OceanLaunchSpecArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

OceanLaunchSpec Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The OceanLaunchSpec resource accepts the following input properties:

OceanId string

The Ocean cluster ID .

Attributes List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecAttributeArgs>

Optionally adds labels to instances launched in an Ocean cluster.

AutoscaleHeadrooms List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecAutoscaleHeadroomArgs>

Set custom headroom per launch spec. provide list of headrooms object.

IamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

ImageId string

ID of the image used to launch the instances.

Name string

The Ocean Launch Specification name.

SecurityGroupIds List<string>

One or more security group ids.

Tags List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecTagArgs>

A key/value mapping of tags to assign to the resource.

UserData string

Base64-encoded MIME user data to make available to the instances.

OceanId string

The Ocean cluster ID .

Attributes []OceanLaunchSpecAttribute

Optionally adds labels to instances launched in an Ocean cluster.

AutoscaleHeadrooms []OceanLaunchSpecAutoscaleHeadroom

Set custom headroom per launch spec. provide list of headrooms object.

IamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

ImageId string

ID of the image used to launch the instances.

Name string

The Ocean Launch Specification name.

SecurityGroupIds []string

One or more security group ids.

Tags []OceanLaunchSpecTag

A key/value mapping of tags to assign to the resource.

UserData string

Base64-encoded MIME user data to make available to the instances.

oceanId string

The Ocean cluster ID .

attributes OceanLaunchSpecAttribute[]

Optionally adds labels to instances launched in an Ocean cluster.

autoscaleHeadrooms OceanLaunchSpecAutoscaleHeadroom[]

Set custom headroom per launch spec. provide list of headrooms object.

iamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

imageId string

ID of the image used to launch the instances.

name string

The Ocean Launch Specification name.

securityGroupIds string[]

One or more security group ids.

tags OceanLaunchSpecTag[]

A key/value mapping of tags to assign to the resource.

userData string

Base64-encoded MIME user data to make available to the instances.

ocean_id str

The Ocean cluster ID .

attributes List[OceanLaunchSpecAttribute]

Optionally adds labels to instances launched in an Ocean cluster.

autoscale_headrooms List[OceanLaunchSpecAutoscaleHeadroom]

Set custom headroom per launch spec. provide list of headrooms object.

iam_instance_profile str

The ARN or name of an IAM instance profile to associate with launched instances.

image_id str

ID of the image used to launch the instances.

name str

The Ocean Launch Specification name.

security_group_ids List[str]

One or more security group ids.

tags List[OceanLaunchSpecTag]

A key/value mapping of tags to assign to the resource.

user_data str

Base64-encoded MIME user data to make available to the instances.

Outputs

All input properties are implicitly available as output properties. Additionally, the OceanLaunchSpec 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 str
The provider-assigned unique ID for this managed resource.

Look up an Existing OceanLaunchSpec Resource

Get an existing OceanLaunchSpec 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?: OceanLaunchSpecState, opts?: CustomResourceOptions): OceanLaunchSpec
static get(resource_name, id, opts=None, attributes=None, autoscale_headrooms=None, iam_instance_profile=None, image_id=None, name=None, ocean_id=None, security_group_ids=None, tags=None, user_data=None, __props__=None);
func GetOceanLaunchSpec(ctx *Context, name string, id IDInput, state *OceanLaunchSpecState, opts ...ResourceOption) (*OceanLaunchSpec, error)
public static OceanLaunchSpec Get(string name, Input<string> id, OceanLaunchSpecState? 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:

Attributes List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecAttributeArgs>

Optionally adds labels to instances launched in an Ocean cluster.

AutoscaleHeadrooms List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecAutoscaleHeadroomArgs>

Set custom headroom per launch spec. provide list of headrooms object.

IamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

ImageId string

ID of the image used to launch the instances.

Name string

The Ocean Launch Specification name.

OceanId string

The Ocean cluster ID .

SecurityGroupIds List<string>

One or more security group ids.

Tags List<Pulumi.SpotInst.Ecs.Inputs.OceanLaunchSpecTagArgs>

A key/value mapping of tags to assign to the resource.

UserData string

Base64-encoded MIME user data to make available to the instances.

Attributes []OceanLaunchSpecAttribute

Optionally adds labels to instances launched in an Ocean cluster.

AutoscaleHeadrooms []OceanLaunchSpecAutoscaleHeadroom

Set custom headroom per launch spec. provide list of headrooms object.

IamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

ImageId string

ID of the image used to launch the instances.

Name string

The Ocean Launch Specification name.

OceanId string

The Ocean cluster ID .

SecurityGroupIds []string

One or more security group ids.

Tags []OceanLaunchSpecTag

A key/value mapping of tags to assign to the resource.

UserData string

Base64-encoded MIME user data to make available to the instances.

attributes OceanLaunchSpecAttribute[]

Optionally adds labels to instances launched in an Ocean cluster.

autoscaleHeadrooms OceanLaunchSpecAutoscaleHeadroom[]

Set custom headroom per launch spec. provide list of headrooms object.

iamInstanceProfile string

The ARN or name of an IAM instance profile to associate with launched instances.

imageId string

ID of the image used to launch the instances.

name string

The Ocean Launch Specification name.

oceanId string

The Ocean cluster ID .

securityGroupIds string[]

One or more security group ids.

tags OceanLaunchSpecTag[]

A key/value mapping of tags to assign to the resource.

userData string

Base64-encoded MIME user data to make available to the instances.

attributes List[OceanLaunchSpecAttribute]

Optionally adds labels to instances launched in an Ocean cluster.

autoscale_headrooms List[OceanLaunchSpecAutoscaleHeadroom]

Set custom headroom per launch spec. provide list of headrooms object.

iam_instance_profile str

The ARN or name of an IAM instance profile to associate with launched instances.

image_id str

ID of the image used to launch the instances.

name str

The Ocean Launch Specification name.

ocean_id str

The Ocean cluster ID .

security_group_ids List[str]

One or more security group ids.

tags List[OceanLaunchSpecTag]

A key/value mapping of tags to assign to the resource.

user_data str

Base64-encoded MIME user data to make available to the instances.

Supporting Types

OceanLaunchSpecAttribute

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Key string

The label key.

Value string

The label value.

Key string

The label key.

Value string

The label value.

key string

The label key.

value string

The label value.

key str

The label key.

value str

The label value.

OceanLaunchSpecAutoscaleHeadroom

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

NumOfUnits int

The number of units to retain as headroom, where each unit has the defined headroom CPU and memory.

CpuPerUnit int

Optionally configure the number of CPUs to allocate for each headroom unit. CPUs are denoted in CPU units, where 1024 units = 1 vCPU.

MemoryPerUnit int

Optionally configure the amount of memory (MiB) to allocate for each headroom unit.

NumOfUnits int

The number of units to retain as headroom, where each unit has the defined headroom CPU and memory.

CpuPerUnit int

Optionally configure the number of CPUs to allocate for each headroom unit. CPUs are denoted in CPU units, where 1024 units = 1 vCPU.

MemoryPerUnit int

Optionally configure the amount of memory (MiB) to allocate for each headroom unit.

numOfUnits number

The number of units to retain as headroom, where each unit has the defined headroom CPU and memory.

cpuPerUnit number

Optionally configure the number of CPUs to allocate for each headroom unit. CPUs are denoted in CPU units, where 1024 units = 1 vCPU.

memoryPerUnit number

Optionally configure the amount of memory (MiB) to allocate for each headroom unit.

numOfUnits float

The number of units to retain as headroom, where each unit has the defined headroom CPU and memory.

cpuPerUnit float

Optionally configure the number of CPUs to allocate for each headroom unit. CPUs are denoted in CPU units, where 1024 units = 1 vCPU.

memoryPerUnit float

Optionally configure the amount of memory (MiB) to allocate for each headroom unit.

OceanLaunchSpecTag

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Key string

The label key.

Value string

The label value.

Key string

The label key.

Value string

The label value.

key string

The label key.

value string

The label value.

key str

The label key.

value str

The label value.

Package Details

Repository
https://github.com/pulumi/pulumi-spotinst
License
Apache-2.0
Notes
This Pulumi package is based on the spotinst Terraform Provider.