Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi
alicloud.ecs.getElasticityAssurances
Explore with Pulumi AI
This data source provides Ecs Elasticity Assurance available to the user.
NOTE: Available in 1.196.0+
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const default = alicloud.ecs.getElasticityAssurances({
ids: [defaultAlicloudEcsElasticityAssurance.id],
});
export const alicloudEcsElasticityAssuranceExampleId = _default.then(_default => _default.assurances?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
default = alicloud.ecs.get_elasticity_assurances(ids=[default_alicloud_ecs_elasticity_assurance["id"]])
pulumi.export("alicloudEcsElasticityAssuranceExampleId", default.assurances[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_default, err := ecs.GetElasticityAssurances(ctx, &ecs.GetElasticityAssurancesArgs{
Ids: interface{}{
defaultAlicloudEcsElasticityAssurance.Id,
},
}, nil);
if err != nil {
return err
}
ctx.Export("alicloudEcsElasticityAssuranceExampleId", _default.Assurances[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var @default = AliCloud.Ecs.GetElasticityAssurances.Invoke(new()
{
Ids = new[]
{
defaultAlicloudEcsElasticityAssurance.Id,
},
});
return new Dictionary<string, object?>
{
["alicloudEcsElasticityAssuranceExampleId"] = @default.Apply(@default => @default.Apply(getElasticityAssurancesResult => getElasticityAssurancesResult.Assurances[0]?.Id)),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ecs.EcsFunctions;
import com.pulumi.alicloud.ecs.inputs.GetElasticityAssurancesArgs;
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 default = EcsFunctions.getElasticityAssurances(GetElasticityAssurancesArgs.builder()
.ids(defaultAlicloudEcsElasticityAssurance.id())
.build());
ctx.export("alicloudEcsElasticityAssuranceExampleId", default_.assurances()[0].id());
}
}
variables:
default:
fn::invoke:
Function: alicloud:ecs:getElasticityAssurances
Arguments:
ids:
- ${defaultAlicloudEcsElasticityAssurance.id}
outputs:
alicloudEcsElasticityAssuranceExampleId: ${default.assurances[0].id}
Using getElasticityAssurances
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 getElasticityAssurances(args: GetElasticityAssurancesArgs, opts?: InvokeOptions): Promise<GetElasticityAssurancesResult>
function getElasticityAssurancesOutput(args: GetElasticityAssurancesOutputArgs, opts?: InvokeOptions): Output<GetElasticityAssurancesResult>
def get_elasticity_assurances(ids: Optional[Sequence[str]] = None,
output_file: Optional[str] = None,
private_pool_options_ids: Optional[Sequence[str]] = None,
resource_group_id: Optional[str] = None,
status: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
opts: Optional[InvokeOptions] = None) -> GetElasticityAssurancesResult
def get_elasticity_assurances_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
output_file: Optional[pulumi.Input[str]] = None,
private_pool_options_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
resource_group_id: Optional[pulumi.Input[str]] = None,
status: Optional[pulumi.Input[str]] = None,
tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetElasticityAssurancesResult]
func GetElasticityAssurances(ctx *Context, args *GetElasticityAssurancesArgs, opts ...InvokeOption) (*GetElasticityAssurancesResult, error)
func GetElasticityAssurancesOutput(ctx *Context, args *GetElasticityAssurancesOutputArgs, opts ...InvokeOption) GetElasticityAssurancesResultOutput
> Note: This function is named GetElasticityAssurances
in the Go SDK.
public static class GetElasticityAssurances
{
public static Task<GetElasticityAssurancesResult> InvokeAsync(GetElasticityAssurancesArgs args, InvokeOptions? opts = null)
public static Output<GetElasticityAssurancesResult> Invoke(GetElasticityAssurancesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetElasticityAssurancesResult> getElasticityAssurances(GetElasticityAssurancesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:ecs/getElasticityAssurances:getElasticityAssurances
arguments:
# arguments dictionary
The following arguments are supported:
- Ids List<string>
- A list of Elasticity Assurance IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Private
Pool List<string>Options Ids - The ID of the elastic protection service.
- Resource
Group stringId - The ID of the resource group.
- Status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Dictionary<string, string>
- The tag key-value pair information bound by the elastic guarantee service.
- Ids []string
- A list of Elasticity Assurance IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Private
Pool []stringOptions Ids - The ID of the elastic protection service.
- Resource
Group stringId - The ID of the resource group.
- Status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - map[string]string
- The tag key-value pair information bound by the elastic guarantee service.
- ids List<String>
- A list of Elasticity Assurance IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - private
Pool List<String>Options Ids - The ID of the elastic protection service.
- resource
Group StringId - The ID of the resource group.
- status String
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Map<String,String>
- The tag key-value pair information bound by the elastic guarantee service.
- ids string[]
- A list of Elasticity Assurance IDs.
- output
File string - File name where to save data source results (after running
pulumi preview
). - private
Pool string[]Options Ids - The ID of the elastic protection service.
- resource
Group stringId - The ID of the resource group.
- status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - {[key: string]: string}
- The tag key-value pair information bound by the elastic guarantee service.
- ids Sequence[str]
- A list of Elasticity Assurance IDs.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - private_
pool_ Sequence[str]options_ ids - The ID of the elastic protection service.
- resource_
group_ strid - The ID of the resource group.
- status str
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Mapping[str, str]
- The tag key-value pair information bound by the elastic guarantee service.
- ids List<String>
- A list of Elasticity Assurance IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - private
Pool List<String>Options Ids - The ID of the elastic protection service.
- resource
Group StringId - The ID of the resource group.
- status String
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Map<String>
- The tag key-value pair information bound by the elastic guarantee service.
getElasticityAssurances Result
The following output properties are available:
- Assurances
List<Pulumi.
Ali Cloud. Ecs. Outputs. Get Elasticity Assurances Assurance> - A list of Elasticity Assurance Entries. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- A list of Elasticity Assurance IDs.
- Output
File string - Private
Pool List<string>Options Ids - Resource
Group stringId - The ID of the resource group.
- Status string
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- Dictionary<string, string>
- A mapping of tags to assign to the Capacity Reservation.
- Assurances
[]Get
Elasticity Assurances Assurance - A list of Elasticity Assurance Entries. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- A list of Elasticity Assurance IDs.
- Output
File string - Private
Pool []stringOptions Ids - Resource
Group stringId - The ID of the resource group.
- Status string
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- map[string]string
- A mapping of tags to assign to the Capacity Reservation.
- assurances
List<Get
Elasticity Assurances Assurance> - A list of Elasticity Assurance Entries. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of Elasticity Assurance IDs.
- output
File String - private
Pool List<String>Options Ids - resource
Group StringId - The ID of the resource group.
- status String
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- Map<String,String>
- A mapping of tags to assign to the Capacity Reservation.
- assurances
Get
Elasticity Assurances Assurance[] - A list of Elasticity Assurance Entries. Each element contains the following attributes:
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- A list of Elasticity Assurance IDs.
- output
File string - private
Pool string[]Options Ids - resource
Group stringId - The ID of the resource group.
- status string
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- {[key: string]: string}
- A mapping of tags to assign to the Capacity Reservation.
- assurances
Sequence[Get
Elasticity Assurances Assurance] - A list of Elasticity Assurance Entries. Each element contains the following attributes:
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- A list of Elasticity Assurance IDs.
- output_
file str - private_
pool_ Sequence[str]options_ ids - resource_
group_ strid - The ID of the resource group.
- status str
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- Mapping[str, str]
- A mapping of tags to assign to the Capacity Reservation.
- assurances List<Property Map>
- A list of Elasticity Assurance Entries. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of Elasticity Assurance IDs.
- output
File String - private
Pool List<String>Options Ids - resource
Group StringId - The ID of the resource group.
- status String
- The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
- Map<String>
- A mapping of tags to assign to the Capacity Reservation.
Supporting Types
GetElasticityAssurancesAssurance
- Allocated
Resources List<Pulumi.Ali Cloud. Ecs. Inputs. Get Elasticity Assurances Assurance Allocated Resource> - Details of resource allocation.
- Description string
- Description of flexible guarantee service.
- Elasticity
Assurance stringId - The first ID of the resource
- End
Time string - Flexible guarantee service failure time.
- Id string
- ID of flexible guarantee service.
- Instance
Charge stringType - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- Private
Pool stringOptions Id - The ID of the elasticity assurance.
- Private
Pool stringOptions Match Criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- Private
Pool stringOptions Name - The name of the elasticity assurance.
- Resource
Group stringId - The ID of the resource group.
- Start
Time string - Flexible guarantee service effective time.
- Start
Time stringType - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- Status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Total
Assurance stringTimes - The total number of flexible guarantee services.
- Used
Assurance intTimes - This parameter is not yet available.
- Dictionary<string, string>
- The tag key-value pair information bound by the elastic guarantee service.
- Allocated
Resources []GetElasticity Assurances Assurance Allocated Resource - Details of resource allocation.
- Description string
- Description of flexible guarantee service.
- Elasticity
Assurance stringId - The first ID of the resource
- End
Time string - Flexible guarantee service failure time.
- Id string
- ID of flexible guarantee service.
- Instance
Charge stringType - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- Private
Pool stringOptions Id - The ID of the elasticity assurance.
- Private
Pool stringOptions Match Criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- Private
Pool stringOptions Name - The name of the elasticity assurance.
- Resource
Group stringId - The ID of the resource group.
- Start
Time string - Flexible guarantee service effective time.
- Start
Time stringType - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- Status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - Total
Assurance stringTimes - The total number of flexible guarantee services.
- Used
Assurance intTimes - This parameter is not yet available.
- map[string]string
- The tag key-value pair information bound by the elastic guarantee service.
- allocated
Resources List<GetElasticity Assurances Assurance Allocated Resource> - Details of resource allocation.
- description String
- Description of flexible guarantee service.
- elasticity
Assurance StringId - The first ID of the resource
- end
Time String - Flexible guarantee service failure time.
- id String
- ID of flexible guarantee service.
- instance
Charge StringType - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- private
Pool StringOptions Id - The ID of the elasticity assurance.
- private
Pool StringOptions Match Criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- private
Pool StringOptions Name - The name of the elasticity assurance.
- resource
Group StringId - The ID of the resource group.
- start
Time String - Flexible guarantee service effective time.
- start
Time StringType - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- status String
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - total
Assurance StringTimes - The total number of flexible guarantee services.
- used
Assurance IntegerTimes - This parameter is not yet available.
- Map<String,String>
- The tag key-value pair information bound by the elastic guarantee service.
- allocated
Resources GetElasticity Assurances Assurance Allocated Resource[] - Details of resource allocation.
- description string
- Description of flexible guarantee service.
- elasticity
Assurance stringId - The first ID of the resource
- end
Time string - Flexible guarantee service failure time.
- id string
- ID of flexible guarantee service.
- instance
Charge stringType - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- private
Pool stringOptions Id - The ID of the elasticity assurance.
- private
Pool stringOptions Match Criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- private
Pool stringOptions Name - The name of the elasticity assurance.
- resource
Group stringId - The ID of the resource group.
- start
Time string - Flexible guarantee service effective time.
- start
Time stringType - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- status string
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - total
Assurance stringTimes - The total number of flexible guarantee services.
- used
Assurance numberTimes - This parameter is not yet available.
- {[key: string]: string}
- The tag key-value pair information bound by the elastic guarantee service.
- allocated_
resources Sequence[GetElasticity Assurances Assurance Allocated Resource] - Details of resource allocation.
- description str
- Description of flexible guarantee service.
- elasticity_
assurance_ strid - The first ID of the resource
- end_
time str - Flexible guarantee service failure time.
- id str
- ID of flexible guarantee service.
- instance_
charge_ strtype - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- private_
pool_ stroptions_ id - The ID of the elasticity assurance.
- private_
pool_ stroptions_ match_ criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- private_
pool_ stroptions_ name - The name of the elasticity assurance.
- resource_
group_ strid - The ID of the resource group.
- start_
time str - Flexible guarantee service effective time.
- start_
time_ strtype - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- status str
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - total_
assurance_ strtimes - The total number of flexible guarantee services.
- used_
assurance_ inttimes - This parameter is not yet available.
- Mapping[str, str]
- The tag key-value pair information bound by the elastic guarantee service.
- allocated
Resources List<Property Map> - Details of resource allocation.
- description String
- Description of flexible guarantee service.
- elasticity
Assurance StringId - The first ID of the resource
- end
Time String - Flexible guarantee service failure time.
- id String
- ID of flexible guarantee service.
- instance
Charge StringType - The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
- private
Pool StringOptions Id - The ID of the elasticity assurance.
- private
Pool StringOptions Match Criteria - The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
- private
Pool StringOptions Name - The name of the elasticity assurance.
- resource
Group StringId - The ID of the resource group.
- start
Time String - Flexible guarantee service effective time.
- start
Time StringType - Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
- status String
- The status of flexible guarantee services. Possible values:
All
,Preparing
,Prepared
,Active
,Released
. - total
Assurance StringTimes - The total number of flexible guarantee services.
- used
Assurance NumberTimes - This parameter is not yet available.
- Map<String>
- The tag key-value pair information bound by the elastic guarantee service.
GetElasticityAssurancesAssuranceAllocatedResource
- Instance
Type string - Instance type.
- Total
Amount int - The total number of instances that need to be reserved within an instance type.
- Used
Amount int - The number of instances that have been used.
- Zone
Id string - The zone ID.
- Instance
Type string - Instance type.
- Total
Amount int - The total number of instances that need to be reserved within an instance type.
- Used
Amount int - The number of instances that have been used.
- Zone
Id string - The zone ID.
- instance
Type String - Instance type.
- total
Amount Integer - The total number of instances that need to be reserved within an instance type.
- used
Amount Integer - The number of instances that have been used.
- zone
Id String - The zone ID.
- instance
Type string - Instance type.
- total
Amount number - The total number of instances that need to be reserved within an instance type.
- used
Amount number - The number of instances that have been used.
- zone
Id string - The zone ID.
- instance_
type str - Instance type.
- total_
amount int - The total number of instances that need to be reserved within an instance type.
- used_
amount int - The number of instances that have been used.
- zone_
id str - The zone ID.
- instance
Type String - Instance type.
- total
Amount Number - The total number of instances that need to be reserved within an instance type.
- used
Amount Number - The number of instances that have been used.
- zone
Id String - The zone ID.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.