CfnApplicationPropsMixin
- class aws_cdk.mixins_preview.aws_elasticbeanstalk.mixins.CfnApplicationPropsMixin(props, *, strategy=None)
Bases:
MixinSpecify an AWS Elastic Beanstalk application by using the AWS::ElasticBeanstalk::Application resource in an AWS CloudFormation template.
The AWS::ElasticBeanstalk::Application resource is an AWS Elastic Beanstalk Beanstalk resource type that specifies an Elastic Beanstalk application.
- See:
- CloudformationResource:
AWS::ElasticBeanstalk::Application
- Mixin:
true
- 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 import mixins from aws_cdk.mixins_preview.aws_elasticbeanstalk import mixins as elasticbeanstalk_mixins cfn_application_props_mixin = elasticbeanstalk_mixins.CfnApplicationPropsMixin(elasticbeanstalk_mixins.CfnApplicationMixinProps( application_name="applicationName", description="description", resource_lifecycle_config=elasticbeanstalk_mixins.CfnApplicationPropsMixin.ApplicationResourceLifecycleConfigProperty( service_role="serviceRole", version_lifecycle_config=elasticbeanstalk_mixins.CfnApplicationPropsMixin.ApplicationVersionLifecycleConfigProperty( max_age_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxAgeRuleProperty( delete_source_from_s3=False, enabled=False, max_age_in_days=123 ), max_count_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxCountRuleProperty( delete_source_from_s3=False, enabled=False, max_count=123 ) ) ) ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::ElasticBeanstalk::Application.- Parameters:
props (
Union[CfnApplicationMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['applicationName', 'description', 'resourceLifecycleConfig']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental
ApplicationResourceLifecycleConfigProperty
- class CfnApplicationPropsMixin.ApplicationResourceLifecycleConfigProperty(*, service_role=None, version_lifecycle_config=None)
Bases:
objectUse the
ApplicationResourceLifecycleConfigproperty type to specify lifecycle settings for resources that belong to an AWS Elastic Beanstalk application when defining an AWS::ElasticBeanstalk::Application resource in an AWS CloudFormation template.The resource lifecycle configuration for an application. Defines lifecycle settings for resources that belong to the application, and the service role that Elastic Beanstalk assumes in order to apply lifecycle settings. The version lifecycle configuration defines lifecycle settings for application versions.
ApplicationResourceLifecycleConfigis a property of the AWS::ElasticBeanstalk::Application resource.- Parameters:
service_role (
Optional[str]) – The ARN of an IAM service role that Elastic Beanstalk has permission to assume. TheServiceRoleproperty is required the first time that you provide aResourceLifecycleConfigfor the application. After you provide it once, Elastic Beanstalk persists the Service Role with the application, and you don’t need to specify it again. You can, however, specify it in subsequent updates to change the Service Role to another value.version_lifecycle_config (
Union[IResolvable,ApplicationVersionLifecycleConfigProperty,Dict[str,Any],None]) – Defines lifecycle settings for application versions.
- See:
- 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_elasticbeanstalk import mixins as elasticbeanstalk_mixins application_resource_lifecycle_config_property = elasticbeanstalk_mixins.CfnApplicationPropsMixin.ApplicationResourceLifecycleConfigProperty( service_role="serviceRole", version_lifecycle_config=elasticbeanstalk_mixins.CfnApplicationPropsMixin.ApplicationVersionLifecycleConfigProperty( max_age_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxAgeRuleProperty( delete_source_from_s3=False, enabled=False, max_age_in_days=123 ), max_count_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxCountRuleProperty( delete_source_from_s3=False, enabled=False, max_count=123 ) ) )
Attributes
- service_role
The ARN of an IAM service role that Elastic Beanstalk has permission to assume.
The
ServiceRoleproperty is required the first time that you provide aResourceLifecycleConfigfor the application. After you provide it once, Elastic Beanstalk persists the Service Role with the application, and you don’t need to specify it again. You can, however, specify it in subsequent updates to change the Service Role to another value.
- version_lifecycle_config
Defines lifecycle settings for application versions.
ApplicationVersionLifecycleConfigProperty
- class CfnApplicationPropsMixin.ApplicationVersionLifecycleConfigProperty(*, max_age_rule=None, max_count_rule=None)
Bases:
objectUse the
ApplicationVersionLifecycleConfigproperty type to specify application version lifecycle settings for an AWS Elastic Beanstalk application when defining an AWS::ElasticBeanstalk::Application resource in an AWS CloudFormation template.The application version lifecycle settings for an application. Defines the rules that Elastic Beanstalk applies to an application’s versions in order to avoid hitting the per-region limit for application versions.
When Elastic Beanstalk deletes an application version from its database, you can no longer deploy that version to an environment. The source bundle remains in S3 unless you configure the rule to delete it.
ApplicationVersionLifecycleConfigis a property of the ApplicationResourceLifecycleConfig property type.- Parameters:
max_age_rule (
Union[IResolvable,MaxAgeRuleProperty,Dict[str,Any],None]) – Specify a max age rule to restrict the length of time that application versions are retained for an application.max_count_rule (
Union[IResolvable,MaxCountRuleProperty,Dict[str,Any],None]) – Specify a max count rule to restrict the number of application versions that are retained for an application.
- See:
- 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_elasticbeanstalk import mixins as elasticbeanstalk_mixins application_version_lifecycle_config_property = elasticbeanstalk_mixins.CfnApplicationPropsMixin.ApplicationVersionLifecycleConfigProperty( max_age_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxAgeRuleProperty( delete_source_from_s3=False, enabled=False, max_age_in_days=123 ), max_count_rule=elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxCountRuleProperty( delete_source_from_s3=False, enabled=False, max_count=123 ) )
Attributes
- max_age_rule
Specify a max age rule to restrict the length of time that application versions are retained for an application.
- max_count_rule
Specify a max count rule to restrict the number of application versions that are retained for an application.
MaxAgeRuleProperty
- class CfnApplicationPropsMixin.MaxAgeRuleProperty(*, delete_source_from_s3=None, enabled=None, max_age_in_days=None)
Bases:
objectUse the
MaxAgeRuleproperty type to specify a max age rule to restrict the length of time that application versions are retained for an AWS Elastic Beanstalk application when defining an AWS::ElasticBeanstalk::Application resource in an AWS CloudFormation template.A lifecycle rule that deletes application versions after the specified number of days.
MaxAgeRuleis a property of the ApplicationVersionLifecycleConfig property type.- Parameters:
delete_source_from_s3 (
Union[bool,IResolvable,None]) – Set totrueto delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.enabled (
Union[bool,IResolvable,None]) – Specifytrueto apply the rule, orfalseto disable it.max_age_in_days (
Union[int,float,None]) – Specify the number of days to retain an application versions.
- See:
- 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_elasticbeanstalk import mixins as elasticbeanstalk_mixins max_age_rule_property = elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxAgeRuleProperty( delete_source_from_s3=False, enabled=False, max_age_in_days=123 )
Attributes
- delete_source_from_s3
Set to
trueto delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.
- enabled
Specify
trueto apply the rule, orfalseto disable it.
- max_age_in_days
Specify the number of days to retain an application versions.
MaxCountRuleProperty
- class CfnApplicationPropsMixin.MaxCountRuleProperty(*, delete_source_from_s3=None, enabled=None, max_count=None)
Bases:
objectUse the
MaxAgeRuleproperty type to specify a max count rule to restrict the number of application versions that are retained for an AWS Elastic Beanstalk application when defining an AWS::ElasticBeanstalk::Application resource in an AWS CloudFormation template.A lifecycle rule that deletes the oldest application version when the maximum count is exceeded.
MaxCountRuleis a property of the ApplicationVersionLifecycleConfig property type.- Parameters:
delete_source_from_s3 (
Union[bool,IResolvable,None]) – Set totrueto delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.enabled (
Union[bool,IResolvable,None]) – Specifytrueto apply the rule, orfalseto disable it.max_count (
Union[int,float,None]) – Specify the maximum number of application versions to retain.
- See:
- 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_elasticbeanstalk import mixins as elasticbeanstalk_mixins max_count_rule_property = elasticbeanstalk_mixins.CfnApplicationPropsMixin.MaxCountRuleProperty( delete_source_from_s3=False, enabled=False, max_count=123 )
Attributes
- delete_source_from_s3
Set to
trueto delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.
- enabled
Specify
trueto apply the rule, orfalseto disable it.
- max_count
Specify the maximum number of application versions to retain.