From 21923be23bcd4ea60624c9c3a8bb877ddba30b22 Mon Sep 17 00:00:00 2001 From: stack72 Date: Tue, 4 May 2021 18:34:05 +0100 Subject: [PATCH] Upgrade to v1.43.0 of the SpotInst Terraform Provider --- CHANGELOG.md | 2 +- Makefile | 3 + examples/aws_elastigroup/csharp/csharp.csproj | 2 +- .../aws_elastigroup/python/requirements.txt | 4 +- examples/aws_elastigroup/ts/package.json | 6 +- .../cmd/pulumi-resource-spotinst/schema.json | 28 +++- provider/go.mod | 2 +- provider/go.sum | 4 + .../OceanLaunchSpecCreateOptionsArgs.cs | 25 ++++ .../OceanLaunchSpecCreateOptionsGetArgs.cs | 25 ++++ sdk/dotnet/Aws/OceanLaunchSpec.cs | 13 ++ .../Outputs/OceanLaunchSpecCreateOptions.cs | 27 ++++ sdk/go/spotinst/aws/oceanLaunchSpec.go | 8 ++ sdk/go/spotinst/aws/pulumiTypes.go | 133 ++++++++++++++++++ sdk/nodejs/aws/oceanLaunchSpec.ts | 8 ++ sdk/nodejs/types/input.ts | 7 + sdk/nodejs/types/output.ts | 7 + sdk/python/pulumi_spotinst/aws/_inputs.py | 23 +++ .../pulumi_spotinst/aws/ocean_launch_spec.py | 40 ++++++ sdk/python/pulumi_spotinst/aws/outputs.py | 36 +++++ 20 files changed, 394 insertions(+), 9 deletions(-) create mode 100644 sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsArgs.cs create mode 100644 sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsGetArgs.cs create mode 100644 sdk/dotnet/Aws/Outputs/OceanLaunchSpecCreateOptions.cs diff --git a/CHANGELOG.md b/CHANGELOG.md index 7ef43adb..94516199 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ CHANGELOG ========= ## HEAD (Unreleased) -_(none)_ +* Upgrade to v1.43.0 of the SpotInst Terraform Provider --- diff --git a/Makefile b/Makefile index f4d438de..89e3f527 100644 --- a/Makefile +++ b/Makefile @@ -82,6 +82,9 @@ clean:: install_plugins:: [ -x $(shell which pulumi) ] || curl -fsSL https://get.pulumi.com | sh + pulumi plugin install resource aws 4.1.0 + pulumi plugin install resource azure 4.1.0 + pulumi plugin install resource random 4.0.0 install_dotnet_sdk:: mkdir -p $(WORKING_DIR)/nuget diff --git a/examples/aws_elastigroup/csharp/csharp.csproj b/examples/aws_elastigroup/csharp/csharp.csproj index 92f8e9d6..bd86effb 100644 --- a/examples/aws_elastigroup/csharp/csharp.csproj +++ b/examples/aws_elastigroup/csharp/csharp.csproj @@ -7,7 +7,7 @@ - + diff --git a/examples/aws_elastigroup/python/requirements.txt b/examples/aws_elastigroup/python/requirements.txt index 583615cf..ea1e69a6 100644 --- a/examples/aws_elastigroup/python/requirements.txt +++ b/examples/aws_elastigroup/python/requirements.txt @@ -1,2 +1,2 @@ -pulumi>=3.0.0a1,<4.0.0 -pulumi_aws>=4.0.0a1,<5.0.0 +pulumi>=3.0.0,<4.0.0 +pulumi_aws>=4.0.0,<5.0.0 diff --git a/examples/aws_elastigroup/ts/package.json b/examples/aws_elastigroup/ts/package.json index d8122daf..b4dc62af 100644 --- a/examples/aws_elastigroup/ts/package.json +++ b/examples/aws_elastigroup/ts/package.json @@ -4,8 +4,8 @@ "@types/node": "^8.0.0" }, "dependencies": { - "@pulumi/aws": "^4.0.0-alpha.0", - "@pulumi/pulumi": "^3.0.0-alpha.0", - "@pulumi/random": "^4.0.0-alpha.0" + "@pulumi/aws": "^4.0.0", + "@pulumi/pulumi": "^3.0.0", + "@pulumi/random": "^4.0.0" } } diff --git a/provider/cmd/pulumi-resource-spotinst/schema.json b/provider/cmd/pulumi-resource-spotinst/schema.json index aff6f01e..f884152f 100644 --- a/provider/cmd/pulumi-resource-spotinst/schema.json +++ b/provider/cmd/pulumi-resource-spotinst/schema.json @@ -4794,6 +4794,23 @@ "sizePerResourceUnit" ] }, + "spotinst:aws/OceanLaunchSpecCreateOptions:OceanLaunchSpecCreateOptions": { + "properties": { + "initialNodes": { + "type": "integer", + "description": "When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group.\n", + "language": { + "python": { + "mapCase": false + } + } + } + }, + "type": "object", + "required": [ + "initialNodes" + ] + }, "spotinst:aws/OceanLaunchSpecElasticIpPool:OceanLaunchSpecElasticIpPool": { "properties": { "tagSelector": { @@ -13373,7 +13390,7 @@ } }, "spotinst:aws/oceanLaunchSpec:OceanLaunchSpec": { - "description": "Manages a Spotinst Ocean AWS [Virtual Node Group](https://docs.spot.io/ocean/features/launch-specifications) resource.\n\n{{% examples %}}\n## Example Usage\n{{% example %}}\n\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as spotinst from \"@pulumi/spotinst\";\n\nconst example = new spotinst.aws.OceanLaunchSpec(\"example\", {\n associatePublicIpAddress: true,\n autoscaleHeadrooms: [{\n cpuPerNit: 1000,\n gpuPerUnit: 0,\n memoryPerUnit: 2048,\n numOfUnits: 5,\n }],\n blockDeviceMappings: [{\n deviceName: \"/dev/xvda1\",\n ebs: {\n deleteOnTermination: true,\n dynamicVolumeSize: {\n baseSize: 50,\n resource: \"CPU\",\n sizePerResourceUnit: 20,\n },\n encrypted: false,\n throughput: 500,\n volumeSize: 50,\n volumeType: \"gp2\",\n },\n }],\n elasticIpPools: [{\n tagSelector: {\n tagKey: \"key\",\n tagValue: \"value\",\n },\n }],\n iamInstanceProfile: \"iam-profile\",\n imageId: \"ami-123456\",\n instanceTypes: [\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n ],\n labels: [{\n key: \"key1\",\n value: \"value1\",\n }],\n oceanId: \"o-123456\",\n resourceLimits: [{\n maxInstanceCount: 4,\n }],\n restrictScaleDown: true,\n rootVolumeSize: 30,\n securityGroups: [\"sg-987654321\"],\n strategies: [{\n spotPercentage: 70,\n }],\n subnetIds: [\"subnet-1234\"],\n tags: [{\n key: \"Env\",\n value: \"production\",\n }],\n taints: [{\n effect: \"NoExecute\",\n key: \"key1\",\n value: \"value1\",\n }],\n userData: \"echo Hello, world!\",\n});\n```\n```python\nimport pulumi\nimport pulumi_spotinst as spotinst\n\nexample = spotinst.aws.OceanLaunchSpec(\"example\",\n associate_public_ip_address=True,\n autoscale_headrooms=[spotinst.aws.OceanLaunchSpecAutoscaleHeadroomArgs(\n cpu_per_nit=1000,\n gpu_per_unit=0,\n memory_per_unit=2048,\n num_of_units=5,\n )],\n block_device_mappings=[spotinst.aws.OceanLaunchSpecBlockDeviceMappingArgs(\n device_name=\"/dev/xvda1\",\n ebs=spotinst.aws.OceanLaunchSpecBlockDeviceMappingEbsArgs(\n delete_on_termination=True,\n dynamic_volume_size=spotinst.aws.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs(\n base_size=50,\n resource=\"CPU\",\n size_per_resource_unit=20,\n ),\n encrypted=False,\n throughput=500,\n volume_size=50,\n volume_type=\"gp2\",\n ),\n )],\n elastic_ip_pools=[spotinst.aws.OceanLaunchSpecElasticIpPoolArgs(\n tag_selector=spotinst.aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs(\n tag_key=\"key\",\n tag_value=\"value\",\n ),\n )],\n iam_instance_profile=\"iam-profile\",\n image_id=\"ami-123456\",\n instance_types=[\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n ],\n labels=[spotinst.aws.OceanLaunchSpecLabelArgs(\n key=\"key1\",\n value=\"value1\",\n )],\n ocean_id=\"o-123456\",\n resource_limits=[spotinst.aws.OceanLaunchSpecResourceLimitArgs(\n max_instance_count=4,\n )],\n restrict_scale_down=True,\n root_volume_size=30,\n security_groups=[\"sg-987654321\"],\n strategies=[spotinst.aws.OceanLaunchSpecStrategyArgs(\n spot_percentage=70,\n )],\n subnet_ids=[\"subnet-1234\"],\n tags=[spotinst.aws.OceanLaunchSpecTagArgs(\n key=\"Env\",\n value=\"production\",\n )],\n taints=[spotinst.aws.OceanLaunchSpecTaintArgs(\n effect=\"NoExecute\",\n key=\"key1\",\n value=\"value1\",\n )],\n user_data=\"echo Hello, world!\")\n```\n```csharp\nusing Pulumi;\nusing SpotInst = Pulumi.SpotInst;\n\nclass MyStack : Stack\n{\n public MyStack()\n {\n var example = new SpotInst.Aws.OceanLaunchSpec(\"example\", new SpotInst.Aws.OceanLaunchSpecArgs\n {\n AssociatePublicIpAddress = true,\n AutoscaleHeadrooms = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecAutoscaleHeadroomArgs\n {\n CpuPerNit = 1000,\n GpuPerUnit = 0,\n MemoryPerUnit = 2048,\n NumOfUnits = 5,\n },\n },\n BlockDeviceMappings = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingArgs\n {\n DeviceName = \"/dev/xvda1\",\n Ebs = new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingEbsArgs\n {\n DeleteOnTermination = true,\n DynamicVolumeSize = new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs\n {\n BaseSize = 50,\n Resource = \"CPU\",\n SizePerResourceUnit = 20,\n },\n Encrypted = false,\n Throughput = 500,\n VolumeSize = 50,\n VolumeType = \"gp2\",\n },\n },\n },\n ElasticIpPools = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecElasticIpPoolArgs\n {\n TagSelector = new SpotInst.Aws.Inputs.OceanLaunchSpecElasticIpPoolTagSelectorArgs\n {\n TagKey = \"key\",\n TagValue = \"value\",\n },\n },\n },\n IamInstanceProfile = \"iam-profile\",\n ImageId = \"ami-123456\",\n InstanceTypes = \n {\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n },\n Labels = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecLabelArgs\n {\n Key = \"key1\",\n Value = \"value1\",\n },\n },\n OceanId = \"o-123456\",\n ResourceLimits = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecResourceLimitArgs\n {\n MaxInstanceCount = 4,\n },\n },\n RestrictScaleDown = true,\n RootVolumeSize = 30,\n SecurityGroups = \n {\n \"sg-987654321\",\n },\n Strategies = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecStrategyArgs\n {\n SpotPercentage = 70,\n },\n },\n SubnetIds = \n {\n \"subnet-1234\",\n },\n Tags = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecTagArgs\n {\n Key = \"Env\",\n Value = \"production\",\n },\n },\n Taints = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecTaintArgs\n {\n Effect = \"NoExecute\",\n Key = \"key1\",\n Value = \"value1\",\n },\n },\n UserData = \"echo Hello, world!\",\n });\n }\n\n}\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-spotinst/sdk/v3/go/spotinst/aws\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := aws.NewOceanLaunchSpec(ctx, \"example\", \u0026aws.OceanLaunchSpecArgs{\n\t\t\tAssociatePublicIpAddress: pulumi.Bool(true),\n\t\t\tAutoscaleHeadrooms: aws.OceanLaunchSpecAutoscaleHeadroomArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecAutoscaleHeadroomArgs{\n\t\t\t\t\tCpuPerNit: pulumi.Float64(1000),\n\t\t\t\t\tGpuPerUnit: pulumi.Int(0),\n\t\t\t\t\tMemoryPerUnit: pulumi.Int(2048),\n\t\t\t\t\tNumOfUnits: pulumi.Int(5),\n\t\t\t\t},\n\t\t\t},\n\t\t\tBlockDeviceMappings: aws.OceanLaunchSpecBlockDeviceMappingArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecBlockDeviceMappingArgs{\n\t\t\t\t\tDeviceName: pulumi.String(\"/dev/xvda1\"),\n\t\t\t\t\tEbs: \u0026aws.OceanLaunchSpecBlockDeviceMappingEbsArgs{\n\t\t\t\t\t\tDeleteOnTermination: pulumi.Bool(true),\n\t\t\t\t\t\tDynamicVolumeSize: \u0026aws.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs{\n\t\t\t\t\t\t\tBaseSize: pulumi.Int(50),\n\t\t\t\t\t\t\tResource: pulumi.String(\"CPU\"),\n\t\t\t\t\t\t\tSizePerResourceUnit: pulumi.Int(20),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tEncrypted: pulumi.Bool(false),\n\t\t\t\t\t\tThroughput: pulumi.Int(500),\n\t\t\t\t\t\tVolumeSize: pulumi.Int(50),\n\t\t\t\t\t\tVolumeType: pulumi.String(\"gp2\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tElasticIpPools: aws.OceanLaunchSpecElasticIpPoolArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecElasticIpPoolArgs{\n\t\t\t\t\tTagSelector: \u0026aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs{\n\t\t\t\t\t\tTagKey: pulumi.String(\"key\"),\n\t\t\t\t\t\tTagValue: pulumi.String(\"value\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tIamInstanceProfile: pulumi.String(\"iam-profile\"),\n\t\t\tImageId: pulumi.String(\"ami-123456\"),\n\t\t\tInstanceTypes: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"m4.large\"),\n\t\t\t\tpulumi.String(\"m4.xlarge\"),\n\t\t\t\tpulumi.String(\"m4.2xlarge\"),\n\t\t\t\tpulumi.String(\"m4.4xlarge\"),\n\t\t\t},\n\t\t\tLabels: aws.OceanLaunchSpecLabelArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecLabelArgs{\n\t\t\t\t\tKey: pulumi.String(\"key1\"),\n\t\t\t\t\tValue: pulumi.String(\"value1\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tOceanId: pulumi.String(\"o-123456\"),\n\t\t\tResourceLimits: aws.OceanLaunchSpecResourceLimitArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecResourceLimitArgs{\n\t\t\t\t\tMaxInstanceCount: pulumi.Int(4),\n\t\t\t\t},\n\t\t\t},\n\t\t\tRestrictScaleDown: pulumi.Bool(true),\n\t\t\tRootVolumeSize: pulumi.Int(30),\n\t\t\tSecurityGroups: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"sg-987654321\"),\n\t\t\t},\n\t\t\tStrategies: aws.OceanLaunchSpecStrategyArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecStrategyArgs{\n\t\t\t\t\tSpotPercentage: pulumi.Int(70),\n\t\t\t\t},\n\t\t\t},\n\t\t\tSubnetIds: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"subnet-1234\"),\n\t\t\t},\n\t\t\tTags: aws.OceanLaunchSpecTagArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecTagArgs{\n\t\t\t\t\tKey: pulumi.String(\"Env\"),\n\t\t\t\t\tValue: pulumi.String(\"production\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tTaints: aws.OceanLaunchSpecTaintArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecTaintArgs{\n\t\t\t\t\tEffect: pulumi.String(\"NoExecute\"),\n\t\t\t\t\tKey: pulumi.String(\"key1\"),\n\t\t\t\t\tValue: pulumi.String(\"value1\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tUserData: pulumi.String(\"echo Hello, world!\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\n\nexport const oceanLaunchspecId = spotinst_ocean_aws_launch_spec.example.id;\n```\n```python\nimport pulumi\n\npulumi.export(\"oceanLaunchspecId\", spotinst_ocean_aws_launch_spec[\"example\"][\"id\"])\n```\n```csharp\nusing Pulumi;\n\nclass MyStack : Stack\n{\n public MyStack()\n {\n this.OceanLaunchspecId = spotinst_ocean_aws_launch_spec.Example.Id;\n }\n\n [Output(\"oceanLaunchspecId\")]\n public Output\u003cstring\u003e OceanLaunchspecId { get; set; }\n}\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tctx.Export(\"oceanLaunchspecId\", spotinst_ocean_aws_launch_spec.Example.Id)\n\t\treturn nil\n\t})\n}\n```\n{{% /example %}}\n{{% /examples %}}", + "description": "Manages a Spotinst Ocean AWS [Virtual Node Group](https://docs.spot.io/ocean/features/launch-specifications) resource.\n\n{{% examples %}}\n## Example Usage\n{{% example %}}\n\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as spotinst from \"@pulumi/spotinst\";\n\nconst example = new spotinst.aws.OceanLaunchSpec(\"example\", {\n associatePublicIpAddress: true,\n autoscaleHeadrooms: [{\n cpuPerNit: 1000,\n gpuPerUnit: 0,\n memoryPerUnit: 2048,\n numOfUnits: 5,\n }],\n blockDeviceMappings: [{\n deviceName: \"/dev/xvda1\",\n ebs: {\n deleteOnTermination: true,\n dynamicVolumeSize: {\n baseSize: 50,\n resource: \"CPU\",\n sizePerResourceUnit: 20,\n },\n encrypted: false,\n throughput: 500,\n volumeSize: 50,\n volumeType: \"gp2\",\n },\n }],\n createOptions: {\n initialNodes: 1,\n },\n elasticIpPools: [{\n tagSelector: {\n tagKey: \"key\",\n tagValue: \"value\",\n },\n }],\n iamInstanceProfile: \"iam-profile\",\n imageId: \"ami-123456\",\n instanceTypes: [\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n ],\n labels: [{\n key: \"key1\",\n value: \"value1\",\n }],\n oceanId: \"o-123456\",\n resourceLimits: [{\n maxInstanceCount: 4,\n }],\n restrictScaleDown: true,\n rootVolumeSize: 30,\n securityGroups: [\"sg-987654321\"],\n strategies: [{\n spotPercentage: 70,\n }],\n subnetIds: [\"subnet-1234\"],\n tags: [{\n key: \"Env\",\n value: \"production\",\n }],\n taints: [{\n effect: \"NoExecute\",\n key: \"key1\",\n value: \"value1\",\n }],\n userData: \"echo Hello, world!\",\n});\n```\n```python\nimport pulumi\nimport pulumi_spotinst as spotinst\n\nexample = spotinst.aws.OceanLaunchSpec(\"example\",\n associate_public_ip_address=True,\n autoscale_headrooms=[spotinst.aws.OceanLaunchSpecAutoscaleHeadroomArgs(\n cpu_per_nit=1000,\n gpu_per_unit=0,\n memory_per_unit=2048,\n num_of_units=5,\n )],\n block_device_mappings=[spotinst.aws.OceanLaunchSpecBlockDeviceMappingArgs(\n device_name=\"/dev/xvda1\",\n ebs=spotinst.aws.OceanLaunchSpecBlockDeviceMappingEbsArgs(\n delete_on_termination=True,\n dynamic_volume_size=spotinst.aws.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs(\n base_size=50,\n resource=\"CPU\",\n size_per_resource_unit=20,\n ),\n encrypted=False,\n throughput=500,\n volume_size=50,\n volume_type=\"gp2\",\n ),\n )],\n create_options=spotinst.aws.OceanLaunchSpecCreateOptionsArgs(\n initial_nodes=1,\n ),\n elastic_ip_pools=[spotinst.aws.OceanLaunchSpecElasticIpPoolArgs(\n tag_selector=spotinst.aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs(\n tag_key=\"key\",\n tag_value=\"value\",\n ),\n )],\n iam_instance_profile=\"iam-profile\",\n image_id=\"ami-123456\",\n instance_types=[\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n ],\n labels=[spotinst.aws.OceanLaunchSpecLabelArgs(\n key=\"key1\",\n value=\"value1\",\n )],\n ocean_id=\"o-123456\",\n resource_limits=[spotinst.aws.OceanLaunchSpecResourceLimitArgs(\n max_instance_count=4,\n )],\n restrict_scale_down=True,\n root_volume_size=30,\n security_groups=[\"sg-987654321\"],\n strategies=[spotinst.aws.OceanLaunchSpecStrategyArgs(\n spot_percentage=70,\n )],\n subnet_ids=[\"subnet-1234\"],\n tags=[spotinst.aws.OceanLaunchSpecTagArgs(\n key=\"Env\",\n value=\"production\",\n )],\n taints=[spotinst.aws.OceanLaunchSpecTaintArgs(\n effect=\"NoExecute\",\n key=\"key1\",\n value=\"value1\",\n )],\n user_data=\"echo Hello, world!\")\n```\n```csharp\nusing Pulumi;\nusing SpotInst = Pulumi.SpotInst;\n\nclass MyStack : Stack\n{\n public MyStack()\n {\n var example = new SpotInst.Aws.OceanLaunchSpec(\"example\", new SpotInst.Aws.OceanLaunchSpecArgs\n {\n AssociatePublicIpAddress = true,\n AutoscaleHeadrooms = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecAutoscaleHeadroomArgs\n {\n CpuPerNit = 1000,\n GpuPerUnit = 0,\n MemoryPerUnit = 2048,\n NumOfUnits = 5,\n },\n },\n BlockDeviceMappings = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingArgs\n {\n DeviceName = \"/dev/xvda1\",\n Ebs = new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingEbsArgs\n {\n DeleteOnTermination = true,\n DynamicVolumeSize = new SpotInst.Aws.Inputs.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs\n {\n BaseSize = 50,\n Resource = \"CPU\",\n SizePerResourceUnit = 20,\n },\n Encrypted = false,\n Throughput = 500,\n VolumeSize = 50,\n VolumeType = \"gp2\",\n },\n },\n },\n CreateOptions = new SpotInst.Aws.Inputs.OceanLaunchSpecCreateOptionsArgs\n {\n InitialNodes = 1,\n },\n ElasticIpPools = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecElasticIpPoolArgs\n {\n TagSelector = new SpotInst.Aws.Inputs.OceanLaunchSpecElasticIpPoolTagSelectorArgs\n {\n TagKey = \"key\",\n TagValue = \"value\",\n },\n },\n },\n IamInstanceProfile = \"iam-profile\",\n ImageId = \"ami-123456\",\n InstanceTypes = \n {\n \"m4.large\",\n \"m4.xlarge\",\n \"m4.2xlarge\",\n \"m4.4xlarge\",\n },\n Labels = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecLabelArgs\n {\n Key = \"key1\",\n Value = \"value1\",\n },\n },\n OceanId = \"o-123456\",\n ResourceLimits = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecResourceLimitArgs\n {\n MaxInstanceCount = 4,\n },\n },\n RestrictScaleDown = true,\n RootVolumeSize = 30,\n SecurityGroups = \n {\n \"sg-987654321\",\n },\n Strategies = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecStrategyArgs\n {\n SpotPercentage = 70,\n },\n },\n SubnetIds = \n {\n \"subnet-1234\",\n },\n Tags = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecTagArgs\n {\n Key = \"Env\",\n Value = \"production\",\n },\n },\n Taints = \n {\n new SpotInst.Aws.Inputs.OceanLaunchSpecTaintArgs\n {\n Effect = \"NoExecute\",\n Key = \"key1\",\n Value = \"value1\",\n },\n },\n UserData = \"echo Hello, world!\",\n });\n }\n\n}\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-spotinst/sdk/v3/go/spotinst/aws\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := aws.NewOceanLaunchSpec(ctx, \"example\", \u0026aws.OceanLaunchSpecArgs{\n\t\t\tAssociatePublicIpAddress: pulumi.Bool(true),\n\t\t\tAutoscaleHeadrooms: aws.OceanLaunchSpecAutoscaleHeadroomArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecAutoscaleHeadroomArgs{\n\t\t\t\t\tCpuPerNit: pulumi.Float64(1000),\n\t\t\t\t\tGpuPerUnit: pulumi.Int(0),\n\t\t\t\t\tMemoryPerUnit: pulumi.Int(2048),\n\t\t\t\t\tNumOfUnits: pulumi.Int(5),\n\t\t\t\t},\n\t\t\t},\n\t\t\tBlockDeviceMappings: aws.OceanLaunchSpecBlockDeviceMappingArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecBlockDeviceMappingArgs{\n\t\t\t\t\tDeviceName: pulumi.String(\"/dev/xvda1\"),\n\t\t\t\t\tEbs: \u0026aws.OceanLaunchSpecBlockDeviceMappingEbsArgs{\n\t\t\t\t\t\tDeleteOnTermination: pulumi.Bool(true),\n\t\t\t\t\t\tDynamicVolumeSize: \u0026aws.OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs{\n\t\t\t\t\t\t\tBaseSize: pulumi.Int(50),\n\t\t\t\t\t\t\tResource: pulumi.String(\"CPU\"),\n\t\t\t\t\t\t\tSizePerResourceUnit: pulumi.Int(20),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tEncrypted: pulumi.Bool(false),\n\t\t\t\t\t\tThroughput: pulumi.Int(500),\n\t\t\t\t\t\tVolumeSize: pulumi.Int(50),\n\t\t\t\t\t\tVolumeType: pulumi.String(\"gp2\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tCreateOptions: \u0026aws.OceanLaunchSpecCreateOptionsArgs{\n\t\t\t\tInitialNodes: pulumi.Int(1),\n\t\t\t},\n\t\t\tElasticIpPools: aws.OceanLaunchSpecElasticIpPoolArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecElasticIpPoolArgs{\n\t\t\t\t\tTagSelector: \u0026aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs{\n\t\t\t\t\t\tTagKey: pulumi.String(\"key\"),\n\t\t\t\t\t\tTagValue: pulumi.String(\"value\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tIamInstanceProfile: pulumi.String(\"iam-profile\"),\n\t\t\tImageId: pulumi.String(\"ami-123456\"),\n\t\t\tInstanceTypes: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"m4.large\"),\n\t\t\t\tpulumi.String(\"m4.xlarge\"),\n\t\t\t\tpulumi.String(\"m4.2xlarge\"),\n\t\t\t\tpulumi.String(\"m4.4xlarge\"),\n\t\t\t},\n\t\t\tLabels: aws.OceanLaunchSpecLabelArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecLabelArgs{\n\t\t\t\t\tKey: pulumi.String(\"key1\"),\n\t\t\t\t\tValue: pulumi.String(\"value1\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tOceanId: pulumi.String(\"o-123456\"),\n\t\t\tResourceLimits: aws.OceanLaunchSpecResourceLimitArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecResourceLimitArgs{\n\t\t\t\t\tMaxInstanceCount: pulumi.Int(4),\n\t\t\t\t},\n\t\t\t},\n\t\t\tRestrictScaleDown: pulumi.Bool(true),\n\t\t\tRootVolumeSize: pulumi.Int(30),\n\t\t\tSecurityGroups: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"sg-987654321\"),\n\t\t\t},\n\t\t\tStrategies: aws.OceanLaunchSpecStrategyArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecStrategyArgs{\n\t\t\t\t\tSpotPercentage: pulumi.Int(70),\n\t\t\t\t},\n\t\t\t},\n\t\t\tSubnetIds: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"subnet-1234\"),\n\t\t\t},\n\t\t\tTags: aws.OceanLaunchSpecTagArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecTagArgs{\n\t\t\t\t\tKey: pulumi.String(\"Env\"),\n\t\t\t\t\tValue: pulumi.String(\"production\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tTaints: aws.OceanLaunchSpecTaintArray{\n\t\t\t\t\u0026aws.OceanLaunchSpecTaintArgs{\n\t\t\t\t\tEffect: pulumi.String(\"NoExecute\"),\n\t\t\t\t\tKey: pulumi.String(\"key1\"),\n\t\t\t\t\tValue: pulumi.String(\"value1\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tUserData: pulumi.String(\"echo Hello, world!\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\n\nexport const oceanLaunchspecId = spotinst_ocean_aws_launch_spec.example.id;\n```\n```python\nimport pulumi\n\npulumi.export(\"oceanLaunchspecId\", spotinst_ocean_aws_launch_spec[\"example\"][\"id\"])\n```\n```csharp\nusing Pulumi;\n\nclass MyStack : Stack\n{\n public MyStack()\n {\n this.OceanLaunchspecId = spotinst_ocean_aws_launch_spec.Example.Id;\n }\n\n [Output(\"oceanLaunchspecId\")]\n public Output\u003cstring\u003e OceanLaunchspecId { get; set; }\n}\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tctx.Export(\"oceanLaunchspecId\", spotinst_ocean_aws_launch_spec.Example.Id)\n\t\treturn nil\n\t})\n}\n```\n{{% /example %}}\n{{% /examples %}}", "properties": { "associatePublicIpAddress": { "type": "boolean", @@ -13393,6 +13410,9 @@ }, "description": "Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes.\n" }, + "createOptions": { + "$ref": "#/types/spotinst:aws/OceanLaunchSpecCreateOptions:OceanLaunchSpecCreateOptions" + }, "elasticIpPools": { "type": "array", "items": { @@ -13506,6 +13526,9 @@ }, "description": "Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes.\n" }, + "createOptions": { + "$ref": "#/types/spotinst:aws/OceanLaunchSpecCreateOptions:OceanLaunchSpecCreateOptions" + }, "elasticIpPools": { "type": "array", "items": { @@ -13620,6 +13643,9 @@ }, "description": "Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes.\n" }, + "createOptions": { + "$ref": "#/types/spotinst:aws/OceanLaunchSpecCreateOptions:OceanLaunchSpecCreateOptions" + }, "elasticIpPools": { "type": "array", "items": { diff --git a/provider/go.mod b/provider/go.mod index 171c2fb3..e1f6f246 100644 --- a/provider/go.mod +++ b/provider/go.mod @@ -13,7 +13,7 @@ require ( replace ( github.com/hashicorp/go-getter v1.5.0 => github.com/hashicorp/go-getter v1.4.0 github.com/hashicorp/vault => github.com/hashicorp/vault v1.2.0 - github.com/spotinst/terraform-provider-spotinst => github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210429195502-d15ec9bf741c + github.com/spotinst/terraform-provider-spotinst => github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210504172624-0754182c644d golang.org/x/crypto => golang.org/x/crypto v0.0.0-20200117160349-530e935923ad golang.org/x/sys => golang.org/x/sys v0.0.0-20190412213103-97732733099d ) diff --git a/provider/go.sum b/provider/go.sum index dc13cdf4..035da6ab 100644 --- a/provider/go.sum +++ b/provider/go.sum @@ -797,6 +797,8 @@ github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210428125936-f306bfac7 github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210428125936-f306bfac77f4/go.mod h1:yMqifs88/giksXnlTY2HOuevmJiqhDR+jXl1VgJkh1E= github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210429195502-d15ec9bf741c h1:8bqh/CsWNRI3CiGKBfngwvRYPLfr3DvEfRFmgKUl70A= github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210429195502-d15ec9bf741c/go.mod h1:yMqifs88/giksXnlTY2HOuevmJiqhDR+jXl1VgJkh1E= +github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210504172624-0754182c644d h1:Tjv8+VX4+BwY2tCey08nPvC1v9iUhfouJa7nr18npJk= +github.com/pulumi/terraform-provider-spotinst v1.33.1-0.20210504172624-0754182c644d/go.mod h1:YkHUgat6vIIzuyyqJIpmS2m1JywCt31pRndta1dD/iw= github.com/rjeczalik/notify v0.9.2 h1:MiTWrPj55mNDHEiIX5YUSKefw/+lCQVoAFmD6oQm5w8= github.com/rjeczalik/notify v0.9.2/go.mod h1:aErll2f0sUX9PXZnVNyeiObbmTlk5jnMoCa4QEjJeqM= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af h1:gu+uRPtBe88sKxUCEXRoeCvVG90TJmwhiqRpvdhQFng= @@ -854,6 +856,8 @@ github.com/spf13/viper v1.4.0 h1:yXHLWeravcrgGyFSyCgdYpXQ9dR9c/WED3pg1RhxqEU= github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= github.com/spotinst/spotinst-sdk-go v1.85.0 h1:tMXKhxfmU7BnqTnUpR2s/hEyTASfrxkgPb/3Tqn6tmM= github.com/spotinst/spotinst-sdk-go v1.85.0/go.mod h1:RuKksd1/RyQogMCxKFI5B75NeFRcgl3W+26DVX6S4m0= +github.com/spotinst/spotinst-sdk-go v1.86.0 h1:52oFqTav1Mi+iVfhqliNXgVXMpbhXBxnWO+LlTzxeOw= +github.com/spotinst/spotinst-sdk-go v1.86.0/go.mod h1:RuKksd1/RyQogMCxKFI5B75NeFRcgl3W+26DVX6S4m0= github.com/src-d/gcfg v1.4.0 h1:xXbNR5AlLSA315x2UO+fTSSAXCDf+Ar38/6oyGbDKQ4= github.com/src-d/gcfg v1.4.0/go.mod h1:p/UMsR43ujA89BJY9duynAwIpvqEujIH/jFlfL7jWoI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= diff --git a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsArgs.cs b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsArgs.cs new file mode 100644 index 00000000..7cc27b6a --- /dev/null +++ b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsArgs.cs @@ -0,0 +1,25 @@ +// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** +// *** Do not edit by hand unless you're certain you know what you are doing! *** + +using System; +using System.Collections.Generic; +using System.Collections.Immutable; +using System.Threading.Tasks; +using Pulumi.Serialization; + +namespace Pulumi.SpotInst.Aws.Inputs +{ + + public sealed class OceanLaunchSpecCreateOptionsArgs : Pulumi.ResourceArgs + { + /// + /// When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + /// + [Input("initialNodes", required: true)] + public Input InitialNodes { get; set; } = null!; + + public OceanLaunchSpecCreateOptionsArgs() + { + } + } +} diff --git a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsGetArgs.cs b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsGetArgs.cs new file mode 100644 index 00000000..b714a1cc --- /dev/null +++ b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecCreateOptionsGetArgs.cs @@ -0,0 +1,25 @@ +// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** +// *** Do not edit by hand unless you're certain you know what you are doing! *** + +using System; +using System.Collections.Generic; +using System.Collections.Immutable; +using System.Threading.Tasks; +using Pulumi.Serialization; + +namespace Pulumi.SpotInst.Aws.Inputs +{ + + public sealed class OceanLaunchSpecCreateOptionsGetArgs : Pulumi.ResourceArgs + { + /// + /// When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + /// + [Input("initialNodes", required: true)] + public Input InitialNodes { get; set; } = null!; + + public OceanLaunchSpecCreateOptionsGetArgs() + { + } + } +} diff --git a/sdk/dotnet/Aws/OceanLaunchSpec.cs b/sdk/dotnet/Aws/OceanLaunchSpec.cs index 3eb4c667..31bf27e8 100644 --- a/sdk/dotnet/Aws/OceanLaunchSpec.cs +++ b/sdk/dotnet/Aws/OceanLaunchSpec.cs @@ -56,6 +56,10 @@ namespace Pulumi.SpotInst.Aws /// }, /// }, /// }, + /// CreateOptions = new SpotInst.Aws.Inputs.OceanLaunchSpecCreateOptionsArgs + /// { + /// InitialNodes = 1, + /// }, /// ElasticIpPools = /// { /// new SpotInst.Aws.Inputs.OceanLaunchSpecElasticIpPoolArgs @@ -168,6 +172,9 @@ public partial class OceanLaunchSpec : Pulumi.CustomResource [Output("blockDeviceMappings")] public Output> BlockDeviceMappings { get; private set; } = null!; + [Output("createOptions")] + public Output CreateOptions { get; private set; } = null!; + /// /// Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. /// @@ -334,6 +341,9 @@ public InputList BlockDeviceMappin set => _blockDeviceMappings = value; } + [Input("createOptions")] + public Input? CreateOptions { get; set; } + [Input("elasticIpPools")] private InputList? _elasticIpPools; @@ -513,6 +523,9 @@ public InputList BlockDeviceMap set => _blockDeviceMappings = value; } + [Input("createOptions")] + public Input? CreateOptions { get; set; } + [Input("elasticIpPools")] private InputList? _elasticIpPools; diff --git a/sdk/dotnet/Aws/Outputs/OceanLaunchSpecCreateOptions.cs b/sdk/dotnet/Aws/Outputs/OceanLaunchSpecCreateOptions.cs new file mode 100644 index 00000000..01791e27 --- /dev/null +++ b/sdk/dotnet/Aws/Outputs/OceanLaunchSpecCreateOptions.cs @@ -0,0 +1,27 @@ +// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** +// *** Do not edit by hand unless you're certain you know what you are doing! *** + +using System; +using System.Collections.Generic; +using System.Collections.Immutable; +using System.Threading.Tasks; +using Pulumi.Serialization; + +namespace Pulumi.SpotInst.Aws.Outputs +{ + + [OutputType] + public sealed class OceanLaunchSpecCreateOptions + { + /// + /// When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + /// + public readonly int InitialNodes; + + [OutputConstructor] + private OceanLaunchSpecCreateOptions(int initialNodes) + { + InitialNodes = initialNodes; + } + } +} diff --git a/sdk/go/spotinst/aws/oceanLaunchSpec.go b/sdk/go/spotinst/aws/oceanLaunchSpec.go index eaa6438c..e17014fd 100644 --- a/sdk/go/spotinst/aws/oceanLaunchSpec.go +++ b/sdk/go/spotinst/aws/oceanLaunchSpec.go @@ -52,6 +52,9 @@ import ( // }, // }, // }, +// CreateOptions: &aws.OceanLaunchSpecCreateOptionsArgs{ +// InitialNodes: pulumi.Int(1), +// }, // ElasticIpPools: aws.OceanLaunchSpecElasticIpPoolArray{ // &aws.OceanLaunchSpecElasticIpPoolArgs{ // TagSelector: &aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs{ @@ -138,6 +141,7 @@ type OceanLaunchSpec struct { AutoscaleHeadrooms OceanLaunchSpecAutoscaleHeadroomArrayOutput `pulumi:"autoscaleHeadrooms"` // Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. BlockDeviceMappings OceanLaunchSpecBlockDeviceMappingArrayOutput `pulumi:"blockDeviceMappings"` + CreateOptions OceanLaunchSpecCreateOptionsPtrOutput `pulumi:"createOptions"` // Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. ElasticIpPools OceanLaunchSpecElasticIpPoolArrayOutput `pulumi:"elasticIpPools"` // The ARN or name of an IAM instance profile to associate with launched instances. @@ -208,6 +212,7 @@ type oceanLaunchSpecState struct { AutoscaleHeadrooms []OceanLaunchSpecAutoscaleHeadroom `pulumi:"autoscaleHeadrooms"` // Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. BlockDeviceMappings []OceanLaunchSpecBlockDeviceMapping `pulumi:"blockDeviceMappings"` + CreateOptions *OceanLaunchSpecCreateOptions `pulumi:"createOptions"` // Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. ElasticIpPools []OceanLaunchSpecElasticIpPool `pulumi:"elasticIpPools"` // The ARN or name of an IAM instance profile to associate with launched instances. @@ -247,6 +252,7 @@ type OceanLaunchSpecState struct { AutoscaleHeadrooms OceanLaunchSpecAutoscaleHeadroomArrayInput // Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. BlockDeviceMappings OceanLaunchSpecBlockDeviceMappingArrayInput + CreateOptions OceanLaunchSpecCreateOptionsPtrInput // Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. ElasticIpPools OceanLaunchSpecElasticIpPoolArrayInput // The ARN or name of an IAM instance profile to associate with launched instances. @@ -290,6 +296,7 @@ type oceanLaunchSpecArgs struct { AutoscaleHeadrooms []OceanLaunchSpecAutoscaleHeadroom `pulumi:"autoscaleHeadrooms"` // Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. BlockDeviceMappings []OceanLaunchSpecBlockDeviceMapping `pulumi:"blockDeviceMappings"` + CreateOptions *OceanLaunchSpecCreateOptions `pulumi:"createOptions"` // Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. ElasticIpPools []OceanLaunchSpecElasticIpPool `pulumi:"elasticIpPools"` // The ARN or name of an IAM instance profile to associate with launched instances. @@ -330,6 +337,7 @@ type OceanLaunchSpecArgs struct { AutoscaleHeadrooms OceanLaunchSpecAutoscaleHeadroomArrayInput // Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. BlockDeviceMappings OceanLaunchSpecBlockDeviceMappingArrayInput + CreateOptions OceanLaunchSpecCreateOptionsPtrInput // Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. ElasticIpPools OceanLaunchSpecElasticIpPoolArrayInput // The ARN or name of an IAM instance profile to associate with launched instances. diff --git a/sdk/go/spotinst/aws/pulumiTypes.go b/sdk/go/spotinst/aws/pulumiTypes.go index 9faa4118..63c3e350 100644 --- a/sdk/go/spotinst/aws/pulumiTypes.go +++ b/sdk/go/spotinst/aws/pulumiTypes.go @@ -14798,6 +14798,137 @@ func (o OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizePtrOutput) SizePerR }).(pulumi.IntPtrOutput) } +type OceanLaunchSpecCreateOptions struct { + // When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + InitialNodes int `pulumi:"initialNodes"` +} + +// OceanLaunchSpecCreateOptionsInput is an input type that accepts OceanLaunchSpecCreateOptionsArgs and OceanLaunchSpecCreateOptionsOutput values. +// You can construct a concrete instance of `OceanLaunchSpecCreateOptionsInput` via: +// +// OceanLaunchSpecCreateOptionsArgs{...} +type OceanLaunchSpecCreateOptionsInput interface { + pulumi.Input + + ToOceanLaunchSpecCreateOptionsOutput() OceanLaunchSpecCreateOptionsOutput + ToOceanLaunchSpecCreateOptionsOutputWithContext(context.Context) OceanLaunchSpecCreateOptionsOutput +} + +type OceanLaunchSpecCreateOptionsArgs struct { + // When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + InitialNodes pulumi.IntInput `pulumi:"initialNodes"` +} + +func (OceanLaunchSpecCreateOptionsArgs) ElementType() reflect.Type { + return reflect.TypeOf((*OceanLaunchSpecCreateOptions)(nil)).Elem() +} + +func (i OceanLaunchSpecCreateOptionsArgs) ToOceanLaunchSpecCreateOptionsOutput() OceanLaunchSpecCreateOptionsOutput { + return i.ToOceanLaunchSpecCreateOptionsOutputWithContext(context.Background()) +} + +func (i OceanLaunchSpecCreateOptionsArgs) ToOceanLaunchSpecCreateOptionsOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsOutput { + return pulumi.ToOutputWithContext(ctx, i).(OceanLaunchSpecCreateOptionsOutput) +} + +func (i OceanLaunchSpecCreateOptionsArgs) ToOceanLaunchSpecCreateOptionsPtrOutput() OceanLaunchSpecCreateOptionsPtrOutput { + return i.ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(context.Background()) +} + +func (i OceanLaunchSpecCreateOptionsArgs) ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsPtrOutput { + return pulumi.ToOutputWithContext(ctx, i).(OceanLaunchSpecCreateOptionsOutput).ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(ctx) +} + +// OceanLaunchSpecCreateOptionsPtrInput is an input type that accepts OceanLaunchSpecCreateOptionsArgs, OceanLaunchSpecCreateOptionsPtr and OceanLaunchSpecCreateOptionsPtrOutput values. +// You can construct a concrete instance of `OceanLaunchSpecCreateOptionsPtrInput` via: +// +// OceanLaunchSpecCreateOptionsArgs{...} +// +// or: +// +// nil +type OceanLaunchSpecCreateOptionsPtrInput interface { + pulumi.Input + + ToOceanLaunchSpecCreateOptionsPtrOutput() OceanLaunchSpecCreateOptionsPtrOutput + ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(context.Context) OceanLaunchSpecCreateOptionsPtrOutput +} + +type oceanLaunchSpecCreateOptionsPtrType OceanLaunchSpecCreateOptionsArgs + +func OceanLaunchSpecCreateOptionsPtr(v *OceanLaunchSpecCreateOptionsArgs) OceanLaunchSpecCreateOptionsPtrInput { + return (*oceanLaunchSpecCreateOptionsPtrType)(v) +} + +func (*oceanLaunchSpecCreateOptionsPtrType) ElementType() reflect.Type { + return reflect.TypeOf((**OceanLaunchSpecCreateOptions)(nil)).Elem() +} + +func (i *oceanLaunchSpecCreateOptionsPtrType) ToOceanLaunchSpecCreateOptionsPtrOutput() OceanLaunchSpecCreateOptionsPtrOutput { + return i.ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(context.Background()) +} + +func (i *oceanLaunchSpecCreateOptionsPtrType) ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsPtrOutput { + return pulumi.ToOutputWithContext(ctx, i).(OceanLaunchSpecCreateOptionsPtrOutput) +} + +type OceanLaunchSpecCreateOptionsOutput struct{ *pulumi.OutputState } + +func (OceanLaunchSpecCreateOptionsOutput) ElementType() reflect.Type { + return reflect.TypeOf((*OceanLaunchSpecCreateOptions)(nil)).Elem() +} + +func (o OceanLaunchSpecCreateOptionsOutput) ToOceanLaunchSpecCreateOptionsOutput() OceanLaunchSpecCreateOptionsOutput { + return o +} + +func (o OceanLaunchSpecCreateOptionsOutput) ToOceanLaunchSpecCreateOptionsOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsOutput { + return o +} + +func (o OceanLaunchSpecCreateOptionsOutput) ToOceanLaunchSpecCreateOptionsPtrOutput() OceanLaunchSpecCreateOptionsPtrOutput { + return o.ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(context.Background()) +} + +func (o OceanLaunchSpecCreateOptionsOutput) ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsPtrOutput { + return o.ApplyT(func(v OceanLaunchSpecCreateOptions) *OceanLaunchSpecCreateOptions { + return &v + }).(OceanLaunchSpecCreateOptionsPtrOutput) +} + +// When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. +func (o OceanLaunchSpecCreateOptionsOutput) InitialNodes() pulumi.IntOutput { + return o.ApplyT(func(v OceanLaunchSpecCreateOptions) int { return v.InitialNodes }).(pulumi.IntOutput) +} + +type OceanLaunchSpecCreateOptionsPtrOutput struct{ *pulumi.OutputState } + +func (OceanLaunchSpecCreateOptionsPtrOutput) ElementType() reflect.Type { + return reflect.TypeOf((**OceanLaunchSpecCreateOptions)(nil)).Elem() +} + +func (o OceanLaunchSpecCreateOptionsPtrOutput) ToOceanLaunchSpecCreateOptionsPtrOutput() OceanLaunchSpecCreateOptionsPtrOutput { + return o +} + +func (o OceanLaunchSpecCreateOptionsPtrOutput) ToOceanLaunchSpecCreateOptionsPtrOutputWithContext(ctx context.Context) OceanLaunchSpecCreateOptionsPtrOutput { + return o +} + +func (o OceanLaunchSpecCreateOptionsPtrOutput) Elem() OceanLaunchSpecCreateOptionsOutput { + return o.ApplyT(func(v *OceanLaunchSpecCreateOptions) OceanLaunchSpecCreateOptions { return *v }).(OceanLaunchSpecCreateOptionsOutput) +} + +// When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. +func (o OceanLaunchSpecCreateOptionsPtrOutput) InitialNodes() pulumi.IntPtrOutput { + return o.ApplyT(func(v *OceanLaunchSpecCreateOptions) *int { + if v == nil { + return nil + } + return &v.InitialNodes + }).(pulumi.IntPtrOutput) +} + type OceanLaunchSpecElasticIpPool struct { // A key-value pair, which defines an Elastic IP from the customer pool. Can be null. TagSelector *OceanLaunchSpecElasticIpPoolTagSelector `pulumi:"tagSelector"` @@ -16725,6 +16856,8 @@ func init() { pulumi.RegisterOutputType(OceanLaunchSpecBlockDeviceMappingEbsPtrOutput{}) pulumi.RegisterOutputType(OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeOutput{}) pulumi.RegisterOutputType(OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizePtrOutput{}) + pulumi.RegisterOutputType(OceanLaunchSpecCreateOptionsOutput{}) + pulumi.RegisterOutputType(OceanLaunchSpecCreateOptionsPtrOutput{}) pulumi.RegisterOutputType(OceanLaunchSpecElasticIpPoolOutput{}) pulumi.RegisterOutputType(OceanLaunchSpecElasticIpPoolArrayOutput{}) pulumi.RegisterOutputType(OceanLaunchSpecElasticIpPoolTagSelectorOutput{}) diff --git a/sdk/nodejs/aws/oceanLaunchSpec.ts b/sdk/nodejs/aws/oceanLaunchSpec.ts index 1f1c5985..480c2fc5 100644 --- a/sdk/nodejs/aws/oceanLaunchSpec.ts +++ b/sdk/nodejs/aws/oceanLaunchSpec.ts @@ -37,6 +37,9 @@ import * as utilities from "../utilities"; * volumeType: "gp2", * }, * }], + * createOptions: { + * initialNodes: 1, + * }, * elasticIpPools: [{ * tagSelector: { * tagKey: "key", @@ -124,6 +127,7 @@ export class OceanLaunchSpec extends pulumi.CustomResource { * Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. */ public readonly blockDeviceMappings!: pulumi.Output; + public readonly createOptions!: pulumi.Output; /** * Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. */ @@ -199,6 +203,7 @@ export class OceanLaunchSpec extends pulumi.CustomResource { inputs["associatePublicIpAddress"] = state ? state.associatePublicIpAddress : undefined; inputs["autoscaleHeadrooms"] = state ? state.autoscaleHeadrooms : undefined; inputs["blockDeviceMappings"] = state ? state.blockDeviceMappings : undefined; + inputs["createOptions"] = state ? state.createOptions : undefined; inputs["elasticIpPools"] = state ? state.elasticIpPools : undefined; inputs["iamInstanceProfile"] = state ? state.iamInstanceProfile : undefined; inputs["imageId"] = state ? state.imageId : undefined; @@ -223,6 +228,7 @@ export class OceanLaunchSpec extends pulumi.CustomResource { inputs["associatePublicIpAddress"] = args ? args.associatePublicIpAddress : undefined; inputs["autoscaleHeadrooms"] = args ? args.autoscaleHeadrooms : undefined; inputs["blockDeviceMappings"] = args ? args.blockDeviceMappings : undefined; + inputs["createOptions"] = args ? args.createOptions : undefined; inputs["elasticIpPools"] = args ? args.elasticIpPools : undefined; inputs["iamInstanceProfile"] = args ? args.iamInstanceProfile : undefined; inputs["imageId"] = args ? args.imageId : undefined; @@ -263,6 +269,7 @@ export interface OceanLaunchSpecState { * Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. */ readonly blockDeviceMappings?: pulumi.Input[]>; + readonly createOptions?: pulumi.Input; /** * Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. */ @@ -339,6 +346,7 @@ export interface OceanLaunchSpecArgs { * Object. Array list of block devices that are exposed to the instance, specify either virtual devices and EBS volumes. */ readonly blockDeviceMappings?: pulumi.Input[]>; + readonly createOptions?: pulumi.Input; /** * Assign an Elastic IP to the instances spun by the Virtual Node Group. Can be null. */ diff --git a/sdk/nodejs/types/input.ts b/sdk/nodejs/types/input.ts index 1bf5b32a..b3ac075e 100644 --- a/sdk/nodejs/types/input.ts +++ b/sdk/nodejs/types/input.ts @@ -2108,6 +2108,13 @@ export namespace aws { sizePerResourceUnit: pulumi.Input; } + export interface OceanLaunchSpecCreateOptions { + /** + * When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + */ + initialNodes: pulumi.Input; + } + export interface OceanLaunchSpecElasticIpPool { /** * A key-value pair, which defines an Elastic IP from the customer pool. Can be null. diff --git a/sdk/nodejs/types/output.ts b/sdk/nodejs/types/output.ts index 3abe597d..7ef0f353 100644 --- a/sdk/nodejs/types/output.ts +++ b/sdk/nodejs/types/output.ts @@ -2108,6 +2108,13 @@ export namespace aws { sizePerResourceUnit: number; } + export interface OceanLaunchSpecCreateOptions { + /** + * When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + */ + initialNodes: number; + } + export interface OceanLaunchSpecElasticIpPool { /** * A key-value pair, which defines an Elastic IP from the customer pool. Can be null. diff --git a/sdk/python/pulumi_spotinst/aws/_inputs.py b/sdk/python/pulumi_spotinst/aws/_inputs.py index 22131f18..8e921213 100644 --- a/sdk/python/pulumi_spotinst/aws/_inputs.py +++ b/sdk/python/pulumi_spotinst/aws/_inputs.py @@ -103,6 +103,7 @@ 'OceanLaunchSpecBlockDeviceMappingArgs', 'OceanLaunchSpecBlockDeviceMappingEbsArgs', 'OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSizeArgs', + 'OceanLaunchSpecCreateOptionsArgs', 'OceanLaunchSpecElasticIpPoolArgs', 'OceanLaunchSpecElasticIpPoolTagSelectorArgs', 'OceanLaunchSpecLabelArgs', @@ -7492,6 +7493,28 @@ def size_per_resource_unit(self, value: pulumi.Input[int]): pulumi.set(self, "size_per_resource_unit", value) +@pulumi.input_type +class OceanLaunchSpecCreateOptionsArgs: + def __init__(__self__, *, + initial_nodes: pulumi.Input[int]): + """ + :param pulumi.Input[int] initial_nodes: When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + """ + pulumi.set(__self__, "initial_nodes", initial_nodes) + + @property + @pulumi.getter(name="initialNodes") + def initial_nodes(self) -> pulumi.Input[int]: + """ + When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + """ + return pulumi.get(self, "initial_nodes") + + @initial_nodes.setter + def initial_nodes(self, value: pulumi.Input[int]): + pulumi.set(self, "initial_nodes", value) + + @pulumi.input_type class OceanLaunchSpecElasticIpPoolArgs: def __init__(__self__, *, diff --git a/sdk/python/pulumi_spotinst/aws/ocean_launch_spec.py b/sdk/python/pulumi_spotinst/aws/ocean_launch_spec.py index f665504c..edfbc3dd 100644 --- a/sdk/python/pulumi_spotinst/aws/ocean_launch_spec.py +++ b/sdk/python/pulumi_spotinst/aws/ocean_launch_spec.py @@ -19,6 +19,7 @@ def __init__(__self__, *, associate_public_ip_address: Optional[pulumi.Input[bool]] = None, autoscale_headrooms: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecAutoscaleHeadroomArgs']]]] = None, block_device_mappings: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecBlockDeviceMappingArgs']]]] = None, + create_options: Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']] = None, elastic_ip_pools: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecElasticIpPoolArgs']]]] = None, iam_instance_profile: Optional[pulumi.Input[str]] = None, image_id: Optional[pulumi.Input[str]] = None, @@ -61,6 +62,8 @@ def __init__(__self__, *, pulumi.set(__self__, "autoscale_headrooms", autoscale_headrooms) if block_device_mappings is not None: pulumi.set(__self__, "block_device_mappings", block_device_mappings) + if create_options is not None: + pulumi.set(__self__, "create_options", create_options) if elastic_ip_pools is not None: pulumi.set(__self__, "elastic_ip_pools", elastic_ip_pools) if iam_instance_profile is not None: @@ -140,6 +143,15 @@ def block_device_mappings(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[' def block_device_mappings(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecBlockDeviceMappingArgs']]]]): pulumi.set(self, "block_device_mappings", value) + @property + @pulumi.getter(name="createOptions") + def create_options(self) -> Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']]: + return pulumi.get(self, "create_options") + + @create_options.setter + def create_options(self, value: Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']]): + pulumi.set(self, "create_options", value) + @property @pulumi.getter(name="elasticIpPools") def elastic_ip_pools(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecElasticIpPoolArgs']]]]: @@ -321,6 +333,7 @@ def __init__(__self__, *, associate_public_ip_address: Optional[pulumi.Input[bool]] = None, autoscale_headrooms: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecAutoscaleHeadroomArgs']]]] = None, block_device_mappings: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecBlockDeviceMappingArgs']]]] = None, + create_options: Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']] = None, elastic_ip_pools: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecElasticIpPoolArgs']]]] = None, iam_instance_profile: Optional[pulumi.Input[str]] = None, image_id: Optional[pulumi.Input[str]] = None, @@ -363,6 +376,8 @@ def __init__(__self__, *, pulumi.set(__self__, "autoscale_headrooms", autoscale_headrooms) if block_device_mappings is not None: pulumi.set(__self__, "block_device_mappings", block_device_mappings) + if create_options is not None: + pulumi.set(__self__, "create_options", create_options) if elastic_ip_pools is not None: pulumi.set(__self__, "elastic_ip_pools", elastic_ip_pools) if iam_instance_profile is not None: @@ -432,6 +447,15 @@ def block_device_mappings(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[' def block_device_mappings(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecBlockDeviceMappingArgs']]]]): pulumi.set(self, "block_device_mappings", value) + @property + @pulumi.getter(name="createOptions") + def create_options(self) -> Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']]: + return pulumi.get(self, "create_options") + + @create_options.setter + def create_options(self, value: Optional[pulumi.Input['OceanLaunchSpecCreateOptionsArgs']]): + pulumi.set(self, "create_options", value) + @property @pulumi.getter(name="elasticIpPools") def elastic_ip_pools(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['OceanLaunchSpecElasticIpPoolArgs']]]]: @@ -627,6 +651,7 @@ def __init__(__self__, associate_public_ip_address: Optional[pulumi.Input[bool]] = None, autoscale_headrooms: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecAutoscaleHeadroomArgs']]]]] = None, block_device_mappings: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecBlockDeviceMappingArgs']]]]] = None, + create_options: Optional[pulumi.Input[pulumi.InputType['OceanLaunchSpecCreateOptionsArgs']]] = None, elastic_ip_pools: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecElasticIpPoolArgs']]]]] = None, iam_instance_profile: Optional[pulumi.Input[str]] = None, image_id: Optional[pulumi.Input[str]] = None, @@ -676,6 +701,9 @@ def __init__(__self__, volume_type="gp2", ), )], + create_options=spotinst.aws.OceanLaunchSpecCreateOptionsArgs( + initial_nodes=1, + ), elastic_ip_pools=[spotinst.aws.OceanLaunchSpecElasticIpPoolArgs( tag_selector=spotinst.aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs( tag_key="key", @@ -780,6 +808,9 @@ def __init__(__self__, volume_type="gp2", ), )], + create_options=spotinst.aws.OceanLaunchSpecCreateOptionsArgs( + initial_nodes=1, + ), elastic_ip_pools=[spotinst.aws.OceanLaunchSpecElasticIpPoolArgs( tag_selector=spotinst.aws.OceanLaunchSpecElasticIpPoolTagSelectorArgs( tag_key="key", @@ -844,6 +875,7 @@ def _internal_init(__self__, associate_public_ip_address: Optional[pulumi.Input[bool]] = None, autoscale_headrooms: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecAutoscaleHeadroomArgs']]]]] = None, block_device_mappings: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecBlockDeviceMappingArgs']]]]] = None, + create_options: Optional[pulumi.Input[pulumi.InputType['OceanLaunchSpecCreateOptionsArgs']]] = None, elastic_ip_pools: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecElasticIpPoolArgs']]]]] = None, iam_instance_profile: Optional[pulumi.Input[str]] = None, image_id: Optional[pulumi.Input[str]] = None, @@ -875,6 +907,7 @@ def _internal_init(__self__, __props__.__dict__["associate_public_ip_address"] = associate_public_ip_address __props__.__dict__["autoscale_headrooms"] = autoscale_headrooms __props__.__dict__["block_device_mappings"] = block_device_mappings + __props__.__dict__["create_options"] = create_options __props__.__dict__["elastic_ip_pools"] = elastic_ip_pools __props__.__dict__["iam_instance_profile"] = iam_instance_profile __props__.__dict__["image_id"] = image_id @@ -906,6 +939,7 @@ def get(resource_name: str, associate_public_ip_address: Optional[pulumi.Input[bool]] = None, autoscale_headrooms: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecAutoscaleHeadroomArgs']]]]] = None, block_device_mappings: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecBlockDeviceMappingArgs']]]]] = None, + create_options: Optional[pulumi.Input[pulumi.InputType['OceanLaunchSpecCreateOptionsArgs']]] = None, elastic_ip_pools: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['OceanLaunchSpecElasticIpPoolArgs']]]]] = None, iam_instance_profile: Optional[pulumi.Input[str]] = None, image_id: Optional[pulumi.Input[str]] = None, @@ -954,6 +988,7 @@ def get(resource_name: str, __props__.__dict__["associate_public_ip_address"] = associate_public_ip_address __props__.__dict__["autoscale_headrooms"] = autoscale_headrooms __props__.__dict__["block_device_mappings"] = block_device_mappings + __props__.__dict__["create_options"] = create_options __props__.__dict__["elastic_ip_pools"] = elastic_ip_pools __props__.__dict__["iam_instance_profile"] = iam_instance_profile __props__.__dict__["image_id"] = image_id @@ -996,6 +1031,11 @@ def block_device_mappings(self) -> pulumi.Output[Optional[Sequence['outputs.Ocea """ return pulumi.get(self, "block_device_mappings") + @property + @pulumi.getter(name="createOptions") + def create_options(self) -> pulumi.Output[Optional['outputs.OceanLaunchSpecCreateOptions']]: + return pulumi.get(self, "create_options") + @property @pulumi.getter(name="elasticIpPools") def elastic_ip_pools(self) -> pulumi.Output[Optional[Sequence['outputs.OceanLaunchSpecElasticIpPool']]]: diff --git a/sdk/python/pulumi_spotinst/aws/outputs.py b/sdk/python/pulumi_spotinst/aws/outputs.py index 216bb968..06d08638 100644 --- a/sdk/python/pulumi_spotinst/aws/outputs.py +++ b/sdk/python/pulumi_spotinst/aws/outputs.py @@ -104,6 +104,7 @@ 'OceanLaunchSpecBlockDeviceMapping', 'OceanLaunchSpecBlockDeviceMappingEbs', 'OceanLaunchSpecBlockDeviceMappingEbsDynamicVolumeSize', + 'OceanLaunchSpecCreateOptions', 'OceanLaunchSpecElasticIpPool', 'OceanLaunchSpecElasticIpPoolTagSelector', 'OceanLaunchSpecLabel', @@ -7461,6 +7462,41 @@ def size_per_resource_unit(self) -> int: return pulumi.get(self, "size_per_resource_unit") +@pulumi.output_type +class OceanLaunchSpecCreateOptions(dict): + @staticmethod + def __key_warning(key: str): + suggest = None + if key == "initialNodes": + suggest = "initial_nodes" + + if suggest: + pulumi.log.warn(f"Key '{key}' not found in OceanLaunchSpecCreateOptions. Access the value via the '{suggest}' property getter instead.") + + def __getitem__(self, key: str) -> Any: + OceanLaunchSpecCreateOptions.__key_warning(key) + return super().__getitem__(key) + + def get(self, key: str, default = None) -> Any: + OceanLaunchSpecCreateOptions.__key_warning(key) + return super().get(key, default) + + def __init__(__self__, *, + initial_nodes: int): + """ + :param int initial_nodes: When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + """ + pulumi.set(__self__, "initial_nodes", initial_nodes) + + @property + @pulumi.getter(name="initialNodes") + def initial_nodes(self) -> int: + """ + When set to an integer greater than 0, a corresponding amount of nodes will be launched from the created virtual node group. + """ + return pulumi.get(self, "initial_nodes") + + @pulumi.output_type class OceanLaunchSpecElasticIpPool(dict): @staticmethod