1. Packages
  2. Volcengine
  3. API Docs
  4. ecs
  5. AvailableResources
Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine

volcengine.ecs.AvailableResources

Explore with Pulumi AI

Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine

Use this data source to query detailed information of ecs available resources

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";

const foo = volcengine.ecs.AvailableResources({
    destinationResource: "InstanceType",
});
Copy
import pulumi
import pulumi_volcengine as volcengine

foo = volcengine.ecs.available_resources(destination_resource="InstanceType")
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ecs.AvailableResources(ctx, &ecs.AvailableResourcesArgs{
			DestinationResource: "InstanceType",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;

return await Deployment.RunAsync(() => 
{
    var foo = Volcengine.Ecs.AvailableResources.Invoke(new()
    {
        DestinationResource = "InstanceType",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.ecs.EcsFunctions;
import com.pulumi.volcengine.ecs.inputs.AvailableResourcesArgs;
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) {
        final var foo = EcsFunctions.AvailableResources(AvailableResourcesArgs.builder()
            .destinationResource("InstanceType")
            .build());

    }
}
Copy
variables:
  foo:
    fn::invoke:
      Function: volcengine:ecs:AvailableResources
      Arguments:
        destinationResource: InstanceType
Copy

Using AvailableResources

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function availableResources(args: AvailableResourcesArgs, opts?: InvokeOptions): Promise<AvailableResourcesResult>
function availableResourcesOutput(args: AvailableResourcesOutputArgs, opts?: InvokeOptions): Output<AvailableResourcesResult>
Copy
def available_resources(destination_resource: Optional[str] = None,
                        instance_charge_type: Optional[str] = None,
                        instance_type_id: Optional[str] = None,
                        output_file: Optional[str] = None,
                        spot_strategy: Optional[str] = None,
                        zone_id: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> AvailableResourcesResult
def available_resources_output(destination_resource: Optional[pulumi.Input[str]] = None,
                        instance_charge_type: Optional[pulumi.Input[str]] = None,
                        instance_type_id: Optional[pulumi.Input[str]] = None,
                        output_file: Optional[pulumi.Input[str]] = None,
                        spot_strategy: Optional[pulumi.Input[str]] = None,
                        zone_id: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[AvailableResourcesResult]
Copy
func AvailableResources(ctx *Context, args *AvailableResourcesArgs, opts ...InvokeOption) (*AvailableResourcesResult, error)
func AvailableResourcesOutput(ctx *Context, args *AvailableResourcesOutputArgs, opts ...InvokeOption) AvailableResourcesResultOutput
Copy
public static class AvailableResources 
{
    public static Task<AvailableResourcesResult> InvokeAsync(AvailableResourcesArgs args, InvokeOptions? opts = null)
    public static Output<AvailableResourcesResult> Invoke(AvailableResourcesInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<AvailableResourcesResult> availableResources(AvailableResourcesArgs args, InvokeOptions options)
public static Output<AvailableResourcesResult> availableResources(AvailableResourcesArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: volcengine:ecs:AvailableResources
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

DestinationResource This property is required. string
The type of resource to query. Valid values: InstanceType, DedicatedHost.
InstanceChargeType string
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
InstanceTypeId string
The id of instance type.
OutputFile string
File name where to save data source results.
SpotStrategy string
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
ZoneId string
The id of available zone.
DestinationResource This property is required. string
The type of resource to query. Valid values: InstanceType, DedicatedHost.
InstanceChargeType string
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
InstanceTypeId string
The id of instance type.
OutputFile string
File name where to save data source results.
SpotStrategy string
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
ZoneId string
The id of available zone.
destinationResource This property is required. String
The type of resource to query. Valid values: InstanceType, DedicatedHost.
instanceChargeType String
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
instanceTypeId String
The id of instance type.
outputFile String
File name where to save data source results.
spotStrategy String
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
zoneId String
The id of available zone.
destinationResource This property is required. string
The type of resource to query. Valid values: InstanceType, DedicatedHost.
instanceChargeType string
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
instanceTypeId string
The id of instance type.
outputFile string
File name where to save data source results.
spotStrategy string
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
zoneId string
The id of available zone.
destination_resource This property is required. str
The type of resource to query. Valid values: InstanceType, DedicatedHost.
instance_charge_type str
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
instance_type_id str
The id of instance type.
output_file str
File name where to save data source results.
spot_strategy str
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
zone_id str
The id of available zone.
destinationResource This property is required. String
The type of resource to query. Valid values: InstanceType, DedicatedHost.
instanceChargeType String
The charge type of instance. Valid values: PostPaid, PrePaid, ReservedInstance. Default is PostPaid.
instanceTypeId String
The id of instance type.
outputFile String
File name where to save data source results.
spotStrategy String
The spot strategy of PostPaid instance. Valid values: NoSpot, SpotAsPriceGo. Default is NoSpot.
zoneId String
The id of available zone.

AvailableResources Result

The following output properties are available:

AvailableZones List<AvailableResourcesAvailableZone>
The collection of query.
DestinationResource string
Id string
The provider-assigned unique ID for this managed resource.
TotalCount int
The total count of query.
InstanceChargeType string
InstanceTypeId string
OutputFile string
SpotStrategy string
ZoneId string
The id of the available zone.
AvailableZones []AvailableResourcesAvailableZone
The collection of query.
DestinationResource string
Id string
The provider-assigned unique ID for this managed resource.
TotalCount int
The total count of query.
InstanceChargeType string
InstanceTypeId string
OutputFile string
SpotStrategy string
ZoneId string
The id of the available zone.
availableZones List<AvailableResourcesAvailableZone>
The collection of query.
destinationResource String
id String
The provider-assigned unique ID for this managed resource.
totalCount Integer
The total count of query.
instanceChargeType String
instanceTypeId String
outputFile String
spotStrategy String
zoneId String
The id of the available zone.
availableZones AvailableResourcesAvailableZone[]
The collection of query.
destinationResource string
id string
The provider-assigned unique ID for this managed resource.
totalCount number
The total count of query.
instanceChargeType string
instanceTypeId string
outputFile string
spotStrategy string
zoneId string
The id of the available zone.
available_zones Sequence[AvailableResourcesAvailableZone]
The collection of query.
destination_resource str
id str
The provider-assigned unique ID for this managed resource.
total_count int
The total count of query.
instance_charge_type str
instance_type_id str
output_file str
spot_strategy str
zone_id str
The id of the available zone.
availableZones List<Property Map>
The collection of query.
destinationResource String
id String
The provider-assigned unique ID for this managed resource.
totalCount Number
The total count of query.
instanceChargeType String
instanceTypeId String
outputFile String
spotStrategy String
zoneId String
The id of the available zone.

Supporting Types

AvailableResourcesAvailableZone

AvailableResources This property is required. List<AvailableResourcesAvailableZoneAvailableResource>
The resource information of the available zone.
RegionId This property is required. string
The id of the region.
Status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
ZoneId This property is required. string
The id of available zone.
AvailableResources This property is required. []AvailableResourcesAvailableZoneAvailableResource
The resource information of the available zone.
RegionId This property is required. string
The id of the region.
Status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
ZoneId This property is required. string
The id of available zone.
availableResources This property is required. List<AvailableResourcesAvailableZoneAvailableResource>
The resource information of the available zone.
regionId This property is required. String
The id of the region.
status This property is required. String
The resource status of the available zone. Valid values: Available, SoldOut.
zoneId This property is required. String
The id of available zone.
availableResources This property is required. AvailableResourcesAvailableZoneAvailableResource[]
The resource information of the available zone.
regionId This property is required. string
The id of the region.
status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
zoneId This property is required. string
The id of available zone.
available_resources This property is required. Sequence[AvailableResourcesAvailableZoneAvailableResource]
The resource information of the available zone.
region_id This property is required. str
The id of the region.
status This property is required. str
The resource status of the available zone. Valid values: Available, SoldOut.
zone_id This property is required. str
The id of available zone.
availableResources This property is required. List<Property Map>
The resource information of the available zone.
regionId This property is required. String
The id of the region.
status This property is required. String
The resource status of the available zone. Valid values: Available, SoldOut.
zoneId This property is required. String
The id of available zone.

AvailableResourcesAvailableZoneAvailableResource

SupportedResources This property is required. List<AvailableResourcesAvailableZoneAvailableResourceSupportedResource>
The supported resource information.
Type This property is required. string
The type of resource. Valid values: InstanceType, DedicatedHost.
SupportedResources This property is required. []AvailableResourcesAvailableZoneAvailableResourceSupportedResource
The supported resource information.
Type This property is required. string
The type of resource. Valid values: InstanceType, DedicatedHost.
supportedResources This property is required. List<AvailableResourcesAvailableZoneAvailableResourceSupportedResource>
The supported resource information.
type This property is required. String
The type of resource. Valid values: InstanceType, DedicatedHost.
supportedResources This property is required. AvailableResourcesAvailableZoneAvailableResourceSupportedResource[]
The supported resource information.
type This property is required. string
The type of resource. Valid values: InstanceType, DedicatedHost.
supported_resources This property is required. Sequence[AvailableResourcesAvailableZoneAvailableResourceSupportedResource]
The supported resource information.
type This property is required. str
The type of resource. Valid values: InstanceType, DedicatedHost.
supportedResources This property is required. List<Property Map>
The supported resource information.
type This property is required. String
The type of resource. Valid values: InstanceType, DedicatedHost.

AvailableResourcesAvailableZoneAvailableResourceSupportedResource

Status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
Value This property is required. string
The value of the resource.
Status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
Value This property is required. string
The value of the resource.
status This property is required. String
The resource status of the available zone. Valid values: Available, SoldOut.
value This property is required. String
The value of the resource.
status This property is required. string
The resource status of the available zone. Valid values: Available, SoldOut.
value This property is required. string
The value of the resource.
status This property is required. str
The resource status of the available zone. Valid values: Available, SoldOut.
value This property is required. str
The value of the resource.
status This property is required. String
The resource status of the available zone. Valid values: Available, SoldOut.
value This property is required. String
The value of the resource.

Package Details

Repository
volcengine volcengine/pulumi-volcengine
License
Apache-2.0
Notes
This Pulumi package is based on the volcengine Terraform Provider.
Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine