CfnApplicationPropsMixin

class aws_cdk.mixins_preview.aws_elasticbeanstalk.mixins.CfnApplicationPropsMixin(props, *, strategy=None)

Bases: Mixin

Specify 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:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticbeanstalk-application.html

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:

IConstruct

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 x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

ApplicationResourceLifecycleConfigProperty

class CfnApplicationPropsMixin.ApplicationResourceLifecycleConfigProperty(*, service_role=None, version_lifecycle_config=None)

Bases: object

Use the ApplicationResourceLifecycleConfig property 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.

ApplicationResourceLifecycleConfig is 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. The ServiceRole property is required the first time that you provide a ResourceLifecycleConfig for 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:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationresourcelifecycleconfig.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_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 ServiceRole property is required the first time that you provide a ResourceLifecycleConfig for 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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationresourcelifecycleconfig.html#cfn-elasticbeanstalk-application-applicationresourcelifecycleconfig-servicerole

version_lifecycle_config

Defines lifecycle settings for application versions.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationresourcelifecycleconfig.html#cfn-elasticbeanstalk-application-applicationresourcelifecycleconfig-versionlifecycleconfig

ApplicationVersionLifecycleConfigProperty

class CfnApplicationPropsMixin.ApplicationVersionLifecycleConfigProperty(*, max_age_rule=None, max_count_rule=None)

Bases: object

Use the ApplicationVersionLifecycleConfig property 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.

ApplicationVersionLifecycleConfig is 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:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationversionlifecycleconfig.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_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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationversionlifecycleconfig.html#cfn-elasticbeanstalk-application-applicationversionlifecycleconfig-maxagerule

max_count_rule

Specify a max count rule to restrict the number of application versions that are retained for an application.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationversionlifecycleconfig.html#cfn-elasticbeanstalk-application-applicationversionlifecycleconfig-maxcountrule

MaxAgeRuleProperty

class CfnApplicationPropsMixin.MaxAgeRuleProperty(*, delete_source_from_s3=None, enabled=None, max_age_in_days=None)

Bases: object

Use the MaxAgeRule property 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.

MaxAgeRule is a property of the ApplicationVersionLifecycleConfig property type.

Parameters:
  • delete_source_from_s3 (Union[bool, IResolvable, None]) – Set to true to delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.

  • enabled (Union[bool, IResolvable, None]) – Specify true to apply the rule, or false to disable it.

  • max_age_in_days (Union[int, float, None]) – Specify the number of days to retain an application versions.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxagerule.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_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 true to delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxagerule.html#cfn-elasticbeanstalk-application-maxagerule-deletesourcefroms3

enabled

Specify true to apply the rule, or false to disable it.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxagerule.html#cfn-elasticbeanstalk-application-maxagerule-enabled

max_age_in_days

Specify the number of days to retain an application versions.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxagerule.html#cfn-elasticbeanstalk-application-maxagerule-maxageindays

MaxCountRuleProperty

class CfnApplicationPropsMixin.MaxCountRuleProperty(*, delete_source_from_s3=None, enabled=None, max_count=None)

Bases: object

Use the MaxAgeRule property 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.

MaxCountRule is a property of the ApplicationVersionLifecycleConfig property type.

Parameters:
  • delete_source_from_s3 (Union[bool, IResolvable, None]) – Set to true to delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.

  • enabled (Union[bool, IResolvable, None]) – Specify true to apply the rule, or false to disable it.

  • max_count (Union[int, float, None]) – Specify the maximum number of application versions to retain.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxcountrule.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_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 true to delete a version’s source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxcountrule.html#cfn-elasticbeanstalk-application-maxcountrule-deletesourcefroms3

enabled

Specify true to apply the rule, or false to disable it.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxcountrule.html#cfn-elasticbeanstalk-application-maxcountrule-enabled

max_count

Specify the maximum number of application versions to retain.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-maxcountrule.html#cfn-elasticbeanstalk-application-maxcountrule-maxcount