Interface CfnLifecyclePolicyProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CfnLifecyclePolicyProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.93.0 (build 1706ca5)",
date="2024-01-03T18:29:27.557Z")
@Stability(Stable)
public interface CfnLifecyclePolicyProps
extends software.amazon.jsii.JsiiSerializable
Properties for defining a
CfnLifecyclePolicy.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.imagebuilder.*;
CfnLifecyclePolicyProps cfnLifecyclePolicyProps = CfnLifecyclePolicyProps.builder()
.executionRole("executionRole")
.name("name")
.policyDetails(List.of(PolicyDetailProperty.builder()
.action(ActionProperty.builder()
.type("type")
// the properties below are optional
.includeResources(IncludeResourcesProperty.builder()
.amis(false)
.containers(false)
.snapshots(false)
.build())
.build())
.filter(FilterProperty.builder()
.type("type")
.value(123)
// the properties below are optional
.retainAtLeast(123)
.unit("unit")
.build())
// the properties below are optional
.exclusionRules(ExclusionRulesProperty.builder()
.amis(AmiExclusionRulesProperty.builder()
.isPublic(false)
.lastLaunched(LastLaunchedProperty.builder()
.unit("unit")
.value(123)
.build())
.regions(List.of("regions"))
.sharedAccounts(List.of("sharedAccounts"))
.tagMap(Map.of(
"tagMapKey", "tagMap"))
.build())
.tagMap(Map.of(
"tagMapKey", "tagMap"))
.build())
.build()))
.resourceSelection(ResourceSelectionProperty.builder()
.recipes(List.of(RecipeSelectionProperty.builder()
.name("name")
// the properties below are optional
.semanticVersion("semanticVersion")
.build()))
.tagMap(Map.of(
"tagMapKey", "tagMap"))
.build())
.resourceType("resourceType")
// the properties below are optional
.description("description")
.status("status")
.tags(Map.of(
"tagsKey", "tags"))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCfnLifecyclePolicyPropsstatic final classAn implementation forCfnLifecyclePolicyProps -
Method Summary
Modifier and TypeMethodDescriptionbuilder()default StringOptional description for the lifecycle policy.The name or Amazon Resource Name (ARN) of the IAM role that Image Builder uses to run the lifecycle policy.getName()The name of the lifecycle policy.The configuration details for a lifecycle policy resource.Resource selection criteria used to run the lifecycle policy.The type of resources the lifecycle policy targets.default StringIndicates whether the lifecycle policy resource is enabled.getTags()To help manage your lifecycle policy resources, you can assign your own metadata to each resource in the form of tags.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getExecutionRole
The name or Amazon Resource Name (ARN) of the IAM role that Image Builder uses to run the lifecycle policy.This is a custom role that you create.
- See Also:
-
getName
The name of the lifecycle policy.- See Also:
-
getPolicyDetails
The configuration details for a lifecycle policy resource.- See Also:
-
getResourceSelection
Resource selection criteria used to run the lifecycle policy.- See Also:
-
getResourceType
The type of resources the lifecycle policy targets.- See Also:
-
getDescription
Optional description for the lifecycle policy.- See Also:
-
getStatus
Indicates whether the lifecycle policy resource is enabled.- See Also:
-
getTags
To help manage your lifecycle policy resources, you can assign your own metadata to each resource in the form of tags.Each tag consists of a key and an optional value, both of which you define.
- See Also:
-
builder
- Returns:
- a
CfnLifecyclePolicyProps.BuilderofCfnLifecyclePolicyProps
-