pulumi_wasm_providers_aws_mini::ec2

Module capacity_reservation

source
Expand description

Provides an EC2 Capacity Reservation. This allows you to reserve capacity for your Amazon EC2 instances in a specific Availability Zone for any duration.

§Example Usage

use pulumi_wasm_rust::Output;
use pulumi_wasm_rust::{add_export, pulumi_main};
#[pulumi_main]
fn test_main() -> Result<(), Error> {
    let default = capacity_reservation::create(
        "default",
        CapacityReservationArgs::builder()
            .availability_zone("eu-west-1a")
            .instance_count(1)
            .instance_platform("Linux/UNIX")
            .instance_type("t2.micro")
            .build_struct(),
    );
}

§Import

Using pulumi import, import Capacity Reservations using the id. For example:

$ pulumi import aws:ec2/capacityReservation:CapacityReservation web cr-0123456789abcdef0

Structs§

Functions§

  • Registers a new resource with the given unique name and arguments