Creates a resilience policy that defines availability and disaster recovery requirements.
Create Policy Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
@overload
def Policy(resource_name: str,
args: Optional[PolicyArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Policy(resource_name: str,
opts: Optional[ResourceOptions] = None,
availability_slo: Optional[PolicyAvailabilitySloArgs] = None,
data_recovery: Optional[PolicyDataRecoveryTargetsArgs] = None,
description: Optional[str] = None,
kms_key_id: Optional[str] = None,
multi_az: Optional[PolicyMultiAzTargetsArgs] = None,
multi_region: Optional[PolicyMultiRegionTargetsArgs] = None,
name: Optional[str] = None,
sharing_enabled: Optional[bool] = None,
tags: Optional[Sequence[_root_inputs.TagArgs]] = None)
public Policy(String name, PolicyArgs args)
public Policy(String name, PolicyArgs args, CustomResourceOptions options)
type: aws-native:resiliencehubv2:Policy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "aws-native_resiliencehubv2_policy" "name" {
# resource properties
}
Parameters
- name
string
- The unique name of the resource.
- args
PolicyArgs
- The arguments to resource properties.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name
str
- The unique name of the resource.
- args
PolicyArgs
- The arguments to resource properties.
- opts
ResourceOptions
- Bag of options to control resource's behavior.
- ctx
Context
- Context object for the current deployment.
- name
string
- The unique name of the resource.
- args
PolicyArgs
- The arguments to resource properties.
- opts
ResourceOption
- Bag of options to control resource's behavior.
- name
string
- The unique name of the resource.
- args
PolicyArgs
- The arguments to resource properties.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- name
String
- The unique name of the resource.
- args
PolicyArgs
- The arguments to resource properties.
- options
CustomResourceOptions
- Bag of options to control resource's behavior.
Policy Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Policy resource accepts the following input properties:
Outputs
All input properties are implicitly available as output properties. Additionally, the Policy resource produces the following output properties:
- AssociatedServiceCount
int
- The number of services associated with this policy.
- CreatedAt
string
- The timestamp when the policy was created.
- Id
string
- The provider-assigned unique ID for this managed resource.
- PolicyArn
string
- The ARN of the policy.
- UpdatedAt
string
- The timestamp when the policy was last updated.
- AssociatedServiceCount
int
- The number of services associated with this policy.
- CreatedAt
string
- The timestamp when the policy was created.
- Id
string
- The provider-assigned unique ID for this managed resource.
- PolicyArn
string
- The ARN of the policy.
- UpdatedAt
string
- The timestamp when the policy was last updated.
- associated_service_count
number
- The number of services associated with this policy.
- created_at
string
- The timestamp when the policy was created.
- id
string
- The provider-assigned unique ID for this managed resource.
- policy_arn
string
- The ARN of the policy.
- updated_at
string
- The timestamp when the policy was last updated.
- associatedServiceCount
Integer
- The number of services associated with this policy.
- createdAt
String
- The timestamp when the policy was created.
- id
String
- The provider-assigned unique ID for this managed resource.
- policyArn
String
- The ARN of the policy.
- updatedAt
String
- The timestamp when the policy was last updated.
- associatedServiceCount
number
- The number of services associated with this policy.
- createdAt
string
- The timestamp when the policy was created.
- id
string
- The provider-assigned unique ID for this managed resource.
- policyArn
string
- The ARN of the policy.
- updatedAt
string
- The timestamp when the policy was last updated.
- associated_service_count
int
- The number of services associated with this policy.
- created_at
str
- The timestamp when the policy was created.
- id
str
- The provider-assigned unique ID for this managed resource.
- policy_arn
str
- The ARN of the policy.
- updated_at
str
- The timestamp when the policy was last updated.
- associatedServiceCount
Number
- The number of services associated with this policy.
- createdAt
String
- The timestamp when the policy was created.
- id
String
- The provider-assigned unique ID for this managed resource.
- policyArn
String
- The ARN of the policy.
- updatedAt
String
- The timestamp when the policy was last updated.
Look up Existing Policy Resource
Get an existing Policy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static Policy get(String name, Output<String> id, CustomResourceOptions options)
resources: existingPolicy: type: aws-native:resiliencehubv2:Policy get: id: ${id}
import {
to = aws-native_resiliencehubv2_policy.example
id = "${id}"
}
- name
string
- The unique name of the resulting resource.
- id
Input<ID>
- The unique provider ID of the resource to look up.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name
str
- The unique name of the resulting resource.
- id
str
- The unique provider ID of the resource to look up.
- opts
ResourceOptions
- Bag of options to control resource's behavior.
- ctx
Context
- Context object for the current deployment.
- name
string
- The unique name of the resulting resource.
- id
IDInput
- The unique provider ID of the resource to look up.
- state
PolicyState
- Pass nil. This resource has no state arguments.
- opts
ResourceOption
- Bag of options to control resource's behavior.
- name
string
- The unique name of the resulting resource.
- id
Input<string>
- The unique provider ID of the resource to look up.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- name
String
- The unique name of the resulting resource.
- id
Output<String>
- The unique provider ID of the resource to look up.
- options
CustomResourceOptions
- Bag of options to control resource's behavior.
Supporting Types
PolicyAvailabilitySlo, PolicyAvailabilitySloArgs
- Target
double
- Availability target percentage.
- Target
float64
- Availability target percentage.
- target
number
- Availability target percentage.
- target
Double
- Availability target percentage.
- target
number
- Availability target percentage.
- target
float
- Availability target percentage.
- target
Number
- Availability target percentage.
PolicyDataRecoveryTargets, PolicyDataRecoveryTargetsArgs
PolicyMultiAzTargets, PolicyMultiAzTargetsArgs
PolicyMultiAzTargetsDisasterRecoveryApproach, PolicyMultiAzTargetsDisasterRecoveryApproachArgs
Multi-AZ disaster recovery approach.| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| PolicyMultiAzTargetsDisasterRecoveryApproachActiveActive | ACTIVE_ACTIVE |
| PolicyMultiAzTargetsDisasterRecoveryApproachHotStandby | HOT_STANDBY |
| PolicyMultiAzTargetsDisasterRecoveryApproachWarmStandby | WARM_STANDBY |
| PolicyMultiAzTargetsDisasterRecoveryApproachPilotLight | PILOT_LIGHT |
| PolicyMultiAzTargetsDisasterRecoveryApproachBackupAndRestore | BACKUP_AND_RESTORE |
| Value |
|---|
ACTIVE_ACTIVE |
HOT_STANDBY |
WARM_STANDBY |
PILOT_LIGHT |
BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ACTIVE_ACTIVE | ACTIVE_ACTIVE |
| HOT_STANDBY | HOT_STANDBY |
| WARM_STANDBY | WARM_STANDBY |
| PILOT_LIGHT | PILOT_LIGHT |
| BACKUP_AND_RESTORE | BACKUP_AND_RESTORE |
| Value |
|---|
ACTIVE_ACTIVE |
HOT_STANDBY |
WARM_STANDBY |
PILOT_LIGHT |
BACKUP_AND_RESTORE |
PolicyMultiRegionTargets, PolicyMultiRegionTargetsArgs
PolicyMultiRegionTargetsDisasterRecoveryApproach, PolicyMultiRegionTargetsDisasterRecoveryApproachArgs
Multi-Region disaster recovery approach.| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| PolicyMultiRegionTargetsDisasterRecoveryApproachActiveActive | ACTIVE_ACTIVE |
| PolicyMultiRegionTargetsDisasterRecoveryApproachHotStandby | HOT_STANDBY |
| PolicyMultiRegionTargetsDisasterRecoveryApproachWarmStandby | WARM_STANDBY |
| PolicyMultiRegionTargetsDisasterRecoveryApproachPilotLight | PILOT_LIGHT |
| PolicyMultiRegionTargetsDisasterRecoveryApproachBackupAndRestore | BACKUP_AND_RESTORE |
| Value |
|---|
ACTIVE_ACTIVE |
HOT_STANDBY |
WARM_STANDBY |
PILOT_LIGHT |
BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ActiveActive | ACTIVE_ACTIVE |
| HotStandby | HOT_STANDBY |
| WarmStandby | WARM_STANDBY |
| PilotLight | PILOT_LIGHT |
| BackupAndRestore | BACKUP_AND_RESTORE |
| Name | Value |
|---|
| ACTIVE_ACTIVE | ACTIVE_ACTIVE |
| HOT_STANDBY | HOT_STANDBY |
| WARM_STANDBY | WARM_STANDBY |
| PILOT_LIGHT | PILOT_LIGHT |
| BACKUP_AND_RESTORE | BACKUP_AND_RESTORE |
| Value |
|---|
ACTIVE_ACTIVE |
HOT_STANDBY |
WARM_STANDBY |
PILOT_LIGHT |
BACKUP_AND_RESTORE |
Tag, TagArgs
A set of tags to apply to the resource.- Key
string
- The key name of the tag
- Value
string
- The value of the tag
- Key
string
- The key name of the tag
- Value
string
- The value of the tag
- key
string
- The key name of the tag
- value
string
- The value of the tag
- key
String
- The key name of the tag
- value
String
- The value of the tag
- key
string
- The key name of the tag
- value
string
- The value of the tag
- key
str
- The key name of the tag
- value
str
- The value of the tag
- key
String
- The key name of the tag
- value
String
- The value of the tag
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0