import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages an AWS Application Recovery Controller Zonal Shift Zonal Autoshift Configuration for a managed resource (such as a load balancer). * * Zonal autoshift is a capability in AWS Application Recovery Controller (ARC) that automatically shifts traffic away from an Availability Zone when AWS identifies a potential issue, helping maintain application availability. * * ## Example Usage * * ### Basic Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const exampleLoadBalancer = new aws.lb.LoadBalancer("example", { * name: "example", * internal: true, * loadBalancerType: "application", * subnets: exampleAwsSubnet.map(__item => __item.id), * enableZonalShift: true, * }); * const exampleMetricAlarm = new aws.cloudwatch.MetricAlarm("example", { * name: "example-outcome-alarm", * comparisonOperator: "GreaterThanOrEqualToThreshold", * evaluationPeriods: 1, * metricName: "TargetResponseTime", * namespace: "AWS/ApplicationELB", * period: 60, * statistic: "Average", * threshold: 1, * alarmDescription: "Outcome alarm for zonal autoshift practice run", * dimensions: { * LoadBalancer: exampleLoadBalancer.arnSuffix, * }, * }); * const example = new aws.arczonalshift.ZonalAutoshiftConfiguration("example", { * outcomeAlarms: [{ * alarmIdentifier: exampleMetricAlarm.arn, * type: "CLOUDWATCH", * }], * resourceArn: exampleLoadBalancer.arn, * zonalAutoshiftStatus: "ENABLED", * }); * ``` * * ### With Blocking Alarms * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.arczonalshift.ZonalAutoshiftConfiguration("example", { * blockingAlarms: [{ * alarmIdentifier: blocking.arn, * type: "CLOUDWATCH", * }], * outcomeAlarms: [{ * alarmIdentifier: outcome.arn, * type: "CLOUDWATCH", * }], * resourceArn: exampleAwsLb.arn, * zonalAutoshiftStatus: "ENABLED", * }); * ``` * * ### With Blocked Windows * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.arczonalshift.ZonalAutoshiftConfiguration("example", { * outcomeAlarms: [{ * alarmIdentifier: exampleAwsCloudwatchMetricAlarm.arn, * type: "CLOUDWATCH", * }], * resourceArn: exampleAwsLb.arn, * zonalAutoshiftStatus: "ENABLED", * blockedWindows: ["Mon:00:00-Mon:08:00"], * }); * ``` * * ## Import * * ### Identity Schema * * #### Required * * * `resourceArn` (String) ARN of the managed resource to configure zonal autoshift for. * * Using `pulumi import`, import ARC Zonal Shift Zonal Autoshift Configuration using the `resourceArn`. For example: * * ```sh * $ pulumi import aws:arczonalshift/zonalAutoshiftConfiguration:ZonalAutoshiftConfiguration example arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/example/50dc6c495c0c9188 * ``` */ export declare class ZonalAutoshiftConfiguration extends pulumi.CustomResource { /** * Get an existing ZonalAutoshiftConfiguration resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: ZonalAutoshiftConfigurationState, opts?: pulumi.CustomResourceOptions): ZonalAutoshiftConfiguration; /** * Returns true if the given object is an instance of ZonalAutoshiftConfiguration. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is ZonalAutoshiftConfiguration; /** * List of time windows during which practice runs are allowed, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:09:00-Mon:17:00`). Cannot be used together with `blockedWindows`. */ readonly allowedWindows: pulumi.Output; /** * List of dates when practice runs should not be started, in the format `YYYY-MM-DD`. */ readonly blockedDates: pulumi.Output; /** * List of time windows during which practice runs should not be started, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:00:00-Mon:08:00`). Cannot be used together with `allowedWindows`. */ readonly blockedWindows: pulumi.Output; /** * List of CloudWatch alarms that can block practice runs when in alarm state. See `blockingAlarms` below. */ readonly blockingAlarms: pulumi.Output; /** * List of CloudWatch alarms monitored during practice runs. See `outcomeAlarms` below. */ readonly outcomeAlarms: pulumi.Output; /** * AWS region where the resource is deployed. */ readonly region: pulumi.Output; /** * The ARN of the managed resource to configure zonal autoshift for (e.g., an Application Load Balancer). Changing this creates a new resource. */ readonly resourceArn: pulumi.Output; /** * The status of zonal autoshift. Valid values: `ENABLED`, `DISABLED`. * * The following arguments are optional: */ readonly zonalAutoshiftStatus: pulumi.Output; /** * Create a ZonalAutoshiftConfiguration resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: ZonalAutoshiftConfigurationArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering ZonalAutoshiftConfiguration resources. */ export interface ZonalAutoshiftConfigurationState { /** * List of time windows during which practice runs are allowed, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:09:00-Mon:17:00`). Cannot be used together with `blockedWindows`. */ allowedWindows?: pulumi.Input[] | undefined>; /** * List of dates when practice runs should not be started, in the format `YYYY-MM-DD`. */ blockedDates?: pulumi.Input[] | undefined>; /** * List of time windows during which practice runs should not be started, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:00:00-Mon:08:00`). Cannot be used together with `allowedWindows`. */ blockedWindows?: pulumi.Input[] | undefined>; /** * List of CloudWatch alarms that can block practice runs when in alarm state. See `blockingAlarms` below. */ blockingAlarms?: pulumi.Input[] | undefined>; /** * List of CloudWatch alarms monitored during practice runs. See `outcomeAlarms` below. */ outcomeAlarms?: pulumi.Input[] | undefined>; /** * AWS region where the resource is deployed. */ region?: pulumi.Input; /** * The ARN of the managed resource to configure zonal autoshift for (e.g., an Application Load Balancer). Changing this creates a new resource. */ resourceArn?: pulumi.Input; /** * The status of zonal autoshift. Valid values: `ENABLED`, `DISABLED`. * * The following arguments are optional: */ zonalAutoshiftStatus?: pulumi.Input; } /** * The set of arguments for constructing a ZonalAutoshiftConfiguration resource. */ export interface ZonalAutoshiftConfigurationArgs { /** * List of time windows during which practice runs are allowed, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:09:00-Mon:17:00`). Cannot be used together with `blockedWindows`. */ allowedWindows?: pulumi.Input[] | undefined>; /** * List of dates when practice runs should not be started, in the format `YYYY-MM-DD`. */ blockedDates?: pulumi.Input[] | undefined>; /** * List of time windows during which practice runs should not be started, in the format `Day:HH:MM-Day:HH:MM` (e.g., `Mon:00:00-Mon:08:00`). Cannot be used together with `allowedWindows`. */ blockedWindows?: pulumi.Input[] | undefined>; /** * List of CloudWatch alarms that can block practice runs when in alarm state. See `blockingAlarms` below. */ blockingAlarms?: pulumi.Input[] | undefined>; /** * List of CloudWatch alarms monitored during practice runs. See `outcomeAlarms` below. */ outcomeAlarms?: pulumi.Input[] | undefined>; /** * AWS region where the resource is deployed. */ region?: pulumi.Input; /** * The ARN of the managed resource to configure zonal autoshift for (e.g., an Application Load Balancer). Changing this creates a new resource. */ resourceArn: pulumi.Input; /** * The status of zonal autoshift. Valid values: `ENABLED`, `DISABLED`. * * The following arguments are optional: */ zonalAutoshiftStatus: pulumi.Input; } //# sourceMappingURL=zonalAutoshiftConfiguration.d.ts.map