CfnLayerMixinProps
- class aws_cdk.mixins_preview.aws_opsworks.mixins.CfnLayerMixinProps(*, attributes=None, auto_assign_elastic_ips=None, auto_assign_public_ips=None, custom_instance_profile_arn=None, custom_json=None, custom_recipes=None, custom_security_group_ids=None, enable_auto_healing=None, install_updates_on_boot=None, lifecycle_event_configuration=None, load_based_auto_scaling=None, name=None, packages=None, shortname=None, stack_id=None, tags=None, type=None, use_ebs_optimized_instances=None, volume_configurations=None)
Bases:
objectProperties for CfnLayerPropsMixin.
- Parameters:
attributes (
Union[Mapping[str,str],IResolvable,None]) – One or more user-defined key-value pairs to be added to the stack attributes. To create a cluster layer, set theEcsClusterArnattribute to the cluster’s ARN.auto_assign_elastic_ips (
Union[bool,IResolvable,None]) – Whether to automatically assign an Elastic IP address to the layer’s instances. For more information, see How to Edit a Layer .auto_assign_public_ips (
Union[bool,IResolvable,None]) –For stacks that are running in a VPC, whether to automatically assign a public IP address to the layer’s instances. For more information, see How to Edit a Layer .
custom_instance_profile_arn (
Optional[str]) – The ARN of an IAM profile to be used for the layer’s EC2 instances. For more information about IAM ARNs, see Using Identifiers .custom_json (
Any) – A JSON-formatted string containing custom stack configuration and deployment attributes to be installed on the layer’s instances. For more information, see Using Custom JSON . This feature is supported as of version 1.7.42 of the AWS CLI .custom_recipes (
Union[IResolvable,RecipesProperty,Dict[str,Any],None]) – ALayerCustomRecipesobject that specifies the layer custom recipes.custom_security_group_ids (
Optional[Sequence[str]]) – An array containing the layer custom security group IDs.enable_auto_healing (
Union[bool,IResolvable,None]) – Whether to disable auto healing for the layer.install_updates_on_boot (
Union[bool,IResolvable,None]) – Whether to install operating system and package updates when the instance boots. The default value istrue. To control when updates are installed, set this value tofalse. You must then update your instances manually by usingCreateDeploymentto run theupdate_dependenciesstack command or by manually runningyum(Amazon Linux) orapt-get(Ubuntu) on the instances. .. epigraph:: To ensure that your instances have the latest security updates, we strongly recommend using the default value oftrue.lifecycle_event_configuration (
Union[IResolvable,LifecycleEventConfigurationProperty,Dict[str,Any],None]) – ALifeCycleEventConfigurationobject that you can use to configure the Shutdown event to specify an execution timeout and enable or disable Elastic Load Balancer connection draining.load_based_auto_scaling (
Union[IResolvable,LoadBasedAutoScalingProperty,Dict[str,Any],None]) – The load-based scaling configuration for the OpsWorks layer.name (
Optional[str]) – The layer name, which is used by the console. Layer names can be a maximum of 32 characters.packages (
Optional[Sequence[str]]) – An array ofPackageobjects that describes the layer packages.shortname (
Optional[str]) – For custom layers only, use this parameter to specify the layer’s short name, which is used internally by OpsWorks Stacks and by Chef recipes. The short name is also used as the name for the directory where your app files are installed. It can have a maximum of 32 characters, which are limited to the alphanumeric characters, ‘-’, ‘_’, and ‘.’. Built-in layer short names are defined by OpsWorks Stacks. For more information, see the Layer Reference .stack_id (
Optional[str]) – The layer stack ID.tags (
Optional[Sequence[Union[CfnTag,Dict[str,Any]]]]) – Specifies one or more sets of tags (key–value pairs) to associate with this OpsWorks layer. Use tags to manage your resources.type (
Optional[str]) – The layer type. A stack cannot have more than one built-in layer of the same type. It can have any number of custom layers. Built-in layers are not available in Chef 12 stacks.use_ebs_optimized_instances (
Union[bool,IResolvable,None]) – Whether to use Amazon EBS-optimized instances.volume_configurations (
Union[IResolvable,Sequence[Union[IResolvable,VolumeConfigurationProperty,Dict[str,Any]]],None]) – AVolumeConfigurationsobject that describes the layer’s Amazon EBS volumes.
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-opsworks-layer.html
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_opsworks import mixins as opsworks_mixins # custom_json: Any cfn_layer_mixin_props = opsworks_mixins.CfnLayerMixinProps( attributes={ "attributes_key": "attributes" }, auto_assign_elastic_ips=False, auto_assign_public_ips=False, custom_instance_profile_arn="customInstanceProfileArn", custom_json=custom_json, custom_recipes=opsworks_mixins.CfnLayerPropsMixin.RecipesProperty( configure=["configure"], deploy=["deploy"], setup=["setup"], shutdown=["shutdown"], undeploy=["undeploy"] ), custom_security_group_ids=["customSecurityGroupIds"], enable_auto_healing=False, install_updates_on_boot=False, lifecycle_event_configuration=opsworks_mixins.CfnLayerPropsMixin.LifecycleEventConfigurationProperty( shutdown_event_configuration=opsworks_mixins.CfnLayerPropsMixin.ShutdownEventConfigurationProperty( delay_until_elb_connections_drained=False, execution_timeout=123 ) ), load_based_auto_scaling=opsworks_mixins.CfnLayerPropsMixin.LoadBasedAutoScalingProperty( down_scaling=opsworks_mixins.CfnLayerPropsMixin.AutoScalingThresholdsProperty( cpu_threshold=123, ignore_metrics_time=123, instance_count=123, load_threshold=123, memory_threshold=123, thresholds_wait_time=123 ), enable=False, up_scaling=opsworks_mixins.CfnLayerPropsMixin.AutoScalingThresholdsProperty( cpu_threshold=123, ignore_metrics_time=123, instance_count=123, load_threshold=123, memory_threshold=123, thresholds_wait_time=123 ) ), name="name", packages=["packages"], shortname="shortname", stack_id="stackId", tags=[CfnTag( key="key", value="value" )], type="type", use_ebs_optimized_instances=False, volume_configurations=[opsworks_mixins.CfnLayerPropsMixin.VolumeConfigurationProperty( encrypted=False, iops=123, mount_point="mountPoint", number_of_disks=123, raid_level=123, size=123, volume_type="volumeType" )] )
Attributes
- attributes
One or more user-defined key-value pairs to be added to the stack attributes.
To create a cluster layer, set the
EcsClusterArnattribute to the cluster’s ARN.
- auto_assign_elastic_ips
Whether to automatically assign an Elastic IP address to the layer’s instances. For more information, see How to Edit a Layer .
- auto_assign_public_ips
For stacks that are running in a VPC, whether to automatically assign a public IP address to the layer’s instances.
For more information, see How to Edit a Layer .
- custom_instance_profile_arn
The ARN of an IAM profile to be used for the layer’s EC2 instances.
For more information about IAM ARNs, see Using Identifiers .
- custom_json
A JSON-formatted string containing custom stack configuration and deployment attributes to be installed on the layer’s instances.
For more information, see Using Custom JSON . This feature is supported as of version 1.7.42 of the AWS CLI .
- custom_recipes
A
LayerCustomRecipesobject that specifies the layer custom recipes.
- custom_security_group_ids
An array containing the layer custom security group IDs.
- enable_auto_healing
Whether to disable auto healing for the layer.
- install_updates_on_boot
Whether to install operating system and package updates when the instance boots.
The default value is
true. To control when updates are installed, set this value tofalse. You must then update your instances manually by usingCreateDeploymentto run theupdate_dependenciesstack command or by manually runningyum(Amazon Linux) orapt-get(Ubuntu) on the instances. .. epigraph:To ensure that your instances have the latest security updates, we strongly recommend using the default value of ``true`` .
- lifecycle_event_configuration
A
LifeCycleEventConfigurationobject that you can use to configure the Shutdown event to specify an execution timeout and enable or disable Elastic Load Balancer connection draining.
- load_based_auto_scaling
The load-based scaling configuration for the OpsWorks layer.
- name
The layer name, which is used by the console.
Layer names can be a maximum of 32 characters.
- packages
An array of
Packageobjects that describes the layer packages.
- shortname
For custom layers only, use this parameter to specify the layer’s short name, which is used internally by OpsWorks Stacks and by Chef recipes.
The short name is also used as the name for the directory where your app files are installed. It can have a maximum of 32 characters, which are limited to the alphanumeric characters, ‘-’, ‘_’, and ‘.’.
Built-in layer short names are defined by OpsWorks Stacks. For more information, see the Layer Reference .
- stack_id
The layer stack ID.
- tags
Specifies one or more sets of tags (key–value pairs) to associate with this OpsWorks layer.
Use tags to manage your resources.
- type
The layer type.
A stack cannot have more than one built-in layer of the same type. It can have any number of custom layers. Built-in layers are not available in Chef 12 stacks.
- use_ebs_optimized_instances
Whether to use Amazon EBS-optimized instances.
- volume_configurations
A
VolumeConfigurationsobject that describes the layer’s Amazon EBS volumes.