@cdkd/cli 0.324.0 → 0.326.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/{asg-provider-D8-GEE_f.js → asg-provider-ClmDsAE5.js} +3 -3
  2. package/dist/{asg-provider-D8-GEE_f.js.map → asg-provider-ClmDsAE5.js.map} +1 -1
  3. package/dist/{aws-clients-DWpHZk2l.js → aws-clients-ez_oXu6x.js} +123 -2
  4. package/dist/aws-clients-ez_oXu6x.js.map +1 -0
  5. package/dist/cli.js +2 -2
  6. package/dist/{created-resource-sink-CmrPwGge.js → created-resource-sink-DMf6WEao.js} +2 -2
  7. package/dist/{created-resource-sink-CmrPwGge.js.map → created-resource-sink-DMf6WEao.js.map} +1 -1
  8. package/dist/{db-instance-modify-retry-DCLA_p9I.js → db-instance-modify-retry-2tRANTVg.js} +6 -5
  9. package/dist/db-instance-modify-retry-2tRANTVg.js.map +1 -0
  10. package/dist/{deploy-engine-B32kQ3SO.js → deploy-engine-D75VMGMz.js} +219 -39
  11. package/dist/deploy-engine-D75VMGMz.js.map +1 -0
  12. package/dist/{iam-role-provider-D3th06lJ.js → iam-role-provider-Cbn0l18B.js} +4 -4
  13. package/dist/{iam-role-provider-D3th06lJ.js.map → iam-role-provider-Cbn0l18B.js.map} +1 -1
  14. package/dist/index.d.ts +13 -1
  15. package/dist/index.d.ts.map +1 -1
  16. package/dist/index.js +5 -5
  17. package/dist/{neptune-provider-CN7ptfAK.js → neptune-provider-mblWF8Dn.js} +4 -4
  18. package/dist/{neptune-provider-CN7ptfAK.js.map → neptune-provider-mblWF8Dn.js.map} +1 -1
  19. package/dist/{program-CcdJAeR0.js → program-DXF0ILBM.js} +69 -16
  20. package/dist/program-DXF0ILBM.js.map +1 -0
  21. package/dist/{provider-classes-CZnJcera.js → provider-classes-Cvc4LfXM.js} +249 -35
  22. package/dist/provider-classes-Cvc4LfXM.js.map +1 -0
  23. package/dist/{rds-provider-YcTAhlgr.js → rds-provider-DrH1T4n5.js} +180 -35
  24. package/dist/rds-provider-DrH1T4n5.js.map +1 -0
  25. package/dist/{version-h1THYe6R.js → version-DzOlXh8b.js} +2 -2
  26. package/dist/{version-h1THYe6R.js.map → version-DzOlXh8b.js.map} +1 -1
  27. package/package.json +3 -2
  28. package/dist/aws-clients-DWpHZk2l.js.map +0 -1
  29. package/dist/db-instance-modify-retry-DCLA_p9I.js.map +0 -1
  30. package/dist/deploy-engine-B32kQ3SO.js.map +0 -1
  31. package/dist/program-CcdJAeR0.js.map +0 -1
  32. package/dist/provider-classes-CZnJcera.js.map +0 -1
  33. package/dist/rds-provider-YcTAhlgr.js.map +0 -1
@@ -1,14 +1,14 @@
1
- import { r as getAwsClients, s as withApiGatewayPacing } from "./aws-clients-DWpHZk2l.js";
1
+ import { d as withApiGatewayPacing, l as s3ClientDefaults, r as getAwsClients } from "./aws-clients-ez_oXu6x.js";
2
2
  import { $ as safeMsg, A as isBeforeStateRead, E as generatedNameFor, J as displaySafe, N as recordedGeneratedNameKept, O as getCurrentStackInstanceId, Q as plainIdentOr, T as generateResourceNameWithFallback, V as SECRET_REF_MAX_CODE_POINTS, X as isPasteableIdent, Y as displayStackName, a as safeStringify, i as isAwsAuthoredFailure, n as describeAwsFailure, q as displayIdent, r as describeAwsStatusReason, s as getLogger, t as VERBOSE_POINTER, w as generateResourceName } from "./aws-failure-text-DiHodi76.js";
3
- import { $ as isTerminalDeleteFailure, A as setBounded, Ar as isThrottlingError, At as stateOrphanRecordRemedy, B as normalizeAwsTagsToCfn, C as AmbiguousCreateLatch, Cr as isExplicitDenyError, Ct as compositeIdFormatMessage, D as isInsideWindow, Dt as packCompositeId, E as createAttemptKey, Er as isTransientServerError, Et as logicalIdShown, F as assertRegionMatch, Fn as ResourceUpdateNotSupportedError, Ft as maskerOrIdentity, Gt as markAuxiliaryFailure, H as refusalTypeShown, I as VALUE_NOT_SHOWN, It as withDerivedNameMasks, J as deleteAfterProtectionFlipWithFinalSnapshot, K as ProtectionFlipRegistry, Kt as markCreatedBeforeFailure, L as isPlainImportJson, M as RESOURCE_NOT_FOUND, Mr as markRedactedCause, Mt as createMaskedRetryLogger, Nn as ProvisioningError, Nr as wrapMaskedAwsError, Nt as isSecretDerivedValue, O as replayFollowedAmbiguousAttempt, Or as THROTTLING_ERROR_NAMES, P as markNotGone, Pt as maskDeep, Q as isTerminalDbWaitStatus, Qn as pasteableCommand, R as isPlainImportValue, S as AMBIGUOUS_LATCH_TTL_MS, Sr as isAmbiguousOutcomeError, St as canonicalizeRoute53QueryName, T as ambiguousAttemptLead, Tr as isRetryableTransientError, Tt as compositeIdSkipResult, U as remedyLogicalId, Ut as isAuxiliaryFailure, V as quotedRemedyLogicalId, W as resolveExplicitPhysicalId, Xn as hasClauseBreak, Y as deleteWithProtectionCompensation, Yn as commandHole, Z as isProceedDbStatus, Zn as isInertUnquoted, b as withRemovalDefaults, bt as isInterruptedWaitError, ct as UNNAMEABLE_ID_CLAUSE, d as onlySecretDerived, dn as withPasteableAwsProfile, dt as pasteableAwsCommand, er as plainOrDescribed, et as logGroupProtectionSite, f as readPrincipalLists, fn as ambientClientDefaults, ft as protectedReplacementAdvice, g as clearOnUpdateRemoval, gn as AccountIdUnavailableError, hn as credentialFingerprint, hr as relayedNameCollision, ht as ElapsedBudgetRegistry, i as reportCreatedResource, ir as withheldTargetClause, j as withoutServerErrorRetries, jr as markNonRetryable, jt as createMaskedLogSinks, k as replayedSendWindow, kr as isMarkedNonRetryable, kt as segmentAfterAnchor, l as SECRET_DERIVED_READ_LIVE, lt as WITHHELD_AWS_COMMAND, m as recordedPrincipalsRepair, mn as clientDefaultsFor, mr as markReplayMayCollide, mt as ElapsedBudget, nt as protectionFlipKey, o as retractCreatedResource, on as injectiveKey, ot as userPoolProtectionSite, pn as ambientCredentialConfig, pr as markNameCollision, pt as renderDisableCommand, qt as markSupersedesEarlierCreate, rr as shellQuote, rt as rdsFamilyProtectionSite, sn as injectiveKeyPrefix, tt as observeThenDisableProtection, u as holdsSecretDerivedEntry, ut as isAwsCliLiteral, vn as CdkdError, w as RecentIdSet, wt as compositeIdSeparatorRefusal, xt as startInterruptWatch, y as removedTemplateKeys, yr as explicitDenyPolicyKind, z as isQuotableImportValue, zt as clearCreatedBeforeFailure } from "./created-resource-sink-CmrPwGge.js";
3
+ import { $ as isTerminalDeleteFailure, A as setBounded, Ar as isThrottlingError, At as stateOrphanRecordRemedy, B as normalizeAwsTagsToCfn, C as AmbiguousCreateLatch, Cr as isExplicitDenyError, Ct as compositeIdFormatMessage, D as isInsideWindow, Dt as packCompositeId, E as createAttemptKey, Er as isTransientServerError, Et as logicalIdShown, F as assertRegionMatch, Fn as ResourceUpdateNotSupportedError, Ft as maskerOrIdentity, Gt as markAuxiliaryFailure, H as refusalTypeShown, I as VALUE_NOT_SHOWN, It as withDerivedNameMasks, J as deleteAfterProtectionFlipWithFinalSnapshot, K as ProtectionFlipRegistry, Kt as markCreatedBeforeFailure, L as isPlainImportJson, M as RESOURCE_NOT_FOUND, Mr as markRedactedCause, Mt as createMaskedRetryLogger, Nn as ProvisioningError, Nr as wrapMaskedAwsError, Nt as isSecretDerivedValue, O as replayFollowedAmbiguousAttempt, Or as THROTTLING_ERROR_NAMES, P as markNotGone, Pt as maskDeep, Q as isTerminalDbWaitStatus, Qn as pasteableCommand, R as isPlainImportValue, S as AMBIGUOUS_LATCH_TTL_MS, Sr as isAmbiguousOutcomeError, St as canonicalizeRoute53QueryName, T as ambiguousAttemptLead, Tr as isRetryableTransientError, Tt as compositeIdSkipResult, U as remedyLogicalId, Ut as isAuxiliaryFailure, V as quotedRemedyLogicalId, W as resolveExplicitPhysicalId, Xn as hasClauseBreak, Y as deleteWithProtectionCompensation, Yn as commandHole, Z as isProceedDbStatus, Zn as isInertUnquoted, b as withRemovalDefaults, bt as isInterruptedWaitError, ct as UNNAMEABLE_ID_CLAUSE, d as onlySecretDerived, dn as withPasteableAwsProfile, dt as pasteableAwsCommand, er as plainOrDescribed, et as logGroupProtectionSite, f as readPrincipalLists, fn as ambientClientDefaults, ft as protectedReplacementAdvice, g as clearOnUpdateRemoval, gn as AccountIdUnavailableError, hn as credentialFingerprint, hr as relayedNameCollision, ht as ElapsedBudgetRegistry, i as reportCreatedResource, ir as withheldTargetClause, j as withoutServerErrorRetries, jr as markNonRetryable, jt as createMaskedLogSinks, k as replayedSendWindow, kr as isMarkedNonRetryable, kt as segmentAfterAnchor, l as SECRET_DERIVED_READ_LIVE, lt as WITHHELD_AWS_COMMAND, m as recordedPrincipalsRepair, mn as clientDefaultsFor, mr as markReplayMayCollide, mt as ElapsedBudget, nt as protectionFlipKey, o as retractCreatedResource, on as injectiveKey, ot as userPoolProtectionSite, pn as ambientCredentialConfig, pr as markNameCollision, pt as renderDisableCommand, qt as markSupersedesEarlierCreate, rr as shellQuote, rt as rdsFamilyProtectionSite, sn as injectiveKeyPrefix, tt as observeThenDisableProtection, u as holdsSecretDerivedEntry, ut as isAwsCliLiteral, vn as CdkdError, w as RecentIdSet, wt as compositeIdSeparatorRefusal, xt as startInterruptWatch, y as removedTemplateKeys, yr as explicitDenyPolicyKind, z as isQuotableImportValue, zt as clearCreatedBeforeFailure } from "./created-resource-sink-DMf6WEao.js";
4
4
  import { c as ambientRegion } from "./aws-client-defaults-BLXFsfMa.js";
5
- import { $ as isTtlRateLimited, $i as stringifyIfAssigned, A as resolvedResourceTimeoutMs, Aa as reEnableInstanceApiTermination, Ac as sameLambdaFunctionAddress, B as DELETE_INDEX_WAIT_PROCEED_NOTE, C as planContributorInsightsOp, Ca as withIndeterminateGuard, Cc as withRetry, Cd as derivePartitionAndUrlSuffix, Cl as recoverMaskedOutput, D as reverseMapTableContributorInsights, Da as isTerminationProtectionPropagationError, Dc as emrClusterInstancesReplaced, Dt as enclosingDeadlineRemainingMs, E as reverseMapIndexContributorInsights, Ea as ec2InstanceProtectionSite, Ec as ecsServiceLaunchTypeSetOrChanged, Et as enclosingDeadlineExpired, F as beginDeleteWait, Fi as earliestDefined, G as relayedIndexBusyDelete, Ga as s3BucketRegionalDomainName, Gi as DBPROXY_TAGS_WHAT, Gn as getCurrentProducerRegions, Gs as withheldAccountClause, H as TABLE_INDEX_NOUN, Ha as s3BucketArn, Hc as passedNoEchoParametersOf, Hr as awaitInFlightSibling, I as compensateRemovedDeletionProtection, Id as describeFileReadFailure, J as readbackVectorIndexes, Jc as markSameGenerationBag, Ji as readTagList, Jn as isRedactedRecordedValue, Js as findSdkUnwiredProperties, K as waitForIndexesSettled, Ka as s3BucketWebsiteUrl, Ki as DBPROXY_TAG_OPTIONS, Kr as replacedDeleteFailureVerdict, L as deleteBudgetKey, Ld as displayAssemblyPath, Li as reserveStackCreateToken, M as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, N as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS, Na as isUsableAttemptedName, Ns as refuseMalformedResourcesForDestroy, O as stripIndexContributorInsights, Oa as observeThenDisableInstanceApiTermination, Oc as canonicalLambdaFunctionName, Ol as carriesSecretMask, Oo as parseWebACLArn, P as DYNAMODB_DELETE_POLL_COST_MS, Q as isTtlAlreadyDisabled, Qi as definedAttributes, Qt as withNestedStackContext, R as resolveDynamoDbDeleteBudgetClock, Rd as renderAssemblyPathEscape, Ro as accountArgs, S as indexDeclaresContributorInsights, Sa as deleteSkipReason, Sd as canonicalizeRegion, Si as secretNamedAttributeNamesOf, T as readContributorInsightsSpec, Tl as recordAttributeIdCopy, U as deleteTableWithIndexBusyRetry, Ua as s3BucketDomainName, Ui as isRefusedByName, V as INDEX_SETTLE_POLL_INTERVAL_MS, Va as isSettledInstanceState, Vr as refuseRestoreFromItself, W as maskedLogger, Wa as s3BucketDualStackDomainName, Wi as markDeleteStarted, Wr as getStackRecords, Wt as getNestedRevertRun, X as vectorIndexesSettled, Xc as recordReferenceProvenanceEntry, Xi as tagMapAsList, Xn as redactedDeleteAddressSkip, Xs as withoutSdkUnwiredProperties, Y as vectorIndexesForCreate, Yc as redactForState, Yi as refuseMalformedDesiredTags, Yn as redactedDeleteAddressFields, Z as vectorIndexesShapeDetail, Za as outputReferenceProvenanceOf, Zc as snapshotPassProvenance, Zi as tagPlanWarning, Zt as getCurrentNestedStackContext, _ as streamMemberRefusals, _a as unchangedBehindSecretReference, _c as requireConfigArray, _o as getAccountInfo, _t as findNestedTemplateTreeDefect, aa as waitForLambdaFunctionActive, ac as WARM_THROUGHPUT_MEMBERS, at as hasCdkAutoDeleteTag, b as CONTRIBUTOR_INSIGHTS_KEY, bt as renderNestedTemplateTreeDefect, bu as rewriteTemplateAssetReferences, c as DynamoDBGlobalTableProvider, cc as toCfnInteger, cn as chunks, ct as markRefusedBeforeApplying, d as declaredStreamPolicyMember, dc as coerceCfnInteger, dn as withApiLimit, el as hasMaskableValues, et as planTimeToLive, f as declaredStreamTagsMember, fc as configBooleanRefusal, fu as timePhase, g as streamDeclaresTags, ga as onlySecretReferencesDiffer, gc as replayWarn, gl as dynamicReferenceTokens, h as streamDeclaresPolicy, ha as slowCcOperationTimeoutMs, hc as readConfigString, hu as stringifyValue, it as S3_AUTO_DELETE_OBJECTS_TAG, jo as passedParameterClassesOf, k as waitForGoneAfterDelete, ka as reDisableInstanceApiTermination, kc as lambdaFunctionNameForMask, l as STREAM_POLICY_KEY, la as getCurrentResourceSecrets, lc as toFiniteNumber, ln as isAccessDeniedError, m as reverseMapStreamPolicy, mc as configStringRefusal, ml as withoutPhysicalNameCopies, nt as sendTtlWaitingOutRateLimit, oc as coerceWarmThroughput$1, ot as isTruthyCfnBoolean, p as planStreamMemberOps, pc as configIntegerRefusal, ps as refuseMalformedNestedChildOutputs, q as planVectorIndexUpdates, qi as planTagDiff, qn as REDACTED_DELETE_ADDRESS_SKIP_REASON, qt as revertNestedChildFromJournal, rt as ECR_AUTO_DELETE_IMAGES_TAG, sc as isWarmThroughputDecrease, st as getPriorAttempts, t as DeployEngine, tt as readTtlSpec, u as STREAM_TAGS_KEY, uc as coerceCfnBoolean, un as lookupEachName, v as streamPolicyMatchesDeclared, vc as requireConfigObject, vt as isAbsoluteAssetPath, w as planIndexContributorInsightsOps, wc as blockDeviceMappingsDifferOnlyInDeleteOnTermination, wl as physicalNameCopiesOf, x as contributorInsightsRefusals, y as streamTagsMatchDeclared, yc as requireConfigString, yd as decodeListingKey, yt as listNestedTemplateRows, z as resolveDynamoDbDeleteBudgetMs, zd as resolveAssemblyPath, zi as acquireIdempotencyToken } from "./deploy-engine-B32kQ3SO.js";
6
- import { a as IamCreateClientCache, i as isEntityAlreadyExists, n as collectInlinePolicyNamesManagedBySiblings, r as iamEntityLeftByThisCreate, t as IAMRoleProvider } from "./iam-role-provider-D3th06lJ.js";
7
- import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, t as canonicalizeIpv4Cidr } from "./program-CcdJAeR0.js";
8
- import { n as modifyDbInstanceWhenAvailable } from "./db-instance-modify-retry-DCLA_p9I.js";
9
- import { RDSProvider } from "./rds-provider-YcTAhlgr.js";
10
- import { NeptuneProvider } from "./neptune-provider-CN7ptfAK.js";
11
- import { ASGProvider } from "./asg-provider-D8-GEE_f.js";
5
+ import { $ as isTtlRateLimited, $i as stringifyIfAssigned, A as resolvedResourceTimeoutMs, Aa as reEnableInstanceApiTermination, Ac as sameLambdaFunctionAddress, B as DELETE_INDEX_WAIT_PROCEED_NOTE, C as planContributorInsightsOp, Ca as withIndeterminateGuard, Cc as withRetry, Cd as derivePartitionAndUrlSuffix, Cl as recoverMaskedOutput, D as reverseMapTableContributorInsights, Da as isTerminationProtectionPropagationError, Dc as emrClusterInstancesReplaced, Dt as enclosingDeadlineRemainingMs, E as reverseMapIndexContributorInsights, Ea as ec2InstanceProtectionSite, Ec as ecsServiceLaunchTypeSetOrChanged, Et as enclosingDeadlineExpired, F as beginDeleteWait, Fi as earliestDefined, G as relayedIndexBusyDelete, Ga as s3BucketRegionalDomainName, Gi as DBPROXY_TAGS_WHAT, Gn as getCurrentProducerRegions, Gs as withheldAccountClause, H as TABLE_INDEX_NOUN, Ha as s3BucketArn, Hc as passedNoEchoParametersOf, Hr as awaitInFlightSibling, I as compensateRemovedDeletionProtection, Id as describeFileReadFailure, J as readbackVectorIndexes, Jc as markSameGenerationBag, Ji as readTagList, Jn as isRedactedRecordedValue, Js as findSdkUnwiredProperties, K as waitForIndexesSettled, Ka as s3BucketWebsiteUrl, Ki as DBPROXY_TAG_OPTIONS, Kr as replacedDeleteFailureVerdict, L as deleteBudgetKey, Ld as displayAssemblyPath, Li as reserveStackCreateToken, M as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, N as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS, Na as isUsableAttemptedName, Ns as refuseMalformedResourcesForDestroy, O as stripIndexContributorInsights, Oa as observeThenDisableInstanceApiTermination, Oc as canonicalLambdaFunctionName, Ol as carriesSecretMask, Oo as parseWebACLArn, P as DYNAMODB_DELETE_POLL_COST_MS, Q as isTtlAlreadyDisabled, Qi as definedAttributes, Qt as withNestedStackContext, R as resolveDynamoDbDeleteBudgetClock, Rd as renderAssemblyPathEscape, Ro as accountArgs, S as indexDeclaresContributorInsights, Sa as deleteSkipReason, Sd as canonicalizeRegion, Si as secretNamedAttributeNamesOf, T as readContributorInsightsSpec, Tl as recordAttributeIdCopy, U as deleteTableWithIndexBusyRetry, Ua as s3BucketDomainName, Ui as isRefusedByName, V as INDEX_SETTLE_POLL_INTERVAL_MS, Va as isSettledInstanceState, Vr as refuseRestoreFromItself, W as maskedLogger, Wa as s3BucketDualStackDomainName, Wi as markDeleteStarted, Wr as getStackRecords, Wt as getNestedRevertRun, X as vectorIndexesSettled, Xc as recordReferenceProvenanceEntry, Xi as tagMapAsList, Xn as redactedDeleteAddressSkip, Xs as withoutSdkUnwiredProperties, Y as vectorIndexesForCreate, Yc as redactForState, Yi as refuseMalformedDesiredTags, Yn as redactedDeleteAddressFields, Z as vectorIndexesShapeDetail, Za as outputReferenceProvenanceOf, Zc as snapshotPassProvenance, Zi as tagPlanWarning, Zt as getCurrentNestedStackContext, _ as streamMemberRefusals, _a as unchangedBehindSecretReference, _c as requireConfigArray, _o as getAccountInfo, _t as findNestedTemplateTreeDefect, aa as waitForLambdaFunctionActive, ac as WARM_THROUGHPUT_MEMBERS, at as hasCdkAutoDeleteTag, b as CONTRIBUTOR_INSIGHTS_KEY, bt as renderNestedTemplateTreeDefect, bu as rewriteTemplateAssetReferences, c as DynamoDBGlobalTableProvider, cc as toCfnInteger, cn as chunks, ct as markRefusedBeforeApplying, d as declaredStreamPolicyMember, dc as coerceCfnInteger, dn as withApiLimit, el as hasMaskableValues, et as planTimeToLive, f as declaredStreamTagsMember, fc as configBooleanRefusal, fu as timePhase, g as streamDeclaresTags, ga as onlySecretReferencesDiffer, gc as replayWarn, gl as dynamicReferenceTokens, h as streamDeclaresPolicy, ha as slowCcOperationTimeoutMs, hc as readConfigString, hu as stringifyValue, it as S3_AUTO_DELETE_OBJECTS_TAG, jo as passedParameterClassesOf, k as waitForGoneAfterDelete, ka as reDisableInstanceApiTermination, kc as lambdaFunctionNameForMask, l as STREAM_POLICY_KEY, la as getCurrentResourceSecrets, lc as toFiniteNumber, ln as isAccessDeniedError, m as reverseMapStreamPolicy, mc as configStringRefusal, ml as withoutPhysicalNameCopies, nt as sendTtlWaitingOutRateLimit, oc as coerceWarmThroughput$1, ot as isTruthyCfnBoolean, p as planStreamMemberOps, pc as configIntegerRefusal, ps as refuseMalformedNestedChildOutputs, q as planVectorIndexUpdates, qi as planTagDiff, qn as REDACTED_DELETE_ADDRESS_SKIP_REASON, qt as revertNestedChildFromJournal, rt as ECR_AUTO_DELETE_IMAGES_TAG, sc as isWarmThroughputDecrease, st as getPriorAttempts, t as DeployEngine, tt as readTtlSpec, u as STREAM_TAGS_KEY, uc as coerceCfnBoolean, un as lookupEachName, v as streamPolicyMatchesDeclared, vc as requireConfigObject, vt as isAbsoluteAssetPath, w as planIndexContributorInsightsOps, wc as blockDeviceMappingsDifferOnlyInDeleteOnTermination, wl as physicalNameCopiesOf, x as contributorInsightsRefusals, y as streamTagsMatchDeclared, yc as requireConfigString, yd as decodeListingKey, yt as listNestedTemplateRows, z as resolveDynamoDbDeleteBudgetMs, zd as resolveAssemblyPath, zi as acquireIdempotencyToken } from "./deploy-engine-D75VMGMz.js";
6
+ import { a as IamCreateClientCache, i as isEntityAlreadyExists, n as collectInlinePolicyNamesManagedBySiblings, r as iamEntityLeftByThisCreate, t as IAMRoleProvider } from "./iam-role-provider-Cbn0l18B.js";
7
+ import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, t as canonicalizeIpv4Cidr } from "./program-DXF0ILBM.js";
8
+ import { n as modifyDbInstanceWhenAvailable } from "./db-instance-modify-retry-2tRANTVg.js";
9
+ import { RDSProvider } from "./rds-provider-DrH1T4n5.js";
10
+ import { NeptuneProvider } from "./neptune-provider-mblWF8Dn.js";
11
+ import { ASGProvider } from "./asg-provider-ClmDsAE5.js";
12
12
  import { createHash, randomUUID } from "node:crypto";
13
13
  import { CreateBucketCommand, CreateBucketMetadataConfigurationCommand, DeleteBucketAnalyticsConfigurationCommand, DeleteBucketCommand, DeleteBucketCorsCommand, DeleteBucketEncryptionCommand, DeleteBucketIntelligentTieringConfigurationCommand, DeleteBucketInventoryConfigurationCommand, DeleteBucketLifecycleCommand, DeleteBucketMetadataConfigurationCommand, DeleteBucketMetricsConfigurationCommand, DeleteBucketOwnershipControlsCommand, DeleteBucketPolicyCommand, DeleteBucketReplicationCommand, DeleteBucketTaggingCommand, DeleteBucketWebsiteCommand, DeleteObjectsCommand, GetBucketAbacCommand, GetBucketAccelerateConfigurationCommand, GetBucketCorsCommand, GetBucketEncryptionCommand, GetBucketLifecycleConfigurationCommand, GetBucketLocationCommand, GetBucketLoggingCommand, GetBucketMetadataConfigurationCommand, GetBucketNotificationConfigurationCommand, GetBucketOwnershipControlsCommand, GetBucketPolicyCommand, GetBucketReplicationCommand, GetBucketTaggingCommand, GetBucketVersioningCommand, GetBucketWebsiteCommand, GetObjectCommand, GetObjectLockConfigurationCommand, GetPublicAccessBlockCommand, HeadBucketCommand, ListBucketAnalyticsConfigurationsCommand, ListBucketIntelligentTieringConfigurationsCommand, ListBucketInventoryConfigurationsCommand, ListBucketMetricsConfigurationsCommand, ListBucketsCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, PutBucketAbacCommand, PutBucketAccelerateConfigurationCommand, PutBucketAnalyticsConfigurationCommand, PutBucketCorsCommand, PutBucketEncryptionCommand, PutBucketIntelligentTieringConfigurationCommand, PutBucketInventoryConfigurationCommand, PutBucketLifecycleConfigurationCommand, PutBucketLoggingCommand, PutBucketMetricsConfigurationCommand, PutBucketNotificationConfigurationCommand, PutBucketOwnershipControlsCommand, PutBucketPolicyCommand, PutBucketReplicationCommand, PutBucketTaggingCommand, PutBucketVersioningCommand, PutBucketWebsiteCommand, PutObjectLockConfigurationCommand, PutPublicAccessBlockCommand, S3Client, UpdateBucketMetadataAnnotationTableConfigurationCommand, UpdateBucketMetadataInventoryTableConfigurationCommand, UpdateBucketMetadataJournalTableConfigurationCommand } from "@aws-sdk/client-s3";
14
14
  import { AddRoleToInstanceProfileCommand, AddUserToGroupCommand, AttachGroupPolicyCommand, AttachRolePolicyCommand, AttachUserPolicyCommand, CreateAccessKeyCommand, CreateGroupCommand, CreateInstanceProfileCommand, CreateLoginProfileCommand, CreatePolicyCommand, CreatePolicyVersionCommand, CreateUserCommand, DeleteAccessKeyCommand, DeleteGroupCommand, DeleteGroupPolicyCommand, DeleteInstanceProfileCommand, DeleteLoginProfileCommand, DeletePolicyCommand, DeletePolicyVersionCommand, DeleteRolePolicyCommand, DeleteUserCommand, DeleteUserPermissionsBoundaryCommand, DeleteUserPolicyCommand, DetachGroupPolicyCommand, DetachRolePolicyCommand, DetachUserPolicyCommand, GetAccessKeyLastUsedCommand, GetGroupCommand, GetGroupPolicyCommand, GetInstanceProfileCommand, GetPolicyCommand, GetPolicyVersionCommand, GetRolePolicyCommand, GetUserCommand, GetUserPolicyCommand, IAMClient, ListAccessKeysCommand, ListAttachedGroupPoliciesCommand, ListAttachedUserPoliciesCommand, ListEntitiesForPolicyCommand, ListGroupPoliciesCommand, ListGroupsForUserCommand, ListPoliciesCommand, ListPolicyTagsCommand, ListPolicyVersionsCommand, ListUserPoliciesCommand, NoSuchEntityException, PutGroupPolicyCommand, PutRolePolicyCommand, PutUserPermissionsBoundaryCommand, PutUserPolicyCommand, RemoveRoleFromInstanceProfileCommand, RemoveUserFromGroupCommand, TagPolicyCommand, TagUserCommand, UntagPolicyCommand, UntagUserCommand, UpdateAccessKeyCommand, UpdateGroupCommand, UpdateLoginProfileCommand, UpdateUserCommand } from "@aws-sdk/client-iam";
@@ -16,7 +16,7 @@ import { CreateQueueCommand, DeleteQueueCommand, GetQueueAttributesCommand, GetQ
16
16
  import { CreateTopicCommand, DeleteTopicCommand, GetSubscriptionAttributesCommand, GetTopicAttributesCommand, InvalidParameterException, ListSubscriptionsByTopicCommand, ListTagsForResourceCommand, ListTopicsCommand, NotFoundException, SNSClient, SetSubscriptionAttributesCommand, SetTopicAttributesCommand, SubscribeCommand, TagResourceCommand, UnsubscribeCommand, UntagResourceCommand } from "@aws-sdk/client-sns";
17
17
  import { AddPermissionCommand, CreateEventSourceMappingCommand, CreateFunctionCommand, CreateFunctionUrlConfigCommand, DeleteEventSourceMappingCommand, DeleteFunctionCodeSigningConfigCommand, DeleteFunctionCommand, DeleteFunctionConcurrencyCommand, DeleteFunctionEventInvokeConfigCommand, DeleteFunctionUrlConfigCommand, DeleteLayerVersionCommand, GetEventSourceMappingCommand, GetFunctionCodeSigningConfigCommand, GetFunctionCommand, GetFunctionConcurrencyCommand, GetFunctionConfigurationCommand, GetFunctionEventInvokeConfigCommand, GetFunctionRecursionConfigCommand, GetFunctionScalingConfigCommand, GetFunctionUrlConfigCommand, GetLayerVersionByArnCommand, GetPolicyCommand as GetPolicyCommand$1, GetRuntimeManagementConfigCommand, LambdaClient, ListEventSourceMappingsCommand, ListLayerVersionsCommand, ListTagsCommand, PublishLayerVersionCommand, PublishVersionCommand, PutFunctionCodeSigningConfigCommand, PutFunctionConcurrencyCommand, PutFunctionEventInvokeConfigCommand, PutFunctionRecursionConfigCommand, PutFunctionScalingConfigCommand, PutRuntimeManagementConfigCommand, RemovePermissionCommand, ResourceNotFoundException, TagResourceCommand as TagResourceCommand$1, UntagResourceCommand as UntagResourceCommand$1, UpdateEventSourceMappingCommand, UpdateFunctionCodeCommand, UpdateFunctionConfigurationCommand, UpdateFunctionUrlConfigCommand, waitUntilFunctionActiveV2, waitUntilFunctionUpdatedV2 } from "@aws-sdk/client-lambda";
18
18
  import { GetCallerIdentityCommand, STSClient } from "@aws-sdk/client-sts";
19
- import { AllocateAddressCommand, AssociateAddressCommand, AssociateIamInstanceProfileCommand, AssociateNatGatewayAddressCommand, AssociateRouteTableCommand, AttachInternetGatewayCommand, AttachVpnGatewayCommand, AuthorizeSecurityGroupEgressCommand, AuthorizeSecurityGroupIngressCommand, CreateInternetGatewayCommand, CreateNatGatewayCommand, CreateNetworkAclCommand, CreateNetworkAclEntryCommand, CreateRouteCommand, CreateRouteTableCommand, CreateSecurityGroupCommand, CreateSubnetCommand, CreateTagsCommand, CreateVpcCommand, DeleteInternetGatewayCommand, DeleteNatGatewayCommand, DeleteNetworkAclCommand, DeleteNetworkAclEntryCommand, DeleteNetworkInterfaceCommand, DeleteRouteCommand, DeleteRouteTableCommand, DeleteSecurityGroupCommand, DeleteSubnetCommand, DeleteTagsCommand, DeleteVpcCommand, DescribeAddressesCommand, DescribeAvailabilityZonesCommand, DescribeIamInstanceProfileAssociationsCommand, DescribeInstanceAttributeCommand, DescribeInstanceCreditSpecificationsCommand, DescribeInstancesCommand, DescribeInternetGatewaysCommand, DescribeNatGatewaysCommand, DescribeNetworkAclsCommand, DescribeNetworkInterfacesCommand, DescribeRouteTablesCommand, DescribeSecurityGroupRulesCommand, DescribeSecurityGroupsCommand, DescribeSubnetsCommand, DescribeVolumesCommand, DescribeVpcAttributeCommand, DescribeVpcsCommand, DescribeVpnGatewaysCommand, DetachInternetGatewayCommand, DetachVpnGatewayCommand, DisassociateAddressCommand, DisassociateIamInstanceProfileCommand, DisassociateNatGatewayAddressCommand, DisassociateRouteTableCommand, EC2Client, GetIpamPoolAllocationsCommand, ModifyInstanceAttributeCommand, ModifyInstanceCreditSpecificationCommand, ModifyInstanceMetadataOptionsCommand, ModifySubnetAttributeCommand, ModifyVpcAttributeCommand, ModifyVpcTenancyCommand, MonitorInstancesCommand, ReleaseAddressCommand, ReplaceIamInstanceProfileAssociationCommand, ReplaceNetworkAclAssociationCommand, ReplaceNetworkAclEntryCommand, ReplaceRouteCommand, RevokeSecurityGroupEgressCommand, RevokeSecurityGroupIngressCommand, RunInstancesCommand, StartInstancesCommand, StopInstancesCommand, TerminateInstancesCommand, UnmonitorInstancesCommand, waitUntilInstanceRunning, waitUntilInstanceTerminated, waitUntilNatGatewayAvailable, waitUntilNatGatewayDeleted } from "@aws-sdk/client-ec2";
19
+ import { AllocateAddressCommand, AssociateAddressCommand, AssociateIamInstanceProfileCommand, AssociateNatGatewayAddressCommand, AssociateRouteTableCommand, AttachInternetGatewayCommand, AttachVpnGatewayCommand, AuthorizeSecurityGroupEgressCommand, AuthorizeSecurityGroupIngressCommand, CreateInternetGatewayCommand, CreateNatGatewayCommand, CreateNetworkAclCommand, CreateNetworkAclEntryCommand, CreateRouteCommand, CreateRouteTableCommand, CreateSecurityGroupCommand, CreateSubnetCommand, CreateTagsCommand, CreateVpcCommand, DeleteInternetGatewayCommand, DeleteNatGatewayCommand, DeleteNetworkAclCommand, DeleteNetworkAclEntryCommand, DeleteNetworkInterfaceCommand, DeleteRouteCommand, DeleteRouteTableCommand, DeleteSecurityGroupCommand, DeleteSubnetCommand, DeleteTagsCommand, DeleteVpcCommand, DescribeAddressesCommand, DescribeAvailabilityZonesCommand, DescribeIamInstanceProfileAssociationsCommand, DescribeInstanceAttributeCommand, DescribeInstanceCreditSpecificationsCommand, DescribeInstancesCommand, DescribeInternetGatewaysCommand, DescribeNatGatewaysCommand, DescribeNetworkAclsCommand, DescribeNetworkInterfacesCommand, DescribeRouteTablesCommand, DescribeSecurityGroupRulesCommand, DescribeSecurityGroupsCommand, DescribeSubnetsCommand, DescribeVolumesCommand, DescribeVpcAttributeCommand, DescribeVpcsCommand, DescribeVpnGatewaysCommand, DetachInternetGatewayCommand, DetachVpnGatewayCommand, DisassociateAddressCommand, DisassociateIamInstanceProfileCommand, DisassociateNatGatewayAddressCommand, DisassociateRouteTableCommand, EC2Client, GetIpamPoolAllocationsCommand, ModifyInstanceAttributeCommand, ModifyInstanceCreditSpecificationCommand, ModifyInstanceMetadataOptionsCommand, ModifyPrivateDnsNameOptionsCommand, ModifySubnetAttributeCommand, ModifyVpcAttributeCommand, ModifyVpcTenancyCommand, MonitorInstancesCommand, ReleaseAddressCommand, ReplaceIamInstanceProfileAssociationCommand, ReplaceNetworkAclAssociationCommand, ReplaceNetworkAclEntryCommand, ReplaceRouteCommand, RevokeSecurityGroupEgressCommand, RevokeSecurityGroupIngressCommand, RunInstancesCommand, StartInstancesCommand, StopInstancesCommand, TerminateInstancesCommand, UnmonitorInstancesCommand, waitUntilInstanceRunning, waitUntilInstanceTerminated, waitUntilNatGatewayAvailable, waitUntilNatGatewayDeleted } from "@aws-sdk/client-ec2";
20
20
  import { CreateTableCommand, DeleteResourcePolicyCommand, DeleteTableCommand, DescribeContinuousBackupsCommand, DescribeContributorInsightsCommand, DescribeKinesisStreamingDestinationCommand, DescribeTableCommand, DescribeTimeToLiveCommand, DisableKinesisStreamingDestinationCommand, DynamoDBClient, EnableKinesisStreamingDestinationCommand, GetResourcePolicyCommand, ListTagsOfResourceCommand, PolicyNotFoundException, PutResourcePolicyCommand, ResourceNotFoundException as ResourceNotFoundException$1, TagResourceCommand as TagResourceCommand$2, UntagResourceCommand as UntagResourceCommand$2, UpdateContinuousBackupsCommand, UpdateContributorInsightsCommand, UpdateKinesisStreamingDestinationCommand, UpdateTableCommand, UpdateTimeToLiveCommand } from "@aws-sdk/client-dynamodb";
21
21
  import { APIGatewayClient, CreateAuthorizerCommand, CreateDeploymentCommand, CreateResourceCommand, CreateStageCommand, DeleteAuthorizerCommand, DeleteDeploymentCommand, DeleteIntegrationCommand, DeleteIntegrationResponseCommand, DeleteMethodCommand, DeleteMethodResponseCommand, DeleteResourceCommand, DeleteStageCommand, GetAccountCommand, GetAuthorizerCommand, GetAuthorizersCommand, GetDeploymentCommand, GetDeploymentsCommand, GetMethodCommand, GetResourceCommand, GetStageCommand, NotFoundException as NotFoundException$1, PutIntegrationCommand, PutIntegrationResponseCommand, PutMethodCommand, PutMethodResponseCommand, TagResourceCommand as TagResourceCommand$3, UntagResourceCommand as UntagResourceCommand$3, UpdateAccountCommand, UpdateAuthorizerCommand, UpdateDeploymentCommand, UpdateMethodCommand, UpdateStageCommand } from "@aws-sdk/client-api-gateway";
22
22
  import { CreateEventBusCommand, DeleteEventBusCommand, DeleteRuleCommand, DescribeEventBusCommand, DescribeRuleCommand, EventBridgeClient, ListRulesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$1, ListTargetsByRuleCommand, PutPermissionCommand, PutRuleCommand, PutTargetsCommand, RemoveTargetsCommand, ResourceNotFoundException as ResourceNotFoundException$2, TagResourceCommand as TagResourceCommand$4, UntagResourceCommand as UntagResourceCommand$4, UpdateEventBusCommand } from "@aws-sdk/client-eventbridge";
@@ -3720,6 +3720,7 @@ var S3BucketProvider = class S3BucketProvider {
3720
3720
  const holder = this.createClientHolder;
3721
3721
  holder.client ??= this.s3Client.config.region().then((region) => withoutServerErrorRetries(new S3Client({
3722
3722
  ...clientDefaultsFor(this.credentialConfig),
3723
+ ...s3ClientDefaults(),
3723
3724
  region
3724
3725
  })), (error) => {
3725
3726
  holder.client = void 0;
@@ -10033,6 +10034,11 @@ const ARN_SERVICE_TO_EVENT_SOURCE_KIND = {
10033
10034
  mq: "mq",
10034
10035
  rds: "documentdb"
10035
10036
  };
10037
+ function enabledFromState(state, properties) {
10038
+ if (state === "Enabled" || state === "Enabling") return true;
10039
+ if (state === "Disabled" || state === "Disabling") return false;
10040
+ return coerceCfnBoolean(properties?.["Enabled"]) ?? true;
10041
+ }
10036
10042
  function classifyEventSource(resp) {
10037
10043
  if (resp.SelfManagedEventSource !== void 0) return "kafka";
10038
10044
  if (resp.SelfManagedKafkaEventSourceConfig !== void 0) return "kafka";
@@ -10589,7 +10595,7 @@ var LambdaEventSourceMappingProvider = class {
10589
10595
  const date = raw instanceof Date ? raw : new Date(raw);
10590
10596
  result["StartingPositionTimestamp"] = Math.floor(date.getTime() / 1e3);
10591
10597
  }
10592
- if (resp.State !== void 0) result["Enabled"] = resp.State === "Enabled" || resp.State === "Enabling" || resp.State === "Updating";
10598
+ if (resp.State !== void 0) result["Enabled"] = enabledFromState(resp.State, properties);
10593
10599
  let tags = [];
10594
10600
  if (resp.EventSourceMappingArn) try {
10595
10601
  const tagMap = (await this.lambdaClient.send(new ListTagsCommand({ Resource: resp.EventSourceMappingArn }))).Tags ?? {};
@@ -17281,6 +17287,13 @@ const STOPPABLE_INSTANCE_STATES = /* @__PURE__ */ new Set([
17281
17287
  ]);
17282
17288
  const instancesLeftStoppedByCdkd = /* @__PURE__ */ new Set();
17283
17289
  const instanceStoppedAfterStart = /* @__PURE__ */ new WeakSet();
17290
+ function instanceStopMembers(plan) {
17291
+ return [
17292
+ plan.instanceType !== void 0 ? "InstanceType" : "",
17293
+ plan.userData !== void 0 ? "UserData" : "",
17294
+ plan.privateDnsNameOptions?.PrivateDnsHostnameType !== void 0 ? "PrivateDnsNameOptions.HostnameType" : ""
17295
+ ].filter(Boolean);
17296
+ }
17284
17297
  function isRecordedStandIn$1(value) {
17285
17298
  if (Array.isArray(value)) return value.some(isRecordedStandIn$1);
17286
17299
  if (value !== null && typeof value === "object") return Object.values(value).some(isRecordedStandIn$1);
@@ -17575,6 +17588,7 @@ function readbackNatZoneAddresses(live, recorded) {
17575
17588
  }
17576
17589
  const EIP_ALLOCATION_NOT_FOUND_NAMES = /* @__PURE__ */ new Set(["InvalidAllocationID.NotFound"]);
17577
17590
  const INSTANCE_NOT_FOUND_NAMES = /* @__PURE__ */ new Set(["InvalidInstanceID.NotFound"]);
17591
+ const LAUNCHED_INSTANCE_VISIBILITY_ATTEMPTS = 8;
17578
17592
  const VPC_NOT_FOUND_NAMES = /* @__PURE__ */ new Set(["InvalidVpcID.NotFound"]);
17579
17593
  const IPAM_POOL_NOT_FOUND_NAMES = /* @__PURE__ */ new Set(["InvalidIpamPoolId.NotFound"]);
17580
17594
  const SUBNET_NOT_FOUND_NAMES = /* @__PURE__ */ new Set(["InvalidSubnetID.NotFound"]);
@@ -17620,7 +17634,42 @@ const VPC_CREATE_ONLY_SENT = [
17620
17634
  "Ipv4NetmaskLength",
17621
17635
  "VpcEncryptionControl"
17622
17636
  ];
17623
- const INSTANCE_CREATE_ONLY_SENT = ["CpuOptions", "HibernationOptions"];
17637
+ const INSTANCE_CREATE_ONLY_SENT = [
17638
+ "CpuOptions",
17639
+ "HibernationOptions",
17640
+ "PlacementGroupName",
17641
+ "PrivateIpAddress",
17642
+ "Ipv6AddressCount",
17643
+ "Ipv6Addresses"
17644
+ ];
17645
+ function instanceIpv6AddressesRefusal(value, resourceType) {
17646
+ if (value === void 0 || value === null) return void 0;
17647
+ if (!Array.isArray(value)) return `${resourceType}.Ipv6Addresses must be a list of { Ipv6Address } entries (got ${typeof value === "object" ? "an object" : `a ${typeof value}`})`;
17648
+ for (const [i, item] of value.entries()) {
17649
+ const path = `${resourceType}.Ipv6Addresses[${i}]`;
17650
+ const refusal = item === void 0 || item === null ? `${path} must be an object (got ${item === null ? "null" : "undefined"})` : configStringRefusal(item, "Ipv6Address", "", path);
17651
+ if (refusal !== void 0) return refusal;
17652
+ const address = item["Ipv6Address"];
17653
+ if (typeof address !== "string" || address === "") return `${path}.Ipv6Address is required (the address to assign)`;
17654
+ }
17655
+ }
17656
+ function privateDnsNameOptionsRefusal(value, resourceType) {
17657
+ const path = `${resourceType}.PrivateDnsNameOptions`;
17658
+ if (value !== null && typeof value === "object" && !Array.isArray(value) && value["HostnameType"] === "") return `${path}.HostnameType must not be empty`;
17659
+ return configStringRefusal(value, "HostnameType", "", path) ?? configBooleanRefusal(value, "EnableResourceNameDnsARecord", path) ?? configBooleanRefusal(value, "EnableResourceNameDnsAAAARecord", path);
17660
+ }
17661
+ function privateDnsNameOptionsRequest(value) {
17662
+ if (value === void 0 || value === null) return void 0;
17663
+ const block = value;
17664
+ const hostnameType = block["HostnameType"];
17665
+ const aRecord = coerceCfnBoolean(block["EnableResourceNameDnsARecord"]);
17666
+ const aaaaRecord = coerceCfnBoolean(block["EnableResourceNameDnsAAAARecord"]);
17667
+ return {
17668
+ ...typeof hostnameType === "string" && hostnameType !== "" && { HostnameType: hostnameType },
17669
+ ...aRecord !== void 0 && { EnableResourceNameDnsARecord: aRecord },
17670
+ ...aaaaRecord !== void 0 && { EnableResourceNameDnsAAAARecord: aaaaRecord }
17671
+ };
17672
+ }
17624
17673
  function foldCreateOnlySent(key, value) {
17625
17674
  const asRecord = (v) => v !== null && typeof v === "object" && !Array.isArray(v) ? v : void 0;
17626
17675
  if (key === "Ipv4NetmaskLength") return coerceCfnInteger(value) ?? value;
@@ -17764,7 +17813,16 @@ var EC2Provider = class {
17764
17813
  "CreditSpecification",
17765
17814
  "CpuOptions",
17766
17815
  "HibernationOptions",
17767
- "InstanceInitiatedShutdownBehavior"
17816
+ "InstanceInitiatedShutdownBehavior",
17817
+ "SourceDestCheck",
17818
+ "Tenancy",
17819
+ "PlacementGroupName",
17820
+ "PrivateIpAddress",
17821
+ "PropagateTagsToVolumeOnCreation",
17822
+ "AdditionalInfo",
17823
+ "Ipv6AddressCount",
17824
+ "Ipv6Addresses",
17825
+ "PrivateDnsNameOptions"
17768
17826
  ])],
17769
17827
  ["AWS::EC2::NetworkAcl", /* @__PURE__ */ new Set(["VpcId", "Tags"])],
17770
17828
  ["AWS::EC2::NetworkAclEntry", /* @__PURE__ */ new Set([
@@ -17780,7 +17838,7 @@ var EC2Provider = class {
17780
17838
  ])],
17781
17839
  ["AWS::EC2::SubnetNetworkAclAssociation", /* @__PURE__ */ new Set(["SubnetId", "NetworkAclId"])]
17782
17840
  ]);
17783
- removalDefaults = /* @__PURE__ */ new Map([["AWS::EC2::VPC", /* @__PURE__ */ new Map([["EnableDnsHostnames", false], ["EnableDnsSupport", true]])], ["AWS::EC2::Instance", /* @__PURE__ */ new Map([["Monitoring", false]])]]);
17841
+ removalDefaults = /* @__PURE__ */ new Map([["AWS::EC2::VPC", /* @__PURE__ */ new Map([["EnableDnsHostnames", false], ["EnableDnsSupport", true]])], ["AWS::EC2::Instance", /* @__PURE__ */ new Map([["Monitoring", false], ["SourceDestCheck", true]])]]);
17784
17842
  unhandledByDesign = /* @__PURE__ */ new Map([
17785
17843
  ["AWS::EC2::Instance", /* @__PURE__ */ new Map([["ElasticGpuSpecifications", "AWS Elastic GPU end-of-life (announced 2023-11); no replacement API"], ["ElasticInferenceAccelerators", "AWS Elastic Inference end-of-life 2024-04; use AWS Inferentia / Trainium accelerator instance families instead"]])],
17786
17844
  ["AWS::EC2::SecurityGroupIngress", /* @__PURE__ */ new Map([["GroupName", "EC2-Classic-only — use GroupId for VPC security groups (EC2-Classic retired 2022-08-15)"], ["SourceSecurityGroupName", "EC2-Classic-only — use SourceSecurityGroupId for VPC peer security groups (EC2-Classic retired 2022-08-15)"]])],
@@ -20091,8 +20149,12 @@ var EC2Provider = class {
20091
20149
  scope: "RunInstances",
20092
20150
  logicalId
20093
20151
  });
20152
+ const propagateToVolumes = coerceCfnBoolean(properties["PropagateTagsToVolumeOnCreation"]) === true;
20094
20153
  const { response, tagsApplied } = await this.sendTaggedCreate(logicalId, "instance", desiredTags, (TagSpecifications) => this.ec2Client.send(new RunInstancesCommand({
20095
- ...TagSpecifications && { TagSpecifications },
20154
+ ...TagSpecifications && { TagSpecifications: propagateToVolumes ? [...TagSpecifications, ...TagSpecifications.map((spec) => ({
20155
+ ...spec,
20156
+ ResourceType: "volume"
20157
+ }))] : TagSpecifications },
20096
20158
  ClientToken: runInstancesToken.value,
20097
20159
  ImageId: imageId,
20098
20160
  InstanceType: instanceType,
@@ -20122,7 +20184,7 @@ var EC2Provider = class {
20122
20184
  const instanceId = instance.InstanceId;
20123
20185
  reportCreatedResource(logicalId, resourceType, instanceId);
20124
20186
  try {
20125
- if (!tagsApplied) await this.applyTags(instanceId, desiredTags, logicalId, maskerOrIdentity(context?.maskSecrets));
20187
+ if (!tagsApplied) await this.applyTags(instanceId, desiredTags, logicalId, maskerOrIdentity(context?.maskSecrets), (call) => this.whileLaunchedInstanceNotVisible(logicalId, instanceId, call));
20126
20188
  if (process.env["CDKD_NO_WAIT"] !== "true") {
20127
20189
  this.logger.debug(`Waiting for instance ${instanceId} to be running...`);
20128
20190
  await waitUntilInstanceRunning({
@@ -20139,7 +20201,16 @@ var EC2Provider = class {
20139
20201
  this.logger.warn(`Skipped the IAM instance profile association check for ${logicalId} (${instanceId}) because --no-wait leaves the instance in 'pending', where AssociateIamInstanceProfile is rejected. RunInstances associates the profile asynchronously and can complete with NO profile attached when the profile was created moments earlier. Verify with: ${aws`aws ec2 describe-iam-instance-profile-associations --filters Name=instance-id,Values=${instanceId}`.render()} — and if it is missing, re-associate with: ` + (profileRef.includes(",") ? WITHHELD_AWS_COMMAND : aws`aws ec2 associate-iam-instance-profile --instance-id ${instanceId} --iam-instance-profile ${iamInstanceProfile.arn ? aws`Arn=${profileRef}` : aws`Name=${profileRef}`}`.render()));
20140
20202
  } else await this.ensureIamInstanceProfileAssociated(instanceId, iamInstanceProfile.arn, iamInstanceProfile.name, logicalId);
20141
20203
  }
20142
- const runningInstance = (await this.ec2Client.send(new DescribeInstancesCommand({ InstanceIds: [instanceId] }))).Reservations?.[0]?.Instances?.[0];
20204
+ if (coerceCfnBoolean(properties["SourceDestCheck"]) === false) await this.whileLaunchedInstanceNotVisible(logicalId, instanceId, () => this.ec2Client.send(new ModifyInstanceAttributeCommand({
20205
+ InstanceId: instanceId,
20206
+ SourceDestCheck: { Value: false }
20207
+ })));
20208
+ const runningInstance = (await this.whileLaunchedInstanceNotVisible(logicalId, instanceId, () => this.ec2Client.send(new DescribeInstancesCommand({ InstanceIds: [instanceId] })))).Reservations?.[0]?.Instances?.[0];
20209
+ if (propagateToVolumes && !tagsApplied && desiredTags.length > 0) {
20210
+ const volumeIds = (runningInstance?.BlockDeviceMappings ?? []).map((m) => m.Ebs?.VolumeId).filter((id) => typeof id === "string" && id !== "");
20211
+ if (volumeIds.length === 0) this.logger.warn(safeMsg`${logicalId}: PropagateTagsToVolumeOnCreation is set, but the launch went out without tags (the tagged RunInstances was refused) and DescribeInstances reported no attached volume for ${instanceId} yet (under --no-wait the instance may still be pending), so its volumes were not tagged. Tag them with ec2:CreateTags once they are attached.`);
20212
+ for (const volumeId of volumeIds) await this.applyTags(volumeId, desiredTags, logicalId, maskerOrIdentity(context?.maskSecrets));
20213
+ }
20143
20214
  const attributes = describedInstanceAttributes(instanceId, runningInstance);
20144
20215
  this.logger.debug(`Successfully created EC2 Instance ${logicalId}: ${instanceId}`);
20145
20216
  runInstancesToken.release();
@@ -20331,12 +20402,38 @@ var EC2Provider = class {
20331
20402
  }
20332
20403
  const createOnlyChanged = INSTANCE_CREATE_ONLY_SENT.filter((key) => changed(key, (a, b) => sameCreateOnlySent(key, a, b)));
20333
20404
  if (createOnlyChanged.length > 0) throw refusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, `replace the instance (cdkd deploy --replace). ${createOnlyChanged.join(", ")} can be set only when the instance is launched, and CloudFormation creates a new instance for this change`));
20405
+ if (changed("Tenancy", (a, b) => a === b) && !standInSkips("Tenancy")) {
20406
+ const before = previousProperties["Tenancy"];
20407
+ const after = properties["Tenancy"];
20408
+ const refusal = configStringRefusal(properties, "Tenancy", "", resourceType);
20409
+ if (refusal !== void 0) throw refusedBeforeApplying(new ProvisioningError(`${refusal}. The instance ${logicalId} was not updated.`, resourceType, logicalId, physicalId));
20410
+ if (before == null && typeof after === "string") plan.tenancyAddition = {
20411
+ value: after,
20412
+ replaying: context?.replayingState === true
20413
+ };
20414
+ else if (typeof before === "string" && typeof after === "string" && before !== "default" && after !== "default") {
20415
+ if (context?.replayingState === true) this.logger.warn(safeMsg`${logicalId} (${resourceType}): the rollback would change Tenancy ${before} -> ${after}, which cdkd does not apply; the instance keeps its current tenancy.`);
20416
+ else throw refusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, safeMsg`cdkd does not change Tenancy ${before} -> ${after}. How CloudFormation applies a change between two non-default tenancies has not been measured (it may stop the instance and move it rather than replace it), so cdkd neither replaces the instance nor applies the change. Keep the current tenancy, or replace the instance explicitly with cdkd deploy --replace`));
20417
+ } else if (context?.replayingState === true) this.logger.warn(safeMsg`${logicalId} (${resourceType}): the rollback would change Tenancy (${before === void 0 ? "unset" : before} -> ${after === void 0 ? "unset" : after}), which needs a new instance; the instance keeps its current tenancy.`);
20418
+ else throw refusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, "replace the instance (cdkd deploy --replace). CloudFormation creates a new instance for a Tenancy change to or from default"));
20419
+ }
20334
20420
  if (changed("InstanceInitiatedShutdownBehavior", (a, b) => a === b)) {
20335
20421
  if (properties["InstanceInitiatedShutdownBehavior"] === void 0) {
20336
20422
  if (context?.replayingState === true) this.logger.warn(safeMsg`${logicalId} (${resourceType}): the state being restored does not declare InstanceInitiatedShutdownBehavior; the rollback leaves it at its current AWS value.`);
20337
20423
  else throw refusedBeforeApplying(new ProvisioningError(safeMsg`${logicalId} (${resourceType}): InstanceInitiatedShutdownBehavior was removed from the template, and CloudFormation fails that update for an existing instance. Keep it declared (set it to stop, the default, to leave the behavior at AWS's default). The instance was not updated.`, resourceType, logicalId, physicalId));
20338
20424
  } else if (!standInSkips("InstanceInitiatedShutdownBehavior")) plan.shutdownBehavior = requireConfigString(properties["InstanceInitiatedShutdownBehavior"], "", "AWS::EC2::Instance InstanceInitiatedShutdownBehavior");
20339
20425
  }
20426
+ const sourceDestCheckOf = (v) => v === void 0 ? true : coerceCfnBoolean(v);
20427
+ if (changed("SourceDestCheck", (a, b) => sourceDestCheckOf(a) === sourceDestCheckOf(b)) && !standInSkips("SourceDestCheck")) {
20428
+ const raw = properties["SourceDestCheck"];
20429
+ const want = raw === void 0 ? true : coerceCfnBoolean(raw);
20430
+ if (want === void 0) {
20431
+ const refusal = configBooleanRefusal(properties, "SourceDestCheck", resourceType);
20432
+ if (context?.replayingState === true || context?.desiredFromAwsReadback === true) this.logger.warn(safeMsg`${logicalId} (${resourceType}): ${refusal ?? "SourceDestCheck is not a boolean"}; it is left at its current AWS value.`);
20433
+ else throw refusedBeforeApplying(new ProvisioningError(`${refusal ?? `${resourceType}.SourceDestCheck must be a boolean`}. The instance ${logicalId} was not updated.`, resourceType, logicalId, physicalId));
20434
+ } else plan.sourceDestCheck = want;
20435
+ }
20436
+ this.planPrivateDnsNameOptions(logicalId, physicalId, resourceType, properties, previousProperties, context, plan, changed, standInSkips);
20340
20437
  if (changed("UserData", (a, b) => a === b)) {
20341
20438
  const userData = properties["UserData"];
20342
20439
  if (userData === void 0) plan.userData = /* @__PURE__ */ new Uint8Array(0);
@@ -20389,14 +20486,64 @@ var EC2Provider = class {
20389
20486
  }
20390
20487
  return plan;
20391
20488
  }
20489
+ planPrivateDnsNameOptions(logicalId, physicalId, resourceType, properties, previousProperties, context, plan, changed, standInSkips) {
20490
+ const KEY = "PrivateDnsNameOptions";
20491
+ const readable = (v) => v != null && privateDnsNameOptionsRefusal(v, resourceType) === void 0 ? privateDnsNameOptionsRequest(v) ?? {} : {};
20492
+ const sameOptions = (a, b) => a != null && b != null && privateDnsNameOptionsRefusal(a, resourceType) === void 0 && privateDnsNameOptionsRefusal(b, resourceType) === void 0 && isDeepStrictEqual(readable(a), readable(b));
20493
+ if (!changed(KEY, sameOptions)) return;
20494
+ const replaying = context?.replayingState === true;
20495
+ const after = properties[KEY];
20496
+ if (after === void 0 || after === null) {
20497
+ if (replaying) {
20498
+ this.logger.warn(safeMsg`${logicalId} (${resourceType}): the state being restored does not declare PrivateDnsNameOptions, which needs a new instance; the rollback leaves the instance's hostname options as they are.`);
20499
+ return;
20500
+ }
20501
+ throw refusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, "replace the instance (cdkd deploy --replace). CloudFormation creates a new instance when PrivateDnsNameOptions is removed"));
20502
+ }
20503
+ if (standInSkips(KEY)) return;
20504
+ const refusal = privateDnsNameOptionsRefusal(after, resourceType);
20505
+ if (refusal !== void 0) {
20506
+ if (replaying || context?.desiredFromAwsReadback === true) {
20507
+ this.logger.warn(safeMsg`${logicalId} (${resourceType}): ${refusal}; the hostname options are left at their current AWS value.`);
20508
+ return;
20509
+ }
20510
+ throw refusedBeforeApplying(new ProvisioningError(`${refusal}. The instance ${logicalId} was not updated.`, resourceType, logicalId, physicalId));
20511
+ }
20512
+ const want = readable(after);
20513
+ const had = readable(previousProperties[KEY]);
20514
+ const request = {};
20515
+ if (want.HostnameType !== void 0 && want.HostnameType !== had.HostnameType) request.PrivateDnsHostnameType = want.HostnameType;
20516
+ for (const member of ["EnableResourceNameDnsARecord", "EnableResourceNameDnsAAAARecord"]) if (want[member] !== void 0 && want[member] !== had[member]) request[member] = want[member];
20517
+ const removedMembers = context?.desiredFromAwsReadback === true ? "" : Object.keys(had).filter((m) => want[m] === void 0).join(", ");
20518
+ if (removedMembers !== "") {
20519
+ if (!replaying) throw refusedBeforeApplying(new ProvisioningError(safeMsg`${logicalId} (${resourceType}): PrivateDnsNameOptions ${removedMembers} was removed from the template, and CloudFormation fails that update ("No valid attributes specified"). Keep it declared (set it to the value the instance has to leave it unchanged), or remove the whole PrivateDnsNameOptions block, which replaces the instance. The instance was not updated.`, resourceType, logicalId, physicalId));
20520
+ this.logger.warn(safeMsg`${logicalId} (${resourceType}): the state being restored does not declare PrivateDnsNameOptions ${removedMembers}; the rollback leaves it at its current AWS value.`);
20521
+ }
20522
+ if (Object.keys(request).length > 0) plan.privateDnsNameOptions = request;
20523
+ }
20392
20524
  async prepareInstanceMemberUpdates(logicalId, physicalId, resourceType, plan) {
20393
- const needsStop = plan.instanceType !== void 0 || plan.userData !== void 0;
20394
20525
  const needsDefaultGroup = plan.securityGroups?.kind === "vpc-default";
20395
- if (!needsStop && !needsDefaultGroup) return;
20526
+ const tenancy = plan.tenancyAddition;
20527
+ if (instanceStopMembers(plan).length === 0 && !needsDefaultGroup && tenancy === void 0) return;
20396
20528
  const instance = (await this.ec2Client.send(new DescribeInstancesCommand({ InstanceIds: [physicalId] }))).Reservations?.[0]?.Instances?.[0];
20529
+ const dns = plan.privateDnsNameOptions;
20530
+ if (dns?.PrivateDnsHostnameType !== void 0 && instance?.PrivateDnsNameOptions?.HostnameType === dns.PrivateDnsHostnameType) {
20531
+ const { PrivateDnsHostnameType: _sameAsLive, ...rest } = dns;
20532
+ if (Object.keys(rest).length > 0) plan.privateDnsNameOptions = rest;
20533
+ else delete plan.privateDnsNameOptions;
20534
+ }
20535
+ const stopMembers = instanceStopMembers(plan);
20536
+ const needsStop = stopMembers.length > 0;
20537
+ if (tenancy !== void 0) {
20538
+ const live = instance?.Placement?.Tenancy;
20539
+ if (live !== tenancy.value) {
20540
+ if (tenancy.replaying) this.logger.warn(safeMsg`${logicalId} (${resourceType}): the state being restored declares Tenancy ${tenancy.value}, but the instance has ${live ?? "an unreadable tenancy"}; the rollback leaves it as it is.`);
20541
+ else throw markRefusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, safeMsg`the template declares Tenancy ${tenancy.value}, the instance has ${live ?? "a tenancy DescribeInstances did not report"}, and the state record does not say which tenancy it was launched with. Changing it needs a new instance: replace it with cdkd deploy --replace, or declare Tenancy ${live ?? "as the instance has it"}`));
20542
+ }
20543
+ }
20397
20544
  if (needsStop) {
20398
- const members = [plan.instanceType !== void 0 ? "InstanceType" : "", plan.userData !== void 0 ? "UserData" : ""].filter(Boolean).join(" and ");
20399
- if (instance?.RootDeviceType === "instance-store") throw markRefusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, `${members} can change only on a stopped instance, and an instance-store-backed instance cannot be stopped; CloudFormation replaces it. Re-deploy with cdkd deploy --replace.`));
20545
+ const members = stopMembers.join(" and ");
20546
+ if (instance?.RootDeviceType === "instance-store") throw markRefusedBeforeApplying(new ResourceUpdateNotSupportedError(resourceType, logicalId, `${members} can change only on a stopped instance, and an instance-store-backed instance cannot be stopped; ${plan.instanceType !== void 0 || plan.userData !== void 0 ? "CloudFormation replaces it" : "it needs a new instance"}. Re-deploy with cdkd deploy --replace.`));
20400
20547
  const state = instance?.State?.Name;
20401
20548
  if (!STOPPABLE_INSTANCE_STATES.has(state ?? "")) throw refusedBeforeApplying(new ProvisioningError(`${logicalId} (${resourceType}): instance ${physicalId} is ${state ?? "not returned by DescribeInstances"}, so its ${members} cannot be changed. The instance was not updated.`, resourceType, logicalId, physicalId));
20402
20549
  }
@@ -20435,7 +20582,24 @@ var EC2Provider = class {
20435
20582
  }));
20436
20583
  applied.push("the new InstanceInitiatedShutdownBehavior");
20437
20584
  }
20438
- if (plan.instanceType === void 0 && plan.userData === void 0) {
20585
+ if (plan.sourceDestCheck !== void 0) {
20586
+ await this.ec2Client.send(new ModifyInstanceAttributeCommand({
20587
+ InstanceId: physicalId,
20588
+ SourceDestCheck: { Value: plan.sourceDestCheck }
20589
+ }));
20590
+ applied.push("the new SourceDestCheck");
20591
+ }
20592
+ const dns = plan.privateDnsNameOptions;
20593
+ if (dns !== void 0 && dns.PrivateDnsHostnameType === void 0) {
20594
+ await this.ec2Client.send(new ModifyPrivateDnsNameOptionsCommand({
20595
+ InstanceId: physicalId,
20596
+ ...dns
20597
+ }));
20598
+ applied.push("the new PrivateDnsNameOptions");
20599
+ }
20600
+ const stopMembers = instanceStopMembers(plan);
20601
+ const stopWhat = stopMembers.join(" / ");
20602
+ if (stopMembers.length === 0) {
20439
20603
  if (instancesLeftStoppedByCdkd.has(physicalId)) {
20440
20604
  let state = await this.readInstanceState(physicalId);
20441
20605
  if (state === "stopping") state = await this.waitForInstanceState(logicalId, physicalId, resourceType, "stopped");
@@ -20447,13 +20611,13 @@ var EC2Provider = class {
20447
20611
  let state = await this.readInstanceState(physicalId);
20448
20612
  if (state === "pending") state = await this.waitForInstanceState(logicalId, physicalId, resourceType, "running");
20449
20613
  else if (state === "stopping") state = await this.waitForInstanceState(logicalId, physicalId, resourceType, "stopped");
20450
- if (state !== "stopped" && state !== "running") throw markNonRetryable(new ProvisioningError(`${logicalId} (${resourceType}): instance ${physicalId} became ${state ?? "not returned by DescribeInstances"} during the update, so its InstanceType / UserData were not changed`, resourceType, logicalId, physicalId));
20614
+ if (state !== "stopped" && state !== "running") throw markNonRetryable(new ProvisioningError(`${logicalId} (${resourceType}): instance ${physicalId} became ${state ?? "not returned by DescribeInstances"} during the update, so its ${stopWhat} were not changed`, resourceType, logicalId, physicalId));
20451
20615
  const startAfter = state === "running" || instancesLeftStoppedByCdkd.has(physicalId);
20452
20616
  let phase = "stop";
20453
20617
  let stopIssued = false;
20454
20618
  try {
20455
20619
  if (state === "running") {
20456
- this.logger.info(safeMsg`Stopping EC2 Instance ${logicalId} (${physicalId}) to change its ${plan.instanceType !== void 0 ? "InstanceType" : ""}${plan.instanceType !== void 0 && plan.userData !== void 0 ? " and " : ""}${plan.userData !== void 0 ? "UserData" : ""}; it is started again afterwards`);
20620
+ this.logger.info(safeMsg`Stopping EC2 Instance ${logicalId} (${physicalId}) to change its ${stopMembers.join(" and ")}; it is started again afterwards`);
20457
20621
  await this.ec2Client.send(new StopInstancesCommand({ InstanceIds: [physicalId] }));
20458
20622
  stopIssued = true;
20459
20623
  await this.waitForInstanceState(logicalId, physicalId, resourceType, "stopped");
@@ -20473,6 +20637,13 @@ var EC2Provider = class {
20473
20637
  }));
20474
20638
  applied.push("the new UserData");
20475
20639
  }
20640
+ if (dns?.PrivateDnsHostnameType !== void 0) {
20641
+ await this.ec2Client.send(new ModifyPrivateDnsNameOptionsCommand({
20642
+ InstanceId: physicalId,
20643
+ ...dns
20644
+ }));
20645
+ applied.push("the new PrivateDnsNameOptions");
20646
+ }
20476
20647
  if (!startAfter) return;
20477
20648
  phase = "start";
20478
20649
  await this.ec2Client.send(new StartInstancesCommand({ InstanceIds: [physicalId] }));
@@ -20504,15 +20675,15 @@ var EC2Provider = class {
20504
20675
  }
20505
20676
  if (startFailure === void 0) {
20506
20677
  instancesLeftStoppedByCdkd.delete(physicalId);
20507
- this.logger.warn(safeMsg`${logicalId}: the InstanceType / UserData change failed after instance ${physicalId} was stopped; cdkd started it again, with ${carries}.`);
20678
+ this.logger.warn(safeMsg`${logicalId}: the ${stopWhat} change failed after instance ${physicalId} was stopped; cdkd started it again, with ${carries}.`);
20508
20679
  } else {
20509
20680
  instancesLeftStoppedByCdkd.add(physicalId);
20510
- this.logger.warn(safeMsg`${logicalId}: instance ${physicalId} was stopped for an InstanceType / UserData change that failed, and starting it again failed too (${describeAwsFailure(startFailure).summary}); it is stopped, with ${carries}. Start it with: ${startCommand}`);
20681
+ this.logger.warn(safeMsg`${logicalId}: instance ${physicalId} was stopped for a ${stopWhat} change that failed, and starting it again failed too (${describeAwsFailure(startFailure).summary}); it is stopped, with ${carries}. Start it with: ${startCommand}`);
20511
20682
  }
20512
20683
  throw error;
20513
20684
  }
20514
20685
  instancesLeftStoppedByCdkd.add(physicalId);
20515
- this.logger.warn(phase === "stop" ? safeMsg`${logicalId}: instance ${physicalId} was being stopped for an InstanceType / UserData change that did not finish. Once it is stopped, start it with: ${startCommand}` : safeMsg`${logicalId}: instance ${physicalId} is stopped, with ${carries}; cdkd did not start it again. Start it with: ${startCommand}`);
20686
+ this.logger.warn(phase === "stop" ? safeMsg`${logicalId}: instance ${physicalId} was being stopped for a ${stopWhat} change that did not finish. Once it is stopped, start it with: ${startCommand}` : safeMsg`${logicalId}: instance ${physicalId} is stopped, with ${carries}; cdkd did not start it again. Start it with: ${startCommand}`);
20516
20687
  throw error;
20517
20688
  }
20518
20689
  }
@@ -20726,9 +20897,14 @@ var EC2Provider = class {
20726
20897
  return Object.keys(result).length > 0 ? result : void 0;
20727
20898
  }
20728
20899
  buildPlacement(properties) {
20900
+ const out = {};
20729
20901
  const az = properties["AvailabilityZone"];
20730
- if (typeof az !== "string" || az === "") return void 0;
20731
- return { AvailabilityZone: az };
20902
+ if (typeof az === "string" && az !== "") out.AvailabilityZone = az;
20903
+ const tenancy = properties["Tenancy"];
20904
+ if (typeof tenancy === "string" && tenancy !== "") out.Tenancy = tenancy;
20905
+ const group = properties["PlacementGroupName"];
20906
+ if (typeof group === "string" && group !== "") out.GroupName = group;
20907
+ return Object.keys(out).length > 0 ? out : void 0;
20732
20908
  }
20733
20909
  buildNetworkInterfaces(properties) {
20734
20910
  const raw = properties["NetworkInterfaces"];
@@ -20789,7 +20965,7 @@ var EC2Provider = class {
20789
20965
  buildLaunchOnlyInstanceOptions(properties, resourceType, logicalId) {
20790
20966
  const cpu = properties["CpuOptions"];
20791
20967
  const hibernation = properties["HibernationOptions"];
20792
- const refusal = configIntegerRefusal(cpu, "CoreCount", `${resourceType} CpuOptions`, 1) ?? configIntegerRefusal(cpu, "ThreadsPerCore", `${resourceType} CpuOptions`, 1) ?? configBooleanRefusal(hibernation, "Configured", `${resourceType} HibernationOptions`) ?? configStringRefusal(properties, "InstanceInitiatedShutdownBehavior", "", resourceType);
20968
+ const refusal = configIntegerRefusal(cpu, "CoreCount", `${resourceType} CpuOptions`, 1) ?? configIntegerRefusal(cpu, "ThreadsPerCore", `${resourceType} CpuOptions`, 1) ?? configBooleanRefusal(hibernation, "Configured", `${resourceType} HibernationOptions`) ?? configStringRefusal(properties, "InstanceInitiatedShutdownBehavior", "", resourceType) ?? configStringRefusal(properties, "Tenancy", "", resourceType) ?? configStringRefusal(properties, "PlacementGroupName", "", resourceType) ?? configStringRefusal(properties, "PrivateIpAddress", "", resourceType) ?? configBooleanRefusal(properties, "SourceDestCheck", resourceType) ?? configBooleanRefusal(properties, "PropagateTagsToVolumeOnCreation", resourceType) ?? configStringRefusal(properties, "AdditionalInfo", "", resourceType) ?? configIntegerRefusal(properties, "Ipv6AddressCount", resourceType, 0) ?? instanceIpv6AddressesRefusal(properties["Ipv6Addresses"], resourceType) ?? privateDnsNameOptionsRefusal(properties["PrivateDnsNameOptions"], resourceType);
20793
20969
  if (refusal !== void 0) throw markNonRetryable(new ProvisioningError(`${refusal}. The instance ${logicalId} was not launched.`, resourceType, logicalId));
20794
20970
  const out = {};
20795
20971
  if (cpu !== void 0 && cpu !== null) {
@@ -20807,6 +20983,16 @@ var EC2Provider = class {
20807
20983
  }
20808
20984
  const shutdown = properties["InstanceInitiatedShutdownBehavior"];
20809
20985
  if (typeof shutdown === "string" && shutdown !== "") out.InstanceInitiatedShutdownBehavior = shutdown;
20986
+ const privateIp = properties["PrivateIpAddress"];
20987
+ if (typeof privateIp === "string" && privateIp !== "") out.PrivateIpAddress = privateIp;
20988
+ const additionalInfo = properties["AdditionalInfo"];
20989
+ if (typeof additionalInfo === "string" && additionalInfo !== "") out.AdditionalInfo = additionalInfo;
20990
+ const ipv6Count = coerceCfnInteger(properties["Ipv6AddressCount"]);
20991
+ if (ipv6Count !== void 0) out.Ipv6AddressCount = ipv6Count;
20992
+ const ipv6Addresses = properties["Ipv6Addresses"];
20993
+ if (Array.isArray(ipv6Addresses)) out.Ipv6Addresses = ipv6Addresses.map((a) => ({ Ipv6Address: a["Ipv6Address"] }));
20994
+ const dnsOptions = privateDnsNameOptionsRequest(properties["PrivateDnsNameOptions"]);
20995
+ if (dnsOptions !== void 0) out.PrivateDnsNameOptions = dnsOptions;
20810
20996
  return out;
20811
20997
  }
20812
20998
  buildIpPermission(properties, direction = "ingress", inline = false) {
@@ -21137,15 +21323,15 @@ var EC2Provider = class {
21137
21323
  }
21138
21324
  }
21139
21325
  }
21140
- async applyTags(resourceId, tags, logicalId, mask) {
21326
+ async applyTags(resourceId, tags, logicalId, mask, wrapSend = (call) => call()) {
21141
21327
  if (tags.length > 0) try {
21142
- await this.ec2Client.send(new CreateTagsCommand({
21328
+ await wrapSend(() => this.ec2Client.send(new CreateTagsCommand({
21143
21329
  Resources: [resourceId],
21144
21330
  Tags: tags.map((t) => ({
21145
21331
  Key: t.Key,
21146
21332
  Value: t.Value
21147
21333
  }))
21148
- }));
21334
+ })));
21149
21335
  this.logger.debug(`Applied ${tags.length} tag(s) to ${logicalId}`);
21150
21336
  } catch (error) {
21151
21337
  const tagHead = `Failed to apply tags to ${logicalId}: `;
@@ -21239,6 +21425,15 @@ var EC2Provider = class {
21239
21425
  if (code === "IncorrectInstanceState" || name === "IncorrectInstanceState") return true;
21240
21426
  return error.message.includes("IncorrectInstanceState");
21241
21427
  }
21428
+ async whileLaunchedInstanceNotVisible(logicalId, instanceId, call) {
21429
+ for (let attempt = 1;; attempt++) try {
21430
+ return await call();
21431
+ } catch (error) {
21432
+ if (attempt >= LAUNCHED_INSTANCE_VISIBILITY_ATTEMPTS || !isNamedError(error, INSTANCE_NOT_FOUND_NAMES)) throw error;
21433
+ this.logger.debug(safeMsg`EC2 Instance ${logicalId} (${instanceId}) is not visible yet after launch (attempt ${String(attempt)}); retrying`);
21434
+ await this.sleep(Math.min(1e3 * 2 ** (attempt - 1), 8e3));
21435
+ }
21436
+ }
21242
21437
  sleep(ms) {
21243
21438
  return new Promise((resolve) => setTimeout(resolve, ms));
21244
21439
  }
@@ -21290,7 +21485,13 @@ var EC2Provider = class {
21290
21485
  }
21291
21486
  getDriftUnknownPaths(resourceType, properties) {
21292
21487
  switch (resourceType) {
21293
- case "AWS::EC2::Instance": return ["NetworkInterfaces"];
21488
+ case "AWS::EC2::Instance": return [
21489
+ "NetworkInterfaces",
21490
+ "PropagateTagsToVolumeOnCreation",
21491
+ "AdditionalInfo",
21492
+ "Ipv6AddressCount",
21493
+ "Ipv6Addresses"
21494
+ ];
21294
21495
  case "AWS::EC2::VPC": {
21295
21496
  const control = properties?.["VpcEncryptionControl"];
21296
21497
  return ["Ipv4IpamPoolId", ...control !== null && typeof control === "object" && control["Mode"] === "monitor" ? VPC_ENCRYPTION_CONTROL_EXCLUSIONS.map((key) => `VpcEncryptionControl.${key}`) : []];
@@ -21459,7 +21660,16 @@ var EC2Provider = class {
21459
21660
  if (Object.keys(cpu).length > 0) result["CpuOptions"] = cpu;
21460
21661
  }
21461
21662
  if (instance.HibernationOptions?.Configured !== void 0) result["HibernationOptions"] = { Configured: instance.HibernationOptions.Configured };
21663
+ const dnsOptions = instance.PrivateDnsNameOptions;
21664
+ if (dnsOptions !== void 0) {
21665
+ const dns = {};
21666
+ if (dnsOptions.HostnameType !== void 0) dns["HostnameType"] = dnsOptions.HostnameType;
21667
+ if (dnsOptions.EnableResourceNameDnsARecord !== void 0) dns["EnableResourceNameDnsARecord"] = dnsOptions.EnableResourceNameDnsARecord;
21668
+ if (dnsOptions.EnableResourceNameDnsAAAARecord !== void 0) dns["EnableResourceNameDnsAAAARecord"] = dnsOptions.EnableResourceNameDnsAAAARecord;
21669
+ if (Object.keys(dns).length > 0) result["PrivateDnsNameOptions"] = dns;
21670
+ }
21462
21671
  if (instance.Placement?.Tenancy !== void 0) result["Tenancy"] = instance.Placement.Tenancy;
21672
+ if (typeof instance.Placement?.GroupName === "string" && instance.Placement.GroupName !== "") result["PlacementGroupName"] = instance.Placement.GroupName;
21463
21673
  if (instance.IamInstanceProfile?.Arn !== void 0) result["IamInstanceProfile"] = instance.IamInstanceProfile.Arn;
21464
21674
  else if (process.env["CDKD_NO_WAIT"] === "true" && instance.State?.Name === "pending") try {
21465
21675
  const live = (await this.ec2Client.send(new DescribeIamInstanceProfileAssociationsCommand({ Filters: [{
@@ -26948,6 +27158,7 @@ var StepFunctionsProvider = class {
26948
27158
  getS3Client() {
26949
27159
  if (!this.s3Client) this.s3Client = new S3Client({
26950
27160
  ...ambientClientDefaults(),
27161
+ ...s3ClientDefaults(),
26951
27162
  ...this.providerRegion ? { region: this.providerRegion } : {}
26952
27163
  });
26953
27164
  return this.s3Client;
@@ -37933,6 +38144,7 @@ var AppSyncProvider = class {
37933
38144
  getS3Client() {
37934
38145
  if (!this.s3Client) this.s3Client = new S3Client({
37935
38146
  ...ambientClientDefaults(),
38147
+ ...s3ClientDefaults(),
37936
38148
  ...this.providerRegion ? { region: this.providerRegion } : {}
37937
38149
  });
37938
38150
  return this.s3Client;
@@ -51465,6 +51677,7 @@ var CodeCommitRepositoryProvider = class {
51465
51677
  getS3Client() {
51466
51678
  if (!this.s3Client) this.s3Client = new S3Client({
51467
51679
  ...ambientClientDefaults(),
51680
+ ...s3ClientDefaults(),
51468
51681
  ...this.providerRegion ? { region: this.providerRegion } : {}
51469
51682
  });
51470
51683
  return this.s3Client;
@@ -52834,6 +53047,7 @@ var S3DirectoryBucketProvider = class {
52834
53047
  getCreateClient() {
52835
53048
  this.createClient ??= this.s3Client.config.region().then((region) => withoutServerErrorRetries(new S3Client({
52836
53049
  ...clientDefaultsFor(this.credentialConfig),
53050
+ ...s3ClientDefaults(),
52837
53051
  region
52838
53052
  })), (error) => {
52839
53053
  this.createClient = void 0;
@@ -55539,4 +55753,4 @@ var ACMCertificateProvider = class {
55539
55753
  };
55540
55754
 
55541
55755
  export { ACMCertificateProvider, ASGProvider, AgentCoreBrowserProvider, AgentCoreCodeInterpreterProvider, AgentCoreEvaluatorProvider, AgentCoreRuntimeProvider, ApiGatewayProvider, ApiGatewayV2Provider, AppSyncProvider, BudgetsBudgetProvider, CloudFrontDistributionProvider, CloudFrontOACProvider, CloudFrontOAIProvider, CloudTrailProvider, CloudWatchAlarmProvider, CloudWatchAnomalyDetectorProvider, CodeBuildProvider, CodeCommitRepositoryProvider, CognitoUserPoolProvider, DLMLifecyclePolicyProvider, DocDBProvider, DocDBSubnetGroupProvider, DynamoDBGlobalTableProvider, DynamoDBTableProvider, EC2Provider, ECRProvider, ECSProvider, EFSProvider, ELBv2Provider, EMRClusterProvider, EMRInstanceFleetConfigProvider, EMRInstanceGroupConfigProvider, ElastiCacheProvider, EventBridgeBusProvider, EventBridgeRuleProvider, FSxFileSystemProvider, FirehoseProvider, GlueConnectionProvider, GlueCrawlerProvider, GlueJobProvider, GlueProvider, GlueSecurityConfigurationProvider, GlueTriggerProvider, GlueWorkflowProvider, IAMAccessKeyProvider, IAMInstanceProfileProvider, IAMManagedPolicyProvider, IAMPolicyProvider, IAMRoleProvider, IAMUserGroupProvider, KMSProvider, KinesisStreamConsumerProvider, KinesisStreamProvider, LambdaEventInvokeConfigProvider, LambdaEventSourceMappingProvider, LambdaFunctionProvider, LambdaLayerVersionProvider, LambdaMicrovmImageProvider, LambdaNetworkConnectorProvider, LambdaPermissionProvider, LambdaUrlProvider, LambdaWebFunctionEndpointProvider, LambdaWebFunctionRevisionProvider, LogsLogGroupProvider, NeptuneProvider, NestedStackProvider, PipesPipeProvider, RDSDBProxyEndpointProvider, RDSDBProxyProvider, RDSDBProxyTargetGroupProvider, RDSProvider, Route53Provider, S3BucketPolicyProvider, S3BucketProvider, S3DirectoryBucketProvider, S3TablesProvider, S3VectorsProvider, SNSSubscriptionProvider, SNSTopicPolicyProvider, SNSTopicProvider, SQSQueuePolicyProvider, SQSQueueProvider, SSMParameterProvider, SchedulerScheduleProvider, SecretsManagerSecretProvider, ServiceDiscoveryProvider, StepFunctionsProvider, WAFv2WebACLProvider, WaitConditionHandleProvider };
55542
- //# sourceMappingURL=provider-classes-CZnJcera.js.map
55756
+ //# sourceMappingURL=provider-classes-Cvc4LfXM.js.map