Skip to content
v2.275.0

MaxAgeRuleProperty Struct ​

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.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_elasticbeanstalk as elasticbeanstalk } from 'aws-cdk-lib';
const maxAgeRuleProperty: elasticbeanstalk.CfnApplication.MaxAgeRuleProperty = {
  deleteSourceFromS3: false,
  enabled: false,
  maxAgeInDays: 123,
};

Properties ​

deleteSourceFromS3optionalboolean | IResolvabledelete_source_from_s3optionaltyping.Union[bool, IResolvable]deleteSourceFromS3optionalBooleanDeleteSourceFromS3optionalboolDeleteSourceFromS3optionalinterface{}#
Set to `true` to delete a version's source bundle from Amazon S3 when Elastic Beanstalk deletes the application version.
enabledoptionalboolean | IResolvableenabledoptionaltyping.Union[bool, IResolvable]enabledoptionalBooleanEnabledoptionalboolEnabledoptionalinterface{}#
Specify `true` to apply the rule, or `false` to disable it.
maxAgeInDaysoptionalnumbermax_age_in_daysoptionalint | floatmaxAgeInDaysoptionalNumberMaxAgeInDaysoptionaldoubleMaxAgeInDaysoptional*float64#
Specify the number of days to retain an application versions.