@cdkd/cli 0.371.1 → 0.373.0
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.
- package/dist/{ambient-client-defaults-Cq58skpK.js → ambient-client-defaults-1yRnA0Re.js} +3 -3
- package/dist/{ambient-client-defaults-Cq58skpK.js.map → ambient-client-defaults-1yRnA0Re.js.map} +1 -1
- package/dist/{asg-provider-B3ngG-X4.js → asg-provider-3uPCjYQK.js} +8 -8
- package/dist/{asg-provider-B3ngG-X4.js.map → asg-provider-3uPCjYQK.js.map} +1 -1
- package/dist/cli.js +3 -3
- package/dist/{created-resource-sink-Bzk9hJNq.js → created-resource-sink-CBOr1ShX.js} +4 -4
- package/dist/{created-resource-sink-Bzk9hJNq.js.map → created-resource-sink-CBOr1ShX.js.map} +1 -1
- package/dist/{custom-resource-runtime-CLHhYoEe.js → custom-resource-runtime-DURpNFOa.js} +6 -6
- package/dist/{custom-resource-runtime-CLHhYoEe.js.map → custom-resource-runtime-DURpNFOa.js.map} +1 -1
- package/dist/{db-associated-roles-CYA2C3yZ.js → db-associated-roles-BbvtfXqW.js} +2 -2
- package/dist/{db-associated-roles-CYA2C3yZ.js.map → db-associated-roles-BbvtfXqW.js.map} +1 -1
- package/dist/{delete-started-D9FEXTba.js → delete-started-yz9plykR.js} +4 -4
- package/dist/{delete-started-D9FEXTba.js.map → delete-started-yz9plykR.js.map} +1 -1
- package/dist/{deploy-engine-DvPDae31.js → deploy-engine-C12Ygjb-.js} +4553 -777
- package/dist/deploy-engine-C12Ygjb-.js.map +1 -0
- package/dist/{ec2-termination-protection-C19A5IH9.js → ec2-termination-protection-UZAZ2Hzv.js} +3 -3
- package/dist/{ec2-termination-protection-C19A5IH9.js.map → ec2-termination-protection-UZAZ2Hzv.js.map} +1 -1
- package/dist/{ecr-uri-BW6V_9R5.js → ecr-uri-C74u9FtL.js} +2 -2
- package/dist/{ecr-uri-BW6V_9R5.js.map → ecr-uri-C74u9FtL.js.map} +1 -1
- package/dist/{emr-cluster-provider-DVljF3YH.js → emr-cluster-provider-2ezuxbz3.js} +10 -10
- package/dist/{emr-cluster-provider-DVljF3YH.js.map → emr-cluster-provider-2ezuxbz3.js.map} +1 -1
- package/dist/{expected-bucket-owner-DMq5H0Zm.js → expected-bucket-owner-0yx_Q4Hl.js} +2 -2
- package/dist/{expected-bucket-owner-DMq5H0Zm.js.map → expected-bucket-owner-0yx_Q4Hl.js.map} +1 -1
- package/dist/{iam-role-provider-B8c2g5fS.js → iam-role-provider-CZtZQJRp.js} +12 -12
- package/dist/{iam-role-provider-B8c2g5fS.js.map → iam-role-provider-CZtZQJRp.js.map} +1 -1
- package/dist/{identity-read-denied-Cl8km1o3.js → identity-read-denied-DBsqwW85.js} +5 -5
- package/dist/{identity-read-denied-Cl8km1o3.js.map → identity-read-denied-DBsqwW85.js.map} +1 -1
- package/dist/{image-plan-Cg5bLNvP.js → image-plan-DW_fg6mx.js} +20 -12
- package/dist/image-plan-DW_fg6mx.js.map +1 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -5
- package/dist/{logger-BUi1Imxa.js → logger-JtU7m4ph.js} +2 -2
- package/dist/{logger-BUi1Imxa.js.map → logger-JtU7m4ph.js.map} +1 -1
- package/dist/{neptune-provider-Ddse7yYJ.js → neptune-provider-ClT-eveS.js} +9 -9
- package/dist/{neptune-provider-Ddse7yYJ.js.map → neptune-provider-ClT-eveS.js.map} +1 -1
- package/dist/{program-bUaiwzJ2.js → program-BPrn1MhZ.js} +508 -790
- package/dist/program-BPrn1MhZ.js.map +1 -0
- package/dist/{provider-classes-AI1PLFRf.js → provider-classes-Bi3D5zDS.js} +22 -22
- package/dist/{provider-classes-AI1PLFRf.js.map → provider-classes-Bi3D5zDS.js.map} +1 -1
- package/dist/{rds-provider-6Cj8pik8.js → rds-provider-D610vnfB.js} +13 -13
- package/dist/{rds-provider-6Cj8pik8.js.map → rds-provider-D610vnfB.js.map} +1 -1
- package/dist/{read-replica-DWbYq3Fh.js → read-replica-Br2tFu0d.js} +3 -3
- package/dist/{read-replica-DWbYq3Fh.js.map → read-replica-Br2tFu0d.js.map} +1 -1
- package/dist/{redacted-delete-address-C1M-bYXm.js → redacted-delete-address-DVgNoeo4.js} +4 -4
- package/dist/{redacted-delete-address-C1M-bYXm.js.map → redacted-delete-address-DVgNoeo4.js.map} +1 -1
- package/dist/{replacement-rules-BimJi0H1.js → replacement-rules-BoZMVFdK.js} +2166 -1663
- package/dist/replacement-rules-BoZMVFdK.js.map +1 -0
- package/dist/{resource-deadline-Cj-4PzvY.js → resource-deadline-BkQ9mJAk.js} +2 -2
- package/dist/{resource-deadline-Cj-4PzvY.js.map → resource-deadline-BkQ9mJAk.js.map} +1 -1
- package/dist/{restore-source-guard-CP2cxnnh.js → restore-source-guard-BkS5tGr5.js} +4 -4
- package/dist/{restore-source-guard-CP2cxnnh.js.map → restore-source-guard-BkS5tGr5.js.map} +1 -1
- package/dist/{run-cli-C0ZXPvze.js → run-cli-Ds9QnqnH.js} +2 -2
- package/dist/{run-cli-C0ZXPvze.js.map → run-cli-Ds9QnqnH.js.map} +1 -1
- package/dist/{secret-reference-immutable-BLsAuIkM.js → secret-reference-immutable-BC4abPuQ.js} +20 -11
- package/dist/secret-reference-immutable-BC4abPuQ.js.map +1 -0
- package/dist/{settle-own-write-members-BJ1rf1Yt.js → settle-own-write-members-D6wzEt7f.js} +13 -771
- package/dist/settle-own-write-members-D6wzEt7f.js.map +1 -0
- package/dist/{tag-list-CSQWFQbX.js → tag-list-UEcqQLzY.js} +4 -4
- package/dist/{tag-list-CSQWFQbX.js.map → tag-list-UEcqQLzY.js.map} +1 -1
- package/dist/{version-CQenoJzP.js → version-Dn0kzidt.js} +2 -2
- package/dist/{version-CQenoJzP.js.map → version-Dn0kzidt.js.map} +1 -1
- package/package.json +1 -1
- package/dist/deploy-engine-DvPDae31.js.map +0 -1
- package/dist/image-plan-Cg5bLNvP.js.map +0 -1
- package/dist/program-bUaiwzJ2.js.map +0 -1
- package/dist/replacement-rules-BimJi0H1.js.map +0 -1
- package/dist/secret-reference-immutable-BLsAuIkM.js.map +0 -1
- package/dist/settle-own-write-members-BJ1rf1Yt.js.map +0 -1
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { A as displayStackName, C as STACK_REF_MAX_CODE_POINTS, D as displayAwsMessage, E as cutMarker, F as stringifyJsonPayload, I as terminalSafe, L as truncateCodePoints, N as plainIdentOr, O as displayIdent, P as safeMsg, S as SECRET_REF_MAX_CODE_POINTS, T as asIsMessage, _ as shellQuote, b as setPasteableVerbFlags, c as deployReplaceCommand, d as pasteableCommand, g as shellBoundedDisplay, h as quotedOrDescribed, i as SHELL_ACTIVE_WHY, j as isPasteableIdent, k as displaySafe, m as proseQuoted, o as cdkdRemedy, p as plainOrDescribed, s as commandHole, t as getCdkdVersion, u as isInertUnquoted, v as withheldTargetClause, w as UNRENDERABLE, x as SAFE_MSG_ALTERED_CHAR, y as setPasteableRunFlags } from "./version-
|
|
2
|
-
import { $ as renderStacksNoLongerSelected, $t as contextOptions, A as followContainerLogs, At as namedEnvAwsRegion, B as resolveRuntimeCodeMountPath, Bt as regionNeedsReconciliation, C as waitForRieReady, Cn as
|
|
3
|
-
import { $t as buildLockContentionMessage, At as resourceTypeShown, C as VALUE_NOT_SHOWN, It as maskDeep, M as remedyLogicalId, Ot as logicalIdShown, P as isMarkedNotGone, Q as runDeleteAttempt, Qt as buildForceUnlockCommand, St as isInterruptedWaitError, Zt as UNREPRODUCIBLE_LOCK_CLAUSE, at as isAwsCliLiteral, b as assertRegionMatch, bt as endCommandInterruptScope, cn as WAIT_CONDITION_SIGNAL_PREFIX, ct as renderDisableCommand, dn as withPasteableAwsProfile, en as forceQuitRecoveryClause, fn as injectiveKey, gt as readRecordedPrincipals, hn as producerRecordKey, ln as setPasteableAwsCaBundle, lt as IAM_PRINCIPAL_NAME, mn as producerCoordinateKey, nn as formatLockOperation, on as CUSTOM_RESOURCE_RESPONSE_PREFIX, rn as formatLockOwner, sn as DEFAULT_STATE_PREFIX, tn as formatLockExpiry, un as setPasteableAwsProfile, ut as RESOLVED_PREVIOUS_PRINCIPAL_KEYS, v as DriftReadRefusedError, xt as interruptWatchListenerCount, y as RESOURCE_NOT_FOUND, yt as beginCommandInterruptScope } from "./created-resource-sink-
|
|
1
|
+
import { A as displayStackName, C as STACK_REF_MAX_CODE_POINTS, D as displayAwsMessage, E as cutMarker, F as stringifyJsonPayload, I as terminalSafe, L as truncateCodePoints, N as plainIdentOr, O as displayIdent, P as safeMsg, S as SECRET_REF_MAX_CODE_POINTS, T as asIsMessage, _ as shellQuote, b as setPasteableVerbFlags, c as deployReplaceCommand, d as pasteableCommand, g as shellBoundedDisplay, h as quotedOrDescribed, i as SHELL_ACTIVE_WHY, j as isPasteableIdent, k as displaySafe, m as proseQuoted, o as cdkdRemedy, p as plainOrDescribed, s as commandHole, t as getCdkdVersion, u as isInertUnquoted, v as withheldTargetClause, w as UNRENDERABLE, x as SAFE_MSG_ALTERED_CHAR, y as setPasteableRunFlags } from "./version-Dn0kzidt.js";
|
|
2
|
+
import { $ as renderStacksNoLongerSelected, $t as contextOptions, A as followContainerLogs, An as parseStateKey, At as namedEnvAwsRegion, B as resolveRuntimeCodeMountPath, Bt as regionNeedsReconciliation, C as waitForRieReady, Cn as parsePositiveIntegerOption, Ct as resolveContainerRegion, Dn as describeStateKey, Dt as warnAwsEmulatorStateSourceHint, E as SENSITIVE_ENV_KEYS, En as STATE_KEY_MAX_CODE_POINTS, Et as taskRoleAssumedInRealAws, F as removeContainer, Ft as legacyStateBucketFallbackRegion, G as nestedOwnerOfLogicalId, Gt as withOtherIndexRemoval, H as resolveRuntimeImage, Ht as resolveEffectiveRegion, It as namedCliRegion, J as renderAllLeftOutStageStacks, Jt as annotationMessageOptions, K as partitionTopLevel, Kt as strandedProfileCredentialsNotice, L as runDetached, Lt as rawCliRegion, M as killAndDrainContainerLogs, Mt as adoptRegionFlag, N as pickFreePort, Nt as exportInferredRegionForSdk, O as ensureDockerAvailable, On as listAllLockKeys, Ot as workloadGetsEmulatorKeysOnly, P as pullImage, Pt as foldRegionOption, Q as renderNotInAppWarning, Qt as commonOptions, Rt as reconcileExportIndexRegion, S as invokeRie, Sn as cliArgParser, St as realAwsException, T as DockerRunnerError, Tn as STATE_FILE_SUFFIX, Tt as stateRoleRecordIsEmulatorSide, U as describeStack, Ut as stackRegionResolver, V as resolveRuntimeFileExtension, Vt as regionShown, W as matchStacks, Wt as stateWithRegion, X as renderAmbiguousTargetStack, Xt as applyWaitFlagEnv, Y as renderAllNoTopLevelStacks, Yt as appOptions, Z as renderNoStackMatch, Zt as collectRepeated, _ as probeHostGatewaySupport, _n as allowUnsupportedTypesOption, _t as localAwsEmulatorCredentials, a as materializeLayerFromArn, an as noCfnFallbackOption, at as unmatchedPatterns, b as substituteImagePlaceholders, bn as resourceTimeoutOptions, bt as prepareLocalLoopbackForwarder, cn as parseStackRegion, ct as resolveCdkPathToLogicalIds, d as resolveAssetCodeDirectory, dn as stackOptions, dt as activateLocalAwsAndRoleArn, en as deployOptions, et as renderUnmatchedPatternsWarning, f as architectureToPlatform, fn as stateOptions, ft as assertAwsEmulatorValue, g as HOST_GATEWAY_MIN_VERSION, gn as parseAssumeRoleToken, gt as localAwsEmulatorActive, h as layerAssetDirectory, hn as normalizeStartApiAssumeRole, ht as keepEmulatorIssuedCredentials, i as resolveInlineCodeFilePath, in as guardStackRegionOptions, it as stacksNoLongerSelected, jt as recordEmulatorDefaultRegion, k as flushStdio, kn as listAllStateKeys, kt as emulatorDefaultRegion, l as resolveLambdaLayers, ln as regionOption, lt as stackForConstructPath, m as copyLayerTreeLastWins, mn as effectiveAssumeRoleArn, mt as getActiveWorkloadAwsWiring$1, n as resolveTmpfsForLambda, nn as diffUpdatePolicyOptions, nt as stackMatchesPattern, o as resolveLambdaTarget, on as noLocalCustomResourcesOption, ot as buildCdkPathIndex, p as buildContainerImage$1, pn as useCdkBootstrapAssetsOption, pt as attachLocalLoopbackForwarder, q as refuseStackNameRegionCollisions, qt as writeProfileCredentialsFile, r as resolveZipImagePlan, rn as exclusivelyOption, rt as stacksForDependency, s as extractEphemeralStorageMb, sn as parseContextOptions, st as readCdkPathOrUndefined, t as resolveLocalBuildPlan$1, tn as destroyOptions, tt as selectTargetStack, u as assetPathDirs, un as skipFinalSnapshotOption, ut as stackForPathFormTarget, v as resolveHostGatewayExtraHosts, vn as diffReplaceResourceOption, vt as mixedModeActive, w as CONTAINER_LOG_DRAIN_TIMEOUT_MS, wn as LOCK_FILE_SUFFIX, wt as setContainerRegion, x as tryResolveImageFnJoin, xn as validateResourceTimeouts, xt as profileCredentialsForWorkload, y as derivePseudoParametersFromRegion$1, yn as parseDuration, yt as mixedModeEmulatorOverride, z as streamLogs, zt as reconcileMarkerRegionWithLegacyDefault } from "./image-plan-DW_fg6mx.js";
|
|
3
|
+
import { $t as buildLockContentionMessage, At as resourceTypeShown, C as VALUE_NOT_SHOWN, It as maskDeep, M as remedyLogicalId, Ot as logicalIdShown, P as isMarkedNotGone, Q as runDeleteAttempt, Qt as buildForceUnlockCommand, St as isInterruptedWaitError, Zt as UNREPRODUCIBLE_LOCK_CLAUSE, at as isAwsCliLiteral, b as assertRegionMatch, bt as endCommandInterruptScope, cn as WAIT_CONDITION_SIGNAL_PREFIX, ct as renderDisableCommand, dn as withPasteableAwsProfile, en as forceQuitRecoveryClause, fn as injectiveKey, gt as readRecordedPrincipals, hn as producerRecordKey, ln as setPasteableAwsCaBundle, lt as IAM_PRINCIPAL_NAME, mn as producerCoordinateKey, nn as formatLockOperation, on as CUSTOM_RESOURCE_RESPONSE_PREFIX, rn as formatLockOwner, sn as DEFAULT_STATE_PREFIX, tn as formatLockExpiry, un as setPasteableAwsProfile, ut as RESOLVED_PREVIOUS_PRINCIPAL_KEYS, v as DriftReadRefusedError, xt as interruptWatchListenerCount, y as RESOURCE_NOT_FOUND, yt as beginCommandInterruptScope } from "./created-resource-sink-CBOr1ShX.js";
|
|
4
4
|
import { a as runWithStackAwsClients, i as resetAwsClients, l as s3ClientDefaults, o as setAwsClients, s as resolveS3ClientDefaults, t as AwsClients, u as setS3ClientDefaultsDebugLog } from "./aws-clients-DOkPjjAW.js";
|
|
5
|
-
import { $ as withStackScope, A as configStringRefusal, B as generateResourceName, E as coerceCfnBoolean, F as requireConfigString, I as PATTERN_B_NAME_OPTIONS, L as PATTERN_B_NAME_PROPERTIES, N as requireConfigArray, O as configBooleanRefusal, P as requireConfigObject, Q as withSkipPrefix, R as PATTERN_B_RESOURCE_TYPES, S as explicitNamePropertyFor, X as isNameGeneration, a as reserveStdoutForPayload, f as isAwsAuthoredFailure, i as releaseStdoutForPayload, m as verboseAwareText, n as getLogger, p as safeStringify, r as isStdoutReservedForPayload, s as runStackBuffered, u as describeAwsFailure, y as getLiveRenderer, z as derivesPatternBName } from "./logger-
|
|
6
|
-
import { A as stripControlChars, B as retryClassificationText, F as isAmbiguousOutcomeError, H as isMarkedNonRetryable, J as DynamicReferenceRegionAmbiguousError, Q as AccountIdUnavailableError, R as isRetryableTransientError, U as isThrottlingError, V as THROTTLING_ERROR_NAMES, W as markNonRetryable, X as MalformedProducerRecordRefusalError, Y as IntrinsicResolutionRefusalError, _ as ResourceUpdateNotSupportedError, a as normalizeAwsError, at as ProvisioningError, ct as SynthesisError, et as CdkdError, g as PartialFailureError, h as NestedStackChildDirectDestroyError, i as credentialFingerprint, j as stripForDisplay, k as escapeRegExp, l as withErrorHandling, n as ambientCredentialConfig, o as formatError, ot as ResourceTimeoutError, q as CrossAccountSecretRefusalError, r as clientDefaultsFor, rt as LocalInvokeBuildError$1, s as handleError, st as StateError, t as ambientClientDefaults, tt as DeployCancelledError, u as LocalStartServiceError, v as StackHasActiveImportsError, y as StackTerminationProtectionError, z as isTransientServerError } from "./ambient-client-defaults-
|
|
5
|
+
import { $ as withStackScope, A as configStringRefusal, B as generateResourceName, E as coerceCfnBoolean, F as requireConfigString, I as PATTERN_B_NAME_OPTIONS, L as PATTERN_B_NAME_PROPERTIES, N as requireConfigArray, O as configBooleanRefusal, P as requireConfigObject, Q as withSkipPrefix, R as PATTERN_B_RESOURCE_TYPES, S as explicitNamePropertyFor, X as isNameGeneration, a as reserveStdoutForPayload, f as isAwsAuthoredFailure, i as releaseStdoutForPayload, m as verboseAwareText, n as getLogger, p as safeStringify, r as isStdoutReservedForPayload, s as runStackBuffered, u as describeAwsFailure, y as getLiveRenderer, z as derivesPatternBName } from "./logger-JtU7m4ph.js";
|
|
6
|
+
import { A as stripControlChars, B as retryClassificationText, F as isAmbiguousOutcomeError, H as isMarkedNonRetryable, J as DynamicReferenceRegionAmbiguousError, Q as AccountIdUnavailableError, R as isRetryableTransientError, U as isThrottlingError, V as THROTTLING_ERROR_NAMES, W as markNonRetryable, X as MalformedProducerRecordRefusalError, Y as IntrinsicResolutionRefusalError, _ as ResourceUpdateNotSupportedError, a as normalizeAwsError, at as ProvisioningError, ct as SynthesisError, et as CdkdError, g as PartialFailureError, h as NestedStackChildDirectDestroyError, i as credentialFingerprint, j as stripForDisplay, k as escapeRegExp, l as withErrorHandling, n as ambientCredentialConfig, o as formatError, ot as ResourceTimeoutError, q as CrossAccountSecretRefusalError, r as clientDefaultsFor, rt as LocalInvokeBuildError$1, s as handleError, st as StateError, t as ambientClientDefaults, tt as DeployCancelledError, u as LocalStartServiceError, v as StackHasActiveImportsError, y as StackTerminationProtectionError, z as isTransientServerError } from "./ambient-client-defaults-1yRnA0Re.js";
|
|
7
7
|
import { a as getAssumedRoleCredentials, c as setAssumedRoleCredentials, h as formatAuthority, l as setAwsEndpointOverrideSource, m as runInStackAwsScope, n as awsClientDefaults, r as awsEndpointOverrideActive, s as runWithRealAws } from "./aws-client-defaults-DAebi99J.js";
|
|
8
|
-
import { $ as
|
|
9
|
-
import { $a as maskEventTextWithBoundBags, $d as validateAssetBucketName, $i as retiredNameGenerationsLeaving, $l as UNREADABLE_ORPHANS_CONTAINER_ROW, $o as WaitConditionSignalStore, $s as classifyRecordedSecretRegion, $u as readOnlyStateVersionOf, A as deferredServiceTokenWarning, Aa as supersededHeldByOtherTypeWarning, Ac as withoutVersionAttestation, Ad as createLazyAssetModeContext, Al as unreadableOrphanRecords, An as sameMove, Ar as hintSidesOf, As as isWaitAbandonedError, Au as displayLogicalId, Ba as cyan, Bi as IMPLICIT_DELETE_DEPENDENCIES, Bl as refuseMalformedResourceEntriesForImport, Bn as readsOnlyNoEchoParameters, Bo as memberReadFailure, Br as mappingPairs, Bs as producerLookupOver, Bu as NO_CC_HANDLERS_REASON, C as warnLegacySpelling, Ca as DEFAULT_RESOURCE_WARN_AFTER_MS, Cc as keepHeldTokenProvenance, Cd as CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION, Ci as updatePartialReason, Cl as malformedOrphanRowsKeptWarning, Cn as keptForRetainedRecord, Cr as noEchoValueMacsOf, Cs as RollbackInlinePolicyWriters, Cu as refuseMalformedState, D as slashedSsmNameHealPendingNote, Da as isSupersededResourceRecord, Dc as recordedReferenceRegions, Di as ledgerForStack, Dl as refuseMalformedOrphansForOrphan, Dn as refactorMarkerMovesOf, Do as destroyStackRecordsView, Dr as formatDestructiveChange, Ds as deleteSkipReason, Du as withheldAccountClause, E as slashedSsmNameHealNote, Ea as holdsSupersededResources, El as refuseMalformedOrphanRecordsForDestroy, En as readRefactorMarkerOnce, Er as formatChangeCounts, Es as deleteLeftInPlace, Eu as accountArgs, F as recordedProtectionNote, Fa as snapshotSegmentSurvivors, Fc as carriesDynamicReference, Fi as isReplacementOrphan, Fl as malformedScrubResourceEntriesRefusalMessage, Fn as settleStackTagChildRuns, Fr as changedReferencePath, Fs as poisonRenderedSpellingsCollidingIn, Ga as noEchoAttributeNamesOf, Gd as AssetModeResolver, Gi as removeProtectionTypeList, Gl as malformedDriftResourcePropertiesWarning, Gn as resolvePendingCloudControlRequests, Go as verbatimEchoDriftKeys, Gr as siblingOwnedRevertDesired, Gs as explicitRoleArnOrThrow, Ha as green, Hi as attemptUsesCompletedCreate, Hl as refuseMalformedResourceEntriesForOrphan, Hn as formatResourceLine, Ho as reReadUntilSettled, Hr as propertiesChangedReason, Hs as applyRoleArnIfSet, Hu as PROPERTY_COVERAGE_BY_TYPE, I as PROTECTION_PROPERTY_BY_TYPE, Ia as resolveReplacementOldType, Ic as keepsSecretReferenceToken, Ii as planFailedOps, Il as refuseMalformedResourceAttributesForOrphan, Io as declaredMemberDocument, Ir as changedReferenceReason, Is as stackIdTailOf, It as tagsMatchDeclared, Iu as unwrittenCreateOnlyReplacement, Ja as noEchoParameterNamesOf, Jc as shownType, Jd as assertAssetBucketRegion, Ji as nameGenerationCarriedFrom, Jl as refuseMalformedResourcePropertiesForDestroy, Jn as displacedPhysicalIdShown, Jo as CC_BROKEN_REASON, Jr as recordedRuleIdOf, Js as sendableAssumeRoleCommand, K as readStreamPolicy, Ka as noEchoComparisonForTemplate, Kc as findReplacedReadersOfRecreateTargets, Kd as ensureAssetStorage, Ki as removeProtectionTypes, Kl as malformedResourcePropertiesWarning, Kn as NESTED_PENDING_PARENT_REASON, Kr as stripSiblingOwnedParentMembers, Ks as isIamRoleArn, L as isProtectionValueActive, La as withPreviousPolicies, Lc as withSharedDrainBudget, Ld as rewriteTemplateAssetReferences, Li as recheckFailedPlan, Ll as refuseMalformedResourceEntries, Ln as childStackTags, Lo as declaredPolicyDocument, Lr as differingRemedy, M as serviceTokenBlockingReason, Ma as supersededResourcesOf, Mc as isImpossibleEmptyStoredAttribute, Mi as seedsDeleteFirstGuard, Ml as malformedLocalResourceEntriesWarning, Mn as deleteSignalReceiver, Mr as rollbackOrphanIds, Ms as IntrinsicFunctionResolver, Mt as declaredTagsReadback, Mu as hasReadableResources, N as diffSecurity, Na as withoutSuperseded, Nc as carriesFetchableDynamicReference, Ni as demoteSupersededOrphans, Nl as malformedLocalResourcesWarning, Nn as isReceiver, No as LAMBDA_PERMISSION_STATEMENT_KEYS, Nr as withMovedTo, Ns as isSelectOutOfBounds, Nu as findActionableSdkUnwired, O as scanActiveConsumers, Oa as supersededAfterRollback, Od as buildAssetRedirectMap, Ol as repairMalformedOrphanRecordsForReadOnly, On as refactorMarkerRefusalMessage, Or as orphanedLogicalIds, Ou as STATE_RESOURCES_MALFORMED, P as recordedProtectionEvidence, Pc as isNamelessDynamicReferenceError, Pd as loadPublishableAssetManifest, Pi as isJournaledOrphan, Pl as malformedResourceEntriesWarning, Pn as removeSignalReceiverNamed, Pr as changedReferenceInDiff, Ps as isAlwaysLiveAttribute, Pu as findHandledUnwrittenCreateOnly, Qa as journaledOrphanPrintingBag, Qc as renderStatefulReason, Qd as readBootstrapMarkerBody, Qi as retiredNameGenerationsAfter, Ql as repairMalformedResourcePropertiesForReadOnly, Qn as recordDisplacedSkips, Qo as wouldReturnToSdkProvider, Qr as siblingRecordedSgRuleIds, Qs as envCredentialsAreAssumedRole, R as perType, Ra as findNestedStackTypeChanges, Rd as AssetManifestLoader, Ri as recordUnderIdIsNotOwn, Rl as refuseMalformedResourceEntriesForDeploy, Rn as literalRowTags, Ro as efsPolicyMatchesDeclared, Rr as isPairableType, S as refusePendingMovesOut, Sa as DEFAULT_RESOURCE_TIMEOUT_MS, Sd as ssmResolvedValueType, Si as updatePartialMessage, Sl as malformedOrphanRecordsWarning, Sn as NestedCleanupQueue, Sr as noEchoMacVerdict, Su as refuseMalformedResourcesForExport, T as slashedSsmNameHealAdoptedNote, Ta as deleteSupersededEntry, Tc as recordedOutputReferenceRegions, Td as decodeListingKey, Ti as replacementCreateRoutesToCloudControl, Tl as refuseMalformedOrphanRecords, Tn as readRefactorMarker, Tr as findDestructiveChanges, Ts as deleteIndeterminateGuards, Tu as JSON_LISTING_HOLE_VALUE, Ua as red, Ui as readsRegeneratingSecret, Ul as repairMalformedResourceEntriesForReadOnly, Un as startForceQuitFlushes, Ur as proposeRenames, Us as assertFlagRoleArn, Va as gray, Vi as computeImplicitDeleteEdges, Vl as refuseMalformedResourceEntriesForImportSave, Vo as policyDocumentMatchesDeclared, Vr as parseMappingFile, Vs as refuseUnreadableCdkCrossAccountRefs, Vu as hasNoCloudControlHandlers, Wa as yellow, Wi as segmentCleanupOptions, Wl as unreadableResourceEntries, Wn as pendingRequestCount, Wr as referencedLogicalIds, Ws as assertSendableRoleArn, Wu as providerReplacementOldDeleted, Xa as createReadOnlyAttributeHealerFactory, Xc as isStatefulRecreateTargetForReplace, Xd as getBootstrapMarkerKey, Xi as nameScopeOf, Xl as refuseMalformedResourcePropertiesForExport, Xo as ccBrokenReason, Xr as sgSiblingDecidedById, Xs as applyCallerIdentityCredentials, Xu as S3StateBackend, Ya as withAttemptedItemsMasked, Yc as MULTI_REGION_RECREATE_BLOCKED_TYPES, Yd as isCrossRegionRedirect, Yi as nameGenerationHighWaterOf, Yl as refuseMalformedResourcePropertiesForDrift, Yn as dropSettledNestedJournals, Yo as ProviderRegistry, Yr as sgRuleOwnershipIdentity, Ys as AWS_CREDENTIAL_ENV_KEYS, Yu as TemplateParser, Z as streamPolicyMatchesDeclared, Za as completedReplayEntries, Zc as isStatefulRecreateTargetSync, Zd as parseBootstrapMarker, Zi as retiredAfterRollback, Zl as refuseMalformedResourcePropertiesForOrphan, Zn as nestedChildStackName$1, Zo as isCustomResource, Zs as callerEnvCredentials, Zu as splitImportedOps, _ as readRecordedConditionVerdicts, _a as noEchoParameterValueSeed, _c as refStateLookupFromResource, _d as listNestedTemplateRows, _f as resolveBucketRegion, _i as withUnprovenUnsettled, _l as declaresNoEcho, _o as unsupportedFinalSnapshotError, _r as crossStackReadsForPartialSave, _u as malformedRenderedContainersWarning, a as mergeNoChangeOutputs, aa as reachableDivergentParameters, ad as applyCrossPrefixScan, af as hasOwnKey, al as secretPhysicalIdSegment, ao as secretNamedRecordNeedles, ar as deleteJournaledOrphans, as as customResourceResponseExpirationWarning, au as repairMalformedOrphansForReadOnly, b as pendingMovesOutOf, ba as isExportAliasCollision, bi as equalModuloMask, bl as isReadableOrphanRecord, br as noEchoMacBinding, bu as refuseMalformedResourcesForDeploy, c as nestedSsmNameRowNote, ca as displayTextOrWithheld, cd as isNotImplemented, cf as ownValue, ci as replayFailedOperations, cl as getSettledWriteOnlyPropertyPaths, co as storedSecretNameNeedles, cr as isHandledOrphan, cs as readsNoEchoDeleteValues, cu as malformedLocalOutputsWarning, d as makeCanonicalizePropertiesFn, da as secretBearingStateKeyWarning, dc as coerceParameterTypedValue, dd as isSecretValuedAttribute, df as describeFileReadFailure, di as PLANNED_EARLY_DELETE_CONSEQUENCE, do as PRE_DELETE_SNAPSHOT_TYPES, dr as sameJournaledOrphans, ds as withPrintingSecrets, ea as withNameGenerationReached, ec as classifyReplaySecretRegion, ed as hasReasonlessBaselineRefusal, ef as validateContainerRepoName, eo as namingSecretsWithRecordedNoEcho, er as revertedNestedRowIds, es as classifyHandleUrl, eu as hasReadableOrphans, f as readDbInstanceAvailabilityZone, fa as secretSafeKeyDisplay, fc as isUnboundTemplateParameter, fd as isSensitiveAttributeName, ff as displayAssemblyPath, fi as earlyDeleteWhen, fl as maskedPropertyFingerprintsOf, fo as ccRoutedFinalSnapshotError, fr as makeForeignHolderScan, fs as NO_LOCAL_CUSTOM_RESOURCES_FLAG, fu as refuseMalformedOutputs, g as parentSuppliedValues, ga as isWholeDynamicReferenceValue, gc as isStalePlaceholderArnAttribute, gd as isAbsoluteAssetPath, gi as settleUnsettledPrevious, go as refusesFinalSnapshot, gr as DeploymentEventsStore, gs as localCustomResourceCommand, gu as refuseDivergentRecordRegionForDestroy, h as conditionInputsFrom, ha as exportNameSecretExposure, hc as cfnRefValueFromPhysicalId, hd as findNestedTemplateTreeDefect, hf as resolveAssemblyPath, hi as recordAfterRollbackUpdate, hl as maskedInputProof, ho as isFinalSnapshotError, hr as DeploymentEventsReader, hs as customResourcesRunWithoutApp, hu as STATE_REGION_DIVERGED, i as keptWholeReasonText, ia as namesAnyDeclaredParameter, ic as isUnexposedRecordedIdentity, id as CrossPrefixScanCache, if as defineOwnKey, ii as sgProtocolKey, ir as withNestedStackContext, is as applyCustomResourceResponseExpiration, iu as refuseMalformedOrphansForDestroy, j as findServiceTokenRefusals, ja as supersededHolderOf, jc as getAccountInfo, ji as planRollback, jl as isReadableResourceEntry, jn as updateRefactorMarker, jo as withStackRecords, jr as movedToHint, ju as hasReadableOutputs, k as inRunStackKey, ka as supersededDependentsFirst, kd as createAssetRedirectResolver, ki as withCreateTokenLedger, kl as unpreviewableOrphanRecords, kn as refuseRefactorMarker, ko as revertStackRecordsView, kr as findRefactorHints, ks as getReadOnlyPropertyPaths, ku as UNREADABLE_RESOURCES_MAP_ROW, l as crossStackOutputProvenanceSource, la as exportAliasCollisionScrubWarning, ld as stackInstanceIdOf, li as replayRollback, ll as getTopLevelKeysHoldingUnreadableCreateOnly, lo as extractDeploymentEventError, lr as journaledOrphanLines, ls as isCustomResourceType$1, lu as malformedOutputsRefusalMessage, m as conditionFingerprint, ma as exportNameNoEchoParameters, mc as AWS_NO_VALUE, mf as renderAssemblyPathEscape, mi as buildReadCurrentStateContext, ml as parameterInputsFor, mo as effectiveDeletionPolicy, mr as planOrphanAdoption, ms as customResourcesFailedWithoutApp, mu as repairMalformedOutputsForReadOnly, n as applyStackTagsToTemplate, na as inheritProducerRegions, nc as regionLessSecretName, nd as rebuildClientForBucketRegion, ni as recordedSgRuleId, no as secretNamePrintingBag, nr as collectNestedChildUnaddressed, ns as isSignalKey, nu as malformedOrphansWarning, o as checkNestedSsmNames, oa as resourcesNamingDeclaredParameter, od as crossPrefixDeniedWarning, of as hasPlainPrototype, oi as canonicalizeIpv4Cidr, ol as secretSegmentsOfState, oo as stackSecretNamesMasker, or as dropFailedCommands, ou as malformedExportNamesWarning, p as healZonelessDbInstanceRecords, pa as carriedExportAliasExposure, pc as parameterTypeMayLoseSecretIdentity, pi as earlyDeletedOld, po as ccRoutedInstanceTakesNoSnapshot, pr as makeSiblingClaimReader, pu as refuseMalformedOutputsForDestroy, qa as noEchoExactEchoLeavesOf, qd as buildDenyExternalAccessPolicy, qi as orphanNeedsIdentity, qn as displacedOpClause, qr as undeclaredGrantSiblingMembers, qs as parseIamRoleArn, r as isSecretBearingReferenceString, ra as computeParameterTaint, rc as withoutLapsedStaleShapeStamp, rd as CrossPrefixReadError, ri as sgCidrKey, rl as displayPhysicalId, ro as secretNamePrintingBags, rr as getCurrentNestedStackContext, rs as CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID, ru as refuseMalformedOrphans, s as nestedSsmNameDeferredNote, sa as WITHHELD_NAME_DISPLAY, sd as isAccessDenied, sf as nullPrototypeRecord, si as canonicalizeIpProtocolValue, sl as withSecretPhysicalIdsMaskedInState, so as stateSecretNameNeedles, sr as dropFailedHint, ss as TemplateNoEchoReresolver, su as malformedExportSourceWarning, t as DeployEngine, tc as producerRegionsFromState, td as hasUnverifiableParameterRefusal, tf as BOOTSTRAP_MARKER_PREFIX, ti as cfnIngressPortValue, to as orphanRecordsPrintingBag, tr as withNestedRevertRun, tu as malformedOrphansRefusalMessage, u as inheritedProvenanceForChildDiff, ua as secretBearing, ud as withStackInstanceIdWithheld, ui as DELETED_RESOURCE_REMEDY, ul as tryGetTopLevelWriteOnlyProperties, uo as ATOMIC_FINAL_SNAPSHOT_TYPES, ur as loadJournaledOrphans, uu as malformedOutputsWarning, v as childTemplateLoader, va as collectDeclaredOutputNames, vc as lacksRecordedRefArn, vd as renderNestedTemplateTreeDefect, vi as calculateResourceDrift, vl as maskedPropertyFingerprint, vo as createPreDeleteFinalSnapshot, vr as NOECHO_MAC_KEY_ALIAS, vs as setLocalCustomResourceRuntimeEnabled, vu as malformedResourcesWarning, w as healSlashedSsmParameterNames, wa as maskingRetryLogger, wi as findUpdatePolicyReplacementRefusals, wl as previewableOrphanRecords, wn as recordRetainedForReadoption, wr as constructPathOf$1, ws as UNSPECIFIED_SKIP_REASON, wu as repairMalformedResourcesForReadOnly, x as pendingMovesRefusalMessage, xa as bindingSkippedOutputs, xi as undeclaredEmptyObservedKeys, xl as malformedOrphanRecordsRefusalMessage, xr as noEchoMacParametersOf, xs as CloudControlProvider, xu as refuseMalformedResourcesForDestroy, y as hasPendingMovesOut, ya as collectPublishedOutputNames, yc as lacksRecordedTableArn, yd as templateIdentity, yi as equalModuloMarkedMask, yl as deployRefusesOrphanRowsReason, yo as buildFinalSnapshotIdentifier, yr as createNoEchoValueMacs, ys as withCustomResourceStack, yu as malformedStateRefusalMessage, z as readProtection, za as bold, zc as INTRINSIC_KEYS, zd as getDockerImageBySourceHash, zi as replacementNeverSwapped, zl as refuseMalformedResourceEntriesForDestroy, zn as macWriteOnlyKeys, zo as lambdaPermissionMatchesDeclared, zr as looselyEqual, zs as resolveDynamicReferences } from "./deploy-engine-DvPDae31.js";
|
|
8
|
+
import { $ as createLegacyAssetParameterBinder, A as runDockerForeground, B as resolveCaptureObservedState, C as finchSecretArgvRefusal, D as isMalformedEnvKey, E as isDockerClientEnvKey, F as getDefaultStateBucketName, G as resolveUpdatePolicy, H as resolveStateBucketWithDefault, I as getLegacyStateBucketName, J as warnDeprecatedNoPrefixCliFlag, K as resolveUseCdkBootstrapAssets, L as loadCdkJson, M as abortInFlightMultipartUploads, N as Synthesizer, O as formatDockerLoginError, P as synthesisStatusMessage, Q as bindLegacyStackAssetParameters, R as resolveApp, S as dockerSpawnEnvWithSensitive, T as warnFinchArgvExposure, U as resolveStateBucketWithDefaultAndSource, V as resolveSkipPrefix, W as resolveStateBucketWithSource, X as AssemblyReader, Y as refuseFailedLookups, Z as StageLoadError, _ as describeDockerExecFailure, at as setChildProcessAwsEnv, b as redactedDockerCause, d as isLockInfoExpired, et as legacyPlanAssetCount, f as AssetPublisher, h as resolveDockerContextDirectory, i as mergeDeclaredEntries, it as processStackMessages, j as runDockerStreaming, k as getDockerCmd, l as DagBuilder, m as buildDockerImage, n as declaredStringList, nt as prepareLegacyStackAssets, p as WorkGraph, q as stateBucketExistenceConfirmed, r as inlinePoliciesAreDeclared, rt as CdkToolkitBucketMissingError, s as stringListIsDeclared, t as declaredInlinePolicies, tt as predictedAutoCreatedAssetMode, u as LockManager, v as describeDockerFailure, w as partitionSensitiveEnv, x as redactDockerArgvValues, y as redactedCause, z as resolveAutoAssetStorage } from "./settle-own-write-members-D6wzEt7f.js";
|
|
9
|
+
import { $ as slashedSsmNameHealPendingNote, $a as supersededHolderOf, $d as loadPublishableAssetManifest, $i as seedsDeleteFirstGuard, $l as malformedLocalResourceEntriesWarning, $n as recordRetainedForReadoption, $r as hintSidesOf, $s as RollbackInlinePolicyWriters, $u as findActionableSdkUnwired, A as parseCfnTemplateWithFormat, Aa as displayTextOrWithheld, Ac as classifyRecordedSecretRegion, Ad as findNestedTemplateTreeDefect, Af as describeFileReadFailure, Ai as replayRollback, Al as getSettledWriteOnlyPropertyPaths, Ao as namingSecretsWithRecordedNoEcho, Ar as withNestedRevertRun, As as classifyHandleUrl, Au as malformedOutputsWarning, B as conditionFingerprint, Ba as collectDeclaredOutputNames, Bd as findLargeInlineResources, Bi as equalModuloMarkedMask, Bl as deployRefusesOrphanRowsReason, Bo as ATOMIC_FINAL_SNAPSHOT_TYPES, Br as sameJournaledOrphans, Bu as refuseMalformedResourcesForDeploy, C as templateMixesDynamicReference, Cc as isIamRoleArn, Cd as isNotImplemented, Cf as defineOwnKey, Ci as recordedRuleIdOf, Co as noEchoParameterNamesOf, Cr as displacedPhysicalIdShown, Cu as refuseMalformedOrphans, D as getCloudFormationResourceTree, Da as reachableDivergentParameters, Dc as applyCallerIdentityCredentials, Dd as isSensitiveAttributeName, Df as ownValue, Di as siblingRecordedSgRuleIds, Dl as secretPhysicalIdSegment, Do as completedReplayEntries, Dr as recordDisplacedSkips, Ds as isCustomResource, Du as malformedExportSourceWarning, E as findReplacedCfnResources, Ea as namesAnyDeclaredParameter, Ec as AWS_CREDENTIAL_ENV_KEYS, Ed as isSecretValuedAttribute, Ef as nullPrototypeRecord, Eo as createReadOnlyAttributeHealerFactory, Er as nestedChildStackName$1, Es as ccBrokenReason, Et as streamPolicyMatchesDeclared, Eu as malformedExportNamesWarning, F as promptYesNo, Fa as carriedExportAliasExposure, Fc as isUnexposedRecordedIdentity, Fi as buildReadCurrentStateContext, Fl as parameterInputsFor, Fo as secretNamedRecordNeedles, Fr as dropFailedCommands, Fs as customResourceResponseExpirationWarning, Fu as STATE_REGION_DIVERGED, G as hasPendingMovesOut, Ga as DEFAULT_RESOURCE_WARN_AFTER_MS, Gc as AWS_NO_VALUE, Gi as findUpdatePolicyReplacementRefusals, Gl as previewableOrphanRecords, Go as isFinalSnapshotError, Gr as DeploymentEventsStore, Gs as customResourcesRunWithoutApp, Gu as JSON_LISTING_HOLE_VALUE, H as parentSuppliedValues, Ha as isExportAliasCollision, Hc as coerceParameterTypedValue, Hd as CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION, Hi as undeclaredEmptyObservedKeys, Hl as malformedOrphanRecordsRefusalMessage, Ho as ccRoutedFinalSnapshotError, Hr as makeSiblingClaimReader, Hs as NO_LOCAL_CUSTOM_RESOURCES_FLAG, Hu as refuseMalformedResourcesForExport, I as serializePrompt, Ia as exportNameNoEchoParameters, If as resolveBucketRegion, Ii as recordAfterRollbackUpdate, Il as maskedInputProof, Io as stackSecretNamesMasker, Ir as dropFailedHint, Iu as refuseDivergentRecordRegionForDestroy, J as refusePendingMovesOut, Ja as holdsSupersededResources, Jc as refStateLookupFromResource, Jd as createAssetRedirectResolver, Ji as ledgerForStack, Jl as refuseMalformedOrphansForOrphan, Jo as createPreDeleteFinalSnapshot, Jr as findDestructiveChanges, Js as setLocalCustomResourceRuntimeEnabled, Ju as STATE_RESOURCES_MALFORMED, K as pendingMovesOutOf, Ka as maskingRetryLogger, Kc as cfnRefValueFromPhysicalId, Ki as replacementCreateRoutesToCloudControl, Kl as refuseMalformedOrphanRecords, Ko as refusesFinalSnapshot, Kr as crossStackReadsForPartialSave, Ks as localCustomResourceCommand, Ku as accountArgs, L as NESTED_STACK_RESOURCE_TYPE$1, La as exportNameSecretExposure, Ld as ssmResolvedValueType, Li as settleUnsettledPrevious, Lo as stateSecretNameNeedles, Lr as isHandledOrphan, Ls as TemplateNoEchoReresolver, Lu as malformedRenderedContainersWarning, M as SUPERSEDED_COPY_HINT, Ma as secretBearing, Mc as producerRegionsFromState, Md as listNestedTemplateRows, Mi as PLANNED_EARLY_DELETE_CONSEQUENCE, Ml as tryGetTopLevelWriteOnlyProperties, Mo as secretNamePrintingBag, Mr as getCurrentNestedStackContext, Ms as isSignalKey, Mu as refuseMalformedOutputs, N as cfnFailureText, Na as secretBearingStateKeyWarning, Nc as regionLessSecretName, Nd as renderNestedTemplateTreeDefect, Nf as renderAssemblyPathEscape, Ni as earlyDeleteWhen, Nl as publicReferencesOf, No as secretNamePrintingBags, Nr as withNestedStackContext, Ns as CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID, Nu as refuseMalformedOutputsForDestroy, O as tryGetCloudFormationResourceMap, Oa as resourcesNamingDeclaredParameter, Oc as callerEnvCredentials, Ol as secretSegmentsOfState, Oo as journaledOrphanPrintingBag, Os as wouldReturnToSdkProvider, Ou as malformedLocalOutputsWarning, P as confirmOrRefuse, Pa as secretSafeKeyDisplay, Pc as withoutLapsedStaleShapeStamp, Pd as templateIdentity, Pf as resolveAssemblyPath, Pi as earlyDeletedOld, Pl as maskedPropertyFingerprintsOf, Pr as deleteJournaledOrphans, Ps as applyCustomResourceResponseExpiration, Pu as repairMalformedOutputsForReadOnly, Q as slashedSsmNameHealNote, Qa as supersededHeldByOtherTypeWarning, Qc as keepHeldTokenProvenance, Qi as planRollback, Ql as isReadableResourceEntry, Qn as keptForRetainedRecord, Qr as findRefactorHints, Qu as hasReadableResources, R as readDbInstanceAvailabilityZone, Ra as isWholeDynamicReferenceValue, Rd as CFN_TEMPLATE_BODY_LIMIT, Ri as withUnprovenUnsettled, Rl as declaresNoEcho, Ro as storedSecretNameNeedles, Rr as journaledOrphanLines, Rs as readsNoEchoDeleteValues, Ru as malformedResourcesWarning, S as taintedNamesOf, Sa as withNameGenerationReached, Sc as explicitRoleArnOrThrow, Sd as isAccessDenied, Si as undeclaredGrantSiblingMembers, So as noEchoComparisonForTemplate, Sr as displacedOpClause, Su as malformedOrphansWarning, T as prepareCloudFormationStackRetirement, Ta as computeParameterTaint, Tc as sendableAssumeRoleCommand, Td as withStackInstanceIdWithheld, Tf as hasPlainPrototype, Ti as sgSiblingDecidedById, Tl as displayPhysicalId, To as noEchoExactEchoLeavesOf, Ts as ProviderRegistry, Tu as repairMalformedOrphansForReadOnly, U as readRecordedConditionVerdicts, Ua as bindingSkippedOutputs, Uc as isUnboundTemplateParameter, Ui as updatePartialMessage, Ul as malformedOrphanRecordsWarning, Uo as ccRoutedInstanceTakesNoSnapshot, Ur as planOrphanAdoption, Uu as refuseMalformedState, V as conditionInputsFrom, Va as collectPublishedOutputNames, Vd as uploadCfnTemplate, Vi as equalModuloMask, Vl as isReadableOrphanRecord, Vo as PRE_DELETE_SNAPSHOT_TYPES, Vr as makeForeignHolderScan, Vs as withPrintingSecrets, Vu as refuseMalformedResourcesForDestroy, W as childTemplateLoader, Wa as DEFAULT_RESOURCE_TIMEOUT_MS, Wc as parameterTypeMayLoseSecretIdentity, Wd as decodeListingKey, Wi as updatePartialReason, Wl as malformedOrphanRowsKeptWarning, Wo as effectiveDeletionPolicy, Wr as DeploymentEventsReader, Ws as customResourcesFailedWithoutApp, Wu as repairMalformedResourcesForReadOnly, X as healSlashedSsmParameterNames, Xa as supersededAfterRollback, Xc as lacksRecordedTableArn, Xi as withCreateTokenLedger, Xl as unpreviewableOrphanRecords, Xr as formatDestructiveChange, Xu as displayLogicalId, Y as warnLegacySpelling, Ya as isSupersededResourceRecord, Yc as lacksRecordedRefArn, Yd as createLazyAssetModeContext, Yl as repairMalformedOrphanRecordsForReadOnly, Yo as buildFinalSnapshotIdentifier, Yr as formatChangeCounts, Ys as withCustomResourceStack, Yu as UNREADABLE_RESOURCES_MAP_ROW, Z as slashedSsmNameHealAdoptedNote, Za as supersededDependentsFirst, Zl as unreadableOrphanRecords, Zn as NestedCleanupQueue, Zr as orphanedLogicalIds, Zs as CloudControlProvider, Zu as hasReadableOutputs, _ as mixedSecretRowKeys, _a as nameGenerationHighWaterOf, _c as producerLookupOver, _d as rebuildClientForBucketRegion, _f as readBootstrapMarkerBody, _i as noEchoMacParametersOf, _l as MULTI_REGION_RECREATE_BLOCKED_TYPES, _o as gray, _r as formatResourceLine, _s as policyDocumentMatchesDeclared, _u as refuseMalformedResourcePropertiesForOrphan, a as mergeNoChangeOutputs, aa as recordUnderIdIsNotOwn, ac as getReadOnlyPropertyPaths, ad as hasNoCloudControlHandlers, ai as changedReferenceReason, al as carriesFetchableDynamicReference, ao as withPreviousPolicies, ar as sameMove, as as revertStackRecordsView, at as deferredServiceTokenWarning, au as refuseMalformedResourceEntriesForDeploy, b as recordedValuesOf, ba as retiredNameGenerationsAfter, bc as assertFlagRoleArn, bd as applyCrossPrefixScan, bf as BOOTSTRAP_MARKER_PREFIX, bi as siblingOwnedRevertDesired, bl as renderStatefulReason, bo as yellow, br as resolvePendingCloudControlRequests, bu as hasReadableOrphans, c as nestedSsmNameRowNote, ca as computeImplicitDeleteEdges, cc as DiffCalculator, ci as looselyEqual, cl as keepsSecretReferenceToken, co as cfnIngressPortValue, cr as isReceiver, ct as diffSecurity, cu as refuseMalformedResourceEntriesForImportSave, d as makeCanonicalizePropertiesFn, da as readsRegeneratingSecret, dc as isAlwaysLiveAttribute, dd as TemplateParser, df as ensureAssetStorage, di as propertiesChangedReason, dl as LEGACY_HANDLE_HEAL_REASON, dn as tagsMatchDeclared, do as sgProtocolKey, dt as PROTECTION_PROPERTY_BY_TYPE, du as unreadableResourceEntries, ea as demoteSupersededOrphans, ec as UNSPECIFIED_SKIP_REASON, ed as findHandledUnwrittenCreateOnly, ei as movedToHint, el as recordedOutputReferenceRegions, eo as supersededResourcesOf, er as readRefactorMarker, et as scanActiveConsumers, eu as malformedLocalResourcesWarning, f as calculatorMaskingPassedSecretLines, fa as segmentCleanupOptions, fc as poisonRenderedSpellingsCollidingIn, fd as S3StateBackend, ff as buildDenyExternalAccessPolicy, fi as proposeRenames, fr as childStackTags, fs as declaredMemberDocument, ft as isProtectionValueActive, fu as malformedDriftResourcePropertiesWarning, g as maskPassedSecretReasons, ga as nameGenerationCarriedFrom, gc as resolveDynamicReferences, gd as hasUnverifiableParameterRefusal, gf as parseBootstrapMarker, gi as noEchoMacBinding, gl as shownType, go as cyan, gs as memberReadFailure, gu as refuseMalformedResourcePropertiesForExport, h as maskPassedSecretOutputs, ha as orphanNeedsIdentity, hd as hasReasonlessBaselineRefusal, hf as getBootstrapMarkerKey, hi as createNoEchoValueMacs, hl as refuseStatefulReplacedReaders, ho as bold, hr as readsOnlyNoEchoParameters, hs as lambdaPermissionMatchesDeclared, hu as refuseMalformedResourcePropertiesForDrift, i as keptWholeReasonText, ia as recheckFailedPlan, id as NO_CC_HANDLERS_REASON, if as getDockerImageBySourceHash, ii as changedReferencePath, il as isImpossibleEmptyStoredAttribute, io as resolveReplacementOldType, ir as refuseRefactorMarker, it as renderUnreplacedTarget, iu as refuseMalformedResourceEntries, j as stringifyCfnTemplate, ja as exportAliasCollisionScrubWarning, jc as classifyReplaySecretRegion, jd as isAbsoluteAssetPath, jf as displayAssemblyPath, ji as DELETED_RESOURCE_REMEDY, jl as getTopLevelKeysHoldingUnreadableCreateOnly, jo as orphanRecordsPrintingBag, jr as collectNestedChildUnaddressed, k as parseCfnTemplate, ka as WITHHELD_NAME_DISPLAY, kc as envCredentialsAreAssumedRole, ki as replayFailedOperations, kl as withSecretPhysicalIdsMaskedInState, ko as maskEventTextWithBoundBags, kr as revertedNestedRowIds, ks as WaitConditionSignalStore, ku as malformedOutputsRefusalMessage, l as crossStackOutputProvenanceSource, la as typesDeletedBefore, lc as IntrinsicFunctionResolver, li as mappingPairs, ll as withSharedDrainBudget, lo as recordedSgRuleId, lr as removeSignalReceiverNamed, ls as LAMBDA_PERMISSION_STATEMENT_KEYS, lt as recordedProtectionEvidence, lu as refuseMalformedResourceEntriesForOrphan, m as maskPassedSecretChanges, ma as removeProtectionTypes, md as readOnlyStateVersionOf, mf as isCrossRegionRedirect, mi as NOECHO_MAC_KEY_ALIAS, ml as findReplacedReadersOfRecreateTargets, mo as canonicalizeIpProtocolValue, mr as macWriteOnlyKeys, ms as efsPolicyMatchesDeclared, mt as readProtection, mu as refuseMalformedResourcePropertiesForDestroy, n as applyStackTagsToTemplate, na as isReplacementOrphan, nc as deleteLeftInPlace, nd as unwrittenCreateOnlyReplacement, nf as rewriteTemplateAssetReferences, ni as withMovedTo, nl as withoutVersionAttestation, nr as refactorMarkerMovesOf, nt as planReplaceResourceTargets, nu as malformedScrubResourceEntriesRefusalMessage, o as checkNestedSsmNames, oa as replacementNeverSwapped, oc as isWaitAbandonedError, od as PROPERTY_COVERAGE_BY_TYPE, oi as differingRemedy, ol as isNamelessDynamicReferenceError, oo as findNestedStackTypeChanges, or as updateRefactorMarker, ot as findServiceTokenRefusals, ou as refuseMalformedResourceEntriesForDestroy, p as crossStackTaintSeeds, pa as removeProtectionTypeList, pc as stackIdTailOf, pd as splitImportedOps, pf as assertAssetBucketRegion, pi as referencedLogicalIds, po as canonicalizeIpv4Cidr, pr as literalRowTags, ps as declaredPolicyDocument, pt as perType, pu as malformedResourcePropertiesWarning, q as pendingMovesRefusalMessage, qa as deleteSupersededEntry, qc as isStalePlaceholderArnAttribute, qd as buildAssetRedirectMap, ql as refuseMalformedOrphanRecordsForDestroy, qo as unsupportedFinalSnapshotError, qr as constructPathOf$1, qu as withheldAccountClause, r as isSecretBearingReferenceString, ra as planFailedOps, rc as deleteSkipReason, rf as AssetManifestLoader, ri as changedReferenceInDiff, rl as getAccountInfo, ro as snapshotSegmentSurvivors, rr as refactorMarkerRefusalMessage, rs as destroyStackRecordsView, rt as refuseStatefulReplaceResourceTargets, ru as refuseMalformedResourceAttributesForOrphan, s as nestedSsmNameDeferredNote, sa as IMPLICIT_DELETE_DEPENDENCIES, sd as providerReplacementOldDeleted, si as isPairableType, sl as carriesDynamicReference, sn as declaredTagsReadback, sr as deleteSignalReceiver, ss as withStackRecords, st as serviceTokenBlockingReason, su as refuseMalformedResourceEntriesForImport, t as DeployEngine, ta as isJournaledOrphan, tc as deleteIndeterminateGuards, ti as rollbackOrphanIds, tl as recordedReferenceRegions, to as withoutSuperseded, tr as readRefactorMarkerOnce, tt as inRunStackKey, tu as malformedResourceEntriesWarning, u as inheritedProvenanceForChildDiff, ua as attemptUsesCompletedCreate, uc as isSelectOutOfBounds, uf as AssetModeResolver, ui as parseMappingFile, ul as INTRINSIC_KEYS, uo as sgCidrKey, ur as settleStackTagChildRuns, ut as recordedProtectionNote, uu as repairMalformedResourceEntriesForReadOnly, v as mixedSecretTagKeys, va as nameScopeOf, vc as refuseUnreadableCdkCrossAccountRefs, vd as CrossPrefixReadError, vf as validateAssetBucketName, vi as noEchoMacVerdict, vl as isStatefulRecreateTargetForReplace, vo as green, vr as startForceQuitFlushes, vs as reReadUntilSettled, vu as repairMalformedResourcePropertiesForReadOnly, w as deleteRetiredCloudFormationStack, wa as inheritProducerRegions, wc as parseIamRoleArn, wd as stackInstanceIdOf, wf as hasOwnKey, wi as sgRuleOwnershipIdentity, wo as withAttemptedItemsMasked, wr as dropSettledNestedJournals, ws as CC_BROKEN_REASON, wu as refuseMalformedOrphansForDestroy, x as securityDiffWithPassedSecretWithheld, xa as retiredNameGenerationsLeaving, xc as assertSendableRoleArn, xd as crossPrefixDeniedWarning, xi as stripSiblingOwnedParentMembers, xo as noEchoAttributeNamesOf, xr as NESTED_PENDING_PARENT_REASON, xs as verbatimEchoDriftKeys, xt as readStreamPolicy, xu as malformedOrphansRefusalMessage, y as readsTainted, ya as retiredAfterRollback, yc as applyRoleArnIfSet, yd as CrossPrefixScanCache, yf as validateContainerRepoName, yi as noEchoValueMacsOf, yl as isStatefulRecreateTargetSync, yo as red, yr as pendingRequestCount, yu as UNREADABLE_ORPHANS_CONTAINER_ROW, z as healZonelessDbInstanceRecords, za as noEchoParameterValueSeed, zd as CFN_TEMPLATE_URL_LIMIT, zi as calculateResourceDrift, zl as maskedPropertyFingerprint, zo as extractDeploymentEventError, zr as loadJournaledOrphans, zs as isCustomResourceType$1, zu as malformedStateRefusalMessage } from "./deploy-engine-C12Ygjb-.js";
|
|
10
10
|
import { n as canonicalizeRegion, r as derivePartitionAndUrlSuffix, t as PARTITION_TABLE } from "./aws-partition-DA0r2sr-.js";
|
|
11
|
-
import { C as timePhase, D as parseFailureDebugDetail, S as renderPhaseTimings, T as describeJsonParseFailure, a as getCreateOnlyPropertyPaths, c as templateResourceTypes, g as withRetry, k as utf8ByteLength, s as prefetchCreateOnlyPropertyPaths, u as describeTypeWithThrottleRetry, v as PhaseClock } from "./secret-reference-immutable-
|
|
12
|
-
import { l as setResolvedResourceTimeouts } from "./ec2-termination-protection-
|
|
13
|
-
import { t as expectedOwnerParam } from "./expected-bucket-owner-
|
|
14
|
-
import { Ct as isReadableBag, Et as shouldRetainResource, Ot as stackInstanceIdCarriedFrom, St as importableOutputs, Tt as orphansCarriedFrom, _t as acceptedCreateOnlyDropsOf, bt as hasReadableExportSet, gt as slowCcOperationTimeoutMs, vt as describeRegionValueKind, wt as orphansAfterRollback, xt as importableOutputKeys, yt as exportNamesCarriedFrom } from "./delete-started-
|
|
15
|
-
import {
|
|
16
|
-
import { S as unsettledPropertiesOf, T as withoutUnsettledProperties, b as unsettledItemsOf, w as withUnsettledProperties, y as unsettledItemsField } from "./restore-source-guard-
|
|
17
|
-
import { u as differingIdentityWarning } from "./identity-read-denied-
|
|
18
|
-
import { n as isRedactedRecordedValue } from "./redacted-delete-address-
|
|
19
|
-
import { a as withResourceDeadline } from "./resource-deadline-
|
|
20
|
-
import { a as parseEcrRegistryHost, i as looksLikeEcrHostWithForeignSuffix, n as hasEcrRegistryHostLabels, t as ecrRegistryHostPattern } from "./ecr-uri-
|
|
11
|
+
import { C as timePhase, D as parseFailureDebugDetail, S as renderPhaseTimings, T as describeJsonParseFailure, a as getCreateOnlyPropertyPaths, c as templateResourceTypes, g as withRetry, k as utf8ByteLength, s as prefetchCreateOnlyPropertyPaths, u as describeTypeWithThrottleRetry, v as PhaseClock } from "./secret-reference-immutable-BC4abPuQ.js";
|
|
12
|
+
import { l as setResolvedResourceTimeouts } from "./ec2-termination-protection-UZAZ2Hzv.js";
|
|
13
|
+
import { t as expectedOwnerParam } from "./expected-bucket-owner-0yx_Q4Hl.js";
|
|
14
|
+
import { Ct as isReadableBag, Et as shouldRetainResource, Ot as stackInstanceIdCarriedFrom, St as importableOutputs, Tt as orphansCarriedFrom, _t as acceptedCreateOnlyDropsOf, bt as hasReadableExportSet, gt as slowCcOperationTimeoutMs, vt as describeRegionValueKind, wt as orphansAfterRollback, xt as importableOutputKeys, yt as exportNamesCarriedFrom } from "./delete-started-yz9plykR.js";
|
|
15
|
+
import { $n as WHOLE_DYNAMIC_REFERENCE_PATTERN, An as splitGetAttStringForm, C as maskedLeafCoordinatesOf, Cn as dynamicReferenceTokens, Ct as errorCauseChain, D as noEchoOutputsComparison, E as noEchoLeavesOf, Et as maskSecretsInText, Gt as identityKeyFor, Ht as spelledKeysOf, I as valueAtCoordinate, Jn as recordNoEchoAttributeValues, Kn as recordMaskOnlyValue, Lt as scrubResourceRecord, M as readsNoEchoSource, P as recordedNoEchoValuesOf, Q as redactForState, Qt as inheritNestedStackParameterAssociations, R as liveMatchesUnresolvedTokenFrame, Rt as withPhysicalNameCopies, S as maskWholeValue, St as createSecretMasker, T as noEchoCoordinatesOf, Tt as maskSecretsInError, Un as provenPublicValue, Ut as pathCrossesDottedKey, Vt as isUncertifiedBaselineMaskPosition, Xn as recordProvenPublicExpression, Yn as recordNoEchoParameterFreshValue, Zn as wholeStringLeavesOf, _n as physicalNameCopiesOf, _t as recordLogOnlyParameterValue, b as maskAtCoordinates, bt as shareLogOnlyValues, ct as carryLogOnlyValues, ft as hasMaskableValues, g as canonicalCoordinates, gt as printingCorpusOf, hn as keepTemplateLiteralLeaves, jn as carriesSecretMask, mt as logOnlyValueCount, pt as literalSplitDelimitersOf, qn as recordMaskOnlyValuesIn, tr as isSingleDynamicReferenceToken, un as recordNestedStackParameterExpressions, ut as createUnionSecretMasker, v as isMarkedCoordinate, x as maskReadbackAtCoordinates, xn as DYNAMIC_REFERENCE_TOKEN_SCAN, xt as unionOfSecretBags, yn as recordPhysicalNameCopy, yt as recordLogOnlyValue } from "./replacement-rules-BoZMVFdK.js";
|
|
16
|
+
import { S as unsettledPropertiesOf, T as withoutUnsettledProperties, b as unsettledItemsOf, w as withUnsettledProperties, y as unsettledItemsField } from "./restore-source-guard-BkS5tGr5.js";
|
|
17
|
+
import { u as differingIdentityWarning } from "./identity-read-denied-DBsqwW85.js";
|
|
18
|
+
import { n as isRedactedRecordedValue } from "./redacted-delete-address-DVgNoeo4.js";
|
|
19
|
+
import { a as withResourceDeadline } from "./resource-deadline-BkQ9mJAk.js";
|
|
20
|
+
import { a as parseEcrRegistryHost, i as looksLikeEcrHostWithForeignSuffix, n as hasEcrRegistryHostLabels, t as ecrRegistryHostPattern } from "./ecr-uri-C74u9FtL.js";
|
|
21
21
|
import { t as cdkdCacheHome } from "./cache-home-BVYKj3de.js";
|
|
22
22
|
import { randomBytes, randomUUID } from "node:crypto";
|
|
23
23
|
import { CopyObjectCommand, CreateBucketCommand, DeleteBucketCommand, DeleteObjectsCommand, GetBucketLocationCommand, GetObjectCommand, HeadBucketCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, NotFound, PutBucketEncryptionCommand, PutBucketPolicyCommand, PutBucketVersioningCommand, PutObjectCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
|
|
24
24
|
import { GetRoleCommand, GetUserCommand } from "@aws-sdk/client-iam";
|
|
25
25
|
import { GetCallerIdentityCommand, STSClient } from "@aws-sdk/client-sts";
|
|
26
26
|
import { DescribeSecurityGroupRulesCommand } from "@aws-sdk/client-ec2";
|
|
27
|
-
import {
|
|
27
|
+
import { CreateChangeSetCommand, DeleteChangeSetCommand, DescribeChangeSetCommand, DescribeStackEventsCommand, DescribeStacksCommand, ExecuteChangeSetCommand, GetTemplateCommand, UpdateStackCommand, waitUntilChangeSetCreateComplete, waitUntilStackImportComplete, waitUntilStackUpdateComplete } from "@aws-sdk/client-cloudformation";
|
|
28
28
|
import { GetSecretValueCommand, SecretsManagerClient } from "@aws-sdk/client-secrets-manager";
|
|
29
29
|
import { GetParameterCommand, SSMClient } from "@aws-sdk/client-ssm";
|
|
30
30
|
import { DescribeLogStreamsCommand, ResourceNotFoundException as ResourceNotFoundException$1 } from "@aws-sdk/client-cloudwatch-logs";
|
|
@@ -39,10 +39,10 @@ import { CreateAliasCommand, CreateKeyCommand, DescribeKeyCommand, KMSClient, Sc
|
|
|
39
39
|
import { A2A_CONTAINER_PORT, A2A_PATH, AGENTCORE_A2A_PROTOCOL, AGENTCORE_AGUI_PROTOCOL, AGENTCORE_MCP_PROTOCOL, ConnectionRegistry, DEFAULT_AWS_EMULATOR_URL, DynamicReferenceResolver, EMULATOR_SCRUBBED_ENV_KEYS, EcsTaskResolutionError, MCP_CONTAINER_PORT, MCP_PATH, UNNAMED_WORKLOAD, a2aInvokeOnce, addAlbSpecificOptions, addAwsEndpointOptions, addCommonEcsServiceOptions, addImageOverrideOptions, addStartServiceSpecificOptions, albStrategy, applyWorkloadAwsWiringToEnv, attachAuthorizers, attachStageContext, availableApiIdentifiers, awaitLoopbackForwarderStatus, awsEmulatorEnvName, awsEmulatorRealServices, awsEmulatorSqsHostBlocks, bufferToBody, buildAgentCoreCodeImage, buildCognitoJwksUrl, buildConnectEvent, buildCorsConfigByApiId, buildCorsConfigFromCloudFrontChain, buildDisconnectEvent, buildJwksUrlFromIssuer, buildMessageEvent, buildMgmtEndpointEnvUrl, buildNamespaceOwnerForwarderDockerArgs, buildStageMap, canonicalizeImageOverrideKeys, classifySourceChange, containsCrossStackIntrinsic, containsDynamicReference, createAuthorizerCache, createFileWatcher, createFileWatcher as createFileWatcher$1, createJwksCache, createMixedModeStateProvider, createWatchPredicates, defaultCredentialsLoader, describeAwsFailureForWarn, describeForwarderFailure, discoverRoutes, discoverWebSocketApis, dockerRegistryEnv, downloadAndExtractS3Bundle, effectiveLoopbackPorts, enforceImageOverrideOrphans, expandNestedStacks, filterRoutesByApiIdentifier, firstUsableRegion, getActiveWorkloadAwsWiring, getAwsEndpointOverride, groupRoutesByServer, groupWorkloadsRoutedApart, handleConnectionsRequest, invokeAgentCore, invokeAgentCoreWs, isAwsServiceRoutedToEmulator, keysNotFromTemplate, keysOverriddenBy, logMixedModeForWorkload, loopbackForwarderPlan, mcpInvokeOnce, noImplicitEcrPullArgs, parseAwsEndpoint, parseConnectionsPath, parseImageOverrideFlags, parseSelectionExpressionPath, pickAgentCoreCandidateStack, pickAgentCoreCandidateStack as pickAgentCoreCandidateStack$1, readAwsEmulatorEnvVarsFile, readEmulatorRunFiles, readEnvVarsFileText, readMtlsMaterialsFromDisk, realAwsServicesOf, resolveAgentCoreTarget, resolveAwsEmulatorOption, resolveDynamicReferencesInEnv, resolveEnvVars, resolveHostDefaultCredentials, resolveImageOverrides, resolveJwtAuthorizerIntrinsics, resolveSingleTarget, resolveWatchConfig, resolveWorkloadAwsWiring, runEcsServiceEmulator, runImageOverrideBuilds, setActiveWorkloadAwsWiring, setAwsEndpointOverride, signAgentCoreInvocation, startApiServer, topLevelStacks, verifyJwtViaDiscovery, waitForAgentCorePing, warnUnenforcedRouteAuthSettings, withNestedDescendants, withoutKeys } from "cdk-local/internal";
|
|
40
40
|
import { isDeepStrictEqual, promisify } from "node:util";
|
|
41
41
|
import graphlib from "graphlib";
|
|
42
|
-
import { Command, InvalidArgumentError, Option } from "commander";
|
|
43
42
|
import * as readline$1 from "node:readline/promises";
|
|
44
43
|
import readline from "node:readline/promises";
|
|
45
|
-
import { Document,
|
|
44
|
+
import { Document, Scalar, isScalar, parse, stringify, visit } from "yaml";
|
|
45
|
+
import { Command, InvalidArgumentError, Option } from "commander";
|
|
46
46
|
import { emitKeypressEvents } from "node:readline";
|
|
47
47
|
import { collectSsmParameterRefs, createLocalStartAgentCoreCommand, createLocalStartCloudFrontCommand, createLocalStartMicrovmCommand, createLocalStartWebFunctionCommand, createLocalStateProvider, getEmbedConfig, isCfnFlagPresent, listTargets, rejectExplicitCfnStackWithMultipleStacks, resolveCfnFallbackRegion, resolveCfnStackName, resolveSsmParameters, setEmbedConfig, substituteAgainstState, substituteAgainstStateAsync, substituteEnvVarsFromState, substituteEnvVarsFromStateAsync } from "cdk-local";
|
|
48
48
|
import { WebSocketServer } from "ws";
|
|
@@ -1176,40 +1176,6 @@ function createListCommand() {
|
|
|
1176
1176
|
return cmd;
|
|
1177
1177
|
}
|
|
1178
1178
|
|
|
1179
|
-
// src/cli/commands/confirm-prompt.ts
|
|
1180
|
-
let promptQueue = Promise.resolve();
|
|
1181
|
-
function serializePrompt(ask) {
|
|
1182
|
-
const asked = promptQueue.then(ask);
|
|
1183
|
-
promptQueue = asked.catch(() => void 0);
|
|
1184
|
-
return asked;
|
|
1185
|
-
}
|
|
1186
|
-
async function promptYesNo(prompt) {
|
|
1187
|
-
const rl = readline$1.createInterface({
|
|
1188
|
-
input: process.stdin,
|
|
1189
|
-
output: process.stdout
|
|
1190
|
-
});
|
|
1191
|
-
try {
|
|
1192
|
-
const ans = await rl.question(`${prompt} [Y/n] `);
|
|
1193
|
-
return /^(y(es)?)?$/i.test(ans.trim());
|
|
1194
|
-
} finally {
|
|
1195
|
-
rl.close();
|
|
1196
|
-
}
|
|
1197
|
-
}
|
|
1198
|
-
const DEFAULT_CONFIRM_SUFFIX = " [y/N] ";
|
|
1199
|
-
async function confirmOrRefuse(prompt, options) {
|
|
1200
|
-
if (process.stdin.isTTY !== true) throw new CdkdError(options.refusal, "NON_INTERACTIVE_CONFIRM");
|
|
1201
|
-
const rl = readline$1.createInterface({
|
|
1202
|
-
input: process.stdin,
|
|
1203
|
-
output: options.output ?? process.stdout
|
|
1204
|
-
});
|
|
1205
|
-
try {
|
|
1206
|
-
const ans = await rl.question(`${prompt}${options.suffix ?? " [y/N] "}`);
|
|
1207
|
-
return /^y(es)?$/i.test(ans.trim());
|
|
1208
|
-
} finally {
|
|
1209
|
-
rl.close();
|
|
1210
|
-
}
|
|
1211
|
-
}
|
|
1212
|
-
|
|
1213
1179
|
// src/cli/commands/require-approval.ts
|
|
1214
1180
|
const REQUIRE_APPROVAL_VALUES = [
|
|
1215
1181
|
"never",
|
|
@@ -1595,7 +1561,7 @@ function collectCrossStackRefs(node, onRef, unconditional) {
|
|
|
1595
1561
|
// src/provisioning/register-providers.ts
|
|
1596
1562
|
let providerClasses;
|
|
1597
1563
|
function loadProviderClasses() {
|
|
1598
|
-
providerClasses ??= import("./provider-classes-
|
|
1564
|
+
providerClasses ??= import("./provider-classes-Bi3D5zDS.js");
|
|
1599
1565
|
return providerClasses;
|
|
1600
1566
|
}
|
|
1601
1567
|
function registerAllProviders(registry, classes) {
|
|
@@ -2626,9 +2592,32 @@ async function addStacksToWorkGraph(args) {
|
|
|
2626
2592
|
}
|
|
2627
2593
|
}
|
|
2628
2594
|
|
|
2595
|
+
// src/cli/commands/deploy/replace-resource-checks.ts
|
|
2596
|
+
function checkReplaceResourceOptions(options, targetStacks) {
|
|
2597
|
+
const ids = options.replaceResource ?? [];
|
|
2598
|
+
if (ids.length === 0) return;
|
|
2599
|
+
const problems = [];
|
|
2600
|
+
const recreate = new Set([options.recreateViaCcApi ?? [], options.recreateViaSdkProvider ?? []].flat());
|
|
2601
|
+
for (const id of new Set(ids)) {
|
|
2602
|
+
const declaring = targetStacks.filter((stack) => Object.hasOwn(stack.template.Resources ?? {}, id)).map((stack) => stack.stackName);
|
|
2603
|
+
if (declaring.length === 0) problems.push(safeMsg` - ${id}: no stack of this deploy declares it (the flag reaches a top-level stack's resources only, not a nested stack's)`);
|
|
2604
|
+
else if (declaring.length > 1) problems.push(safeMsg` - ${id}: declared by ${declaring.join(", ")}; deploy one of them alone to replace it there`);
|
|
2605
|
+
if (recreate.has(id)) problems.push(safeMsg` - ${id}: also named by --recreate-via-*, which destroys and recreates it already; pass one`);
|
|
2606
|
+
}
|
|
2607
|
+
if (problems.length === 0) return;
|
|
2608
|
+
throw new CdkdError(`--replace-resource must name exactly one resource of this deploy:\n${problems.join("\n")}`, "REPLACE_RESOURCE_INVALID");
|
|
2609
|
+
}
|
|
2610
|
+
function replaceResourcesForStack(ids, stackName, template) {
|
|
2611
|
+
const own = (ids ?? []).filter((id) => Object.hasOwn(template.Resources ?? {}, id));
|
|
2612
|
+
return own.length > 0 ? {
|
|
2613
|
+
stackName,
|
|
2614
|
+
logicalIds: new Set(own)
|
|
2615
|
+
} : void 0;
|
|
2616
|
+
}
|
|
2617
|
+
|
|
2629
2618
|
// src/deployment/recreate-targets/validate.ts
|
|
2630
2619
|
const EMPTY_ALLOW_SET$1 = /* @__PURE__ */ new Set();
|
|
2631
|
-
const NESTED_STACK_RESOURCE_TYPE
|
|
2620
|
+
const NESTED_STACK_RESOURCE_TYPE = "AWS::CloudFormation::Stack";
|
|
2632
2621
|
function validateRecreateTargets(input) {
|
|
2633
2622
|
const seenCcApi = new Set(input.recreateViaCcApi);
|
|
2634
2623
|
const seenSdk = new Set(input.recreateViaSdkProvider ?? []);
|
|
@@ -2735,7 +2724,7 @@ function validateRecreateTargets(input) {
|
|
|
2735
2724
|
blockedNoCcRoute,
|
|
2736
2725
|
blockedCcBroken,
|
|
2737
2726
|
conflictingDirections,
|
|
2738
|
-
nestedStackLogicalIds: Object.entries(input.template.Resources ?? {}).filter(([, resource]) => resource?.Type === NESTED_STACK_RESOURCE_TYPE
|
|
2727
|
+
nestedStackLogicalIds: Object.entries(input.template.Resources ?? {}).filter(([, resource]) => resource?.Type === NESTED_STACK_RESOURCE_TYPE).map(([id]) => id)
|
|
2739
2728
|
};
|
|
2740
2729
|
}
|
|
2741
2730
|
|
|
@@ -2774,7 +2763,7 @@ function renderRecreateTargetsErrors(validation) {
|
|
|
2774
2763
|
if (lines.length > 0) lines.push("");
|
|
2775
2764
|
lines.push(`${FLAG_UMBRELLA} refuses to operate on ${validation.blockedNestedStackTargets.length} nested-stack resource(s):`);
|
|
2776
2765
|
for (const blocked of validation.blockedNestedStackTargets) {
|
|
2777
|
-
const templateType = validation.nestedStackLogicalIds.includes(blocked.logicalId) ? NESTED_STACK_RESOURCE_TYPE
|
|
2766
|
+
const templateType = validation.nestedStackLogicalIds.includes(blocked.logicalId) ? NESTED_STACK_RESOURCE_TYPE : void 0;
|
|
2778
2767
|
const shown = templateType && templateType !== blocked.resourceType ? `${recordedTypeShown(blocked.resourceType)} in state, ${templateType} in the template` : recordedTypeShown(blocked.resourceType);
|
|
2779
2768
|
lines.push(` - ${blocked.logicalId} (${shown})`);
|
|
2780
2769
|
}
|
|
@@ -3345,6 +3334,7 @@ async function deployStackInScope(ctx, stackInfo, stackRegion, stackAwsClients)
|
|
|
3345
3334
|
guard: crossPrefixGuard,
|
|
3346
3335
|
backend: preflightStateBackend
|
|
3347
3336
|
});
|
|
3337
|
+
const replaceResources = replaceResourcesForStack(options.replaceResource, stackInfo.stackName, stackInfo.template);
|
|
3348
3338
|
let recreateTargets;
|
|
3349
3339
|
if (options.recreateViaCcApi?.length || options.recreateViaSdkProvider?.length) {
|
|
3350
3340
|
const stateForRecreateCheck = await stackStateBackend.getState(stackInfo.stackName, stackRegion);
|
|
@@ -3436,6 +3426,7 @@ async function deployStackInScope(ctx, stackInfo, stackRegion, stackAwsClients)
|
|
|
3436
3426
|
} },
|
|
3437
3427
|
...recreateTargets && (recreateTargets.viaCcApi.size > 0 || recreateTargets.viaSdkProvider.size > 0) && { recreateTargets },
|
|
3438
3428
|
...options.replace && { replace: true },
|
|
3429
|
+
...replaceResources && { replaceResources },
|
|
3439
3430
|
...options.forceStatefulRecreation && { forceStatefulRecreation: true },
|
|
3440
3431
|
...options.skipFinalSnapshot && { skipFinalSnapshot: true },
|
|
3441
3432
|
finalSnapshotClients: stackAwsClients,
|
|
@@ -3578,6 +3569,28 @@ function checkPinCcApiOptions(options, targetStacks, logger) {
|
|
|
3578
3569
|
}
|
|
3579
3570
|
}
|
|
3580
3571
|
|
|
3572
|
+
// src/cli/commands/deploy/dependency-closure.ts
|
|
3573
|
+
function withDependencyStacks(selected, allStacks, onAdd) {
|
|
3574
|
+
const inferred = inferCrossStackDepsByStack(allStacks, { kinds: ["ImportValue"] });
|
|
3575
|
+
const inApp = new Set(allStacks);
|
|
3576
|
+
const out = [...selected];
|
|
3577
|
+
const included = new Set(selected);
|
|
3578
|
+
const add = (stack) => {
|
|
3579
|
+
const deps = /* @__PURE__ */ new Set();
|
|
3580
|
+
for (const depName of stack.dependencyNames) for (const dep of stacksForDependency(depName, stack, allStacks)) deps.add(dep);
|
|
3581
|
+
for (const producer of inferred.get(stack) ?? []) if (producer !== stack && inApp.has(producer)) deps.add(producer);
|
|
3582
|
+
for (const dep of deps) {
|
|
3583
|
+
if (included.has(dep)) continue;
|
|
3584
|
+
included.add(dep);
|
|
3585
|
+
out.push(dep);
|
|
3586
|
+
onAdd?.(dep, stack);
|
|
3587
|
+
add(dep);
|
|
3588
|
+
}
|
|
3589
|
+
};
|
|
3590
|
+
for (const stack of selected) add(stack);
|
|
3591
|
+
return out;
|
|
3592
|
+
}
|
|
3593
|
+
|
|
3581
3594
|
// src/cli/commands/deploy/command.ts
|
|
3582
3595
|
async function deployCommand(stacks, options) {
|
|
3583
3596
|
const runClock = new PhaseClock("run", { fromProcessStart: true });
|
|
@@ -3698,19 +3711,9 @@ async function deployCommand(stacks, options) {
|
|
|
3698
3711
|
for (const producer of inferred.get(stack) ?? []) if (producer !== stack && inPool.has(producer)) deps.add(producer);
|
|
3699
3712
|
return deps;
|
|
3700
3713
|
};
|
|
3701
|
-
const inferredStrongCrossStackDeps = inferCrossStackDepsByStack(allStacks, { kinds: ["ImportValue"] });
|
|
3702
3714
|
if (!options.exclusively) {
|
|
3703
|
-
const
|
|
3704
|
-
|
|
3705
|
-
for (const depStack of dependencyStacks(stack, inferredStrongCrossStackDeps, allStacks)) {
|
|
3706
|
-
if (included.has(depStack)) continue;
|
|
3707
|
-
included.add(depStack);
|
|
3708
|
-
targetStacks.push(depStack);
|
|
3709
|
-
logger.debug(`Auto-including dependency stack: ${depStack.stackName} (required by ${stack.stackName})`);
|
|
3710
|
-
addDependencies(depStack);
|
|
3711
|
-
}
|
|
3712
|
-
};
|
|
3713
|
-
for (const stack of [...targetStacks]) addDependencies(stack);
|
|
3715
|
+
const withDependencies = withDependencyStacks(targetStacks, allStacks, (dep, by) => logger.debug(`Auto-including dependency stack: ${dep.stackName} (required by ${by.stackName})`));
|
|
3716
|
+
targetStacks.splice(0, targetStacks.length, ...withDependencies);
|
|
3714
3717
|
}
|
|
3715
3718
|
const selectedNames = new Set(targetStacks.map((s) => s.stackName));
|
|
3716
3719
|
const selectedSet = new Set(targetStacks);
|
|
@@ -3860,6 +3863,7 @@ async function deployCommand(stacks, options) {
|
|
|
3860
3863
|
...consumerHold !== void 0 && { consumerHold }
|
|
3861
3864
|
};
|
|
3862
3865
|
checkPinCcApiOptions(options, targetStacks, logger);
|
|
3866
|
+
checkReplaceResourceOptions(options, targetStacks);
|
|
3863
3867
|
runClock.lap("work graph build, recreate checks");
|
|
3864
3868
|
let workGraphCompleted = false;
|
|
3865
3869
|
let heldFailure;
|
|
@@ -3936,6 +3940,35 @@ function createDeployCommand() {
|
|
|
3936
3940
|
var CrossStackPreview = class {
|
|
3937
3941
|
exports = /* @__PURE__ */ new Map();
|
|
3938
3942
|
outputs = /* @__PURE__ */ new Map();
|
|
3943
|
+
taintedExports = /* @__PURE__ */ new Set();
|
|
3944
|
+
taintedOutputs = /* @__PURE__ */ new Set();
|
|
3945
|
+
taintedTexts = /* @__PURE__ */ new Set();
|
|
3946
|
+
everyExportTainted = false;
|
|
3947
|
+
nestedOutputsTaintedOutside;
|
|
3948
|
+
exportTainted(_region, name) {
|
|
3949
|
+
return this.everyExportTainted || this.taintedExports.has(name);
|
|
3950
|
+
}
|
|
3951
|
+
stackOutputTainted(_region, stackName, outputName) {
|
|
3952
|
+
return this.taintedOutputs.has(JSON.stringify([stackName, outputName])) || this.nestedOutputsTaintedOutside !== void 0 && !this.nestedOutputsTaintedOutside.has(stackName);
|
|
3953
|
+
}
|
|
3954
|
+
markNestedOutputsTainted(topLevelStackNames) {
|
|
3955
|
+
this.nestedOutputsTaintedOutside = topLevelStackNames;
|
|
3956
|
+
}
|
|
3957
|
+
anyTainted() {
|
|
3958
|
+
return this.everyExportTainted || this.taintedOutputs.size > 0;
|
|
3959
|
+
}
|
|
3960
|
+
taintedValues() {
|
|
3961
|
+
return this.taintedTexts;
|
|
3962
|
+
}
|
|
3963
|
+
markTainted(stackName, outputName, exportName, values = []) {
|
|
3964
|
+
const outputKey = JSON.stringify([stackName, outputName]);
|
|
3965
|
+
const added = !this.taintedOutputs.has(outputKey);
|
|
3966
|
+
this.taintedOutputs.add(outputKey);
|
|
3967
|
+
if (exportName === null) this.everyExportTainted = true;
|
|
3968
|
+
else if (exportName !== void 0) this.taintedExports.add(exportName);
|
|
3969
|
+
for (const value of values) if (isScalar$1(value) && value !== "" && value !== "***") this.taintedTexts.add(String(value));
|
|
3970
|
+
return added;
|
|
3971
|
+
}
|
|
3939
3972
|
exportValue(region, name) {
|
|
3940
3973
|
return this.exports.get(key(region, name));
|
|
3941
3974
|
}
|
|
@@ -4015,8 +4048,27 @@ async function resolvedExportNames(template, resolve) {
|
|
|
4015
4048
|
}
|
|
4016
4049
|
return names;
|
|
4017
4050
|
}
|
|
4051
|
+
async function markProducerTaint(preview, resolve, input, exportNames) {
|
|
4052
|
+
const reads = input.readsSecretFedName;
|
|
4053
|
+
if (reads === void 0) return;
|
|
4054
|
+
const exportNameOf = exportNames ?? await resolvedExportNames(input.template, resolve);
|
|
4055
|
+
const stored = input.storedOutputs ?? {};
|
|
4056
|
+
for (const [outputName, definition] of Object.entries(input.template.Outputs ?? {})) {
|
|
4057
|
+
const output = definition;
|
|
4058
|
+
const secretName = reads(output?.Export);
|
|
4059
|
+
if (!reads(output?.Value) && !secretName) continue;
|
|
4060
|
+
const exportName = exportNameOf.get(outputName) ?? (output?.Export === void 0 ? void 0 : null);
|
|
4061
|
+
preview.markTainted(input.stackName, outputName, exportName, [
|
|
4062
|
+
Object.hasOwn(input.desiredOutputs, outputName) ? input.desiredOutputs[outputName] : void 0,
|
|
4063
|
+
Object.hasOwn(stored, outputName) ? stored[outputName] : void 0,
|
|
4064
|
+
...typeof exportName === "string" ? [Object.hasOwn(stored, exportName) ? stored[exportName] : void 0] : [],
|
|
4065
|
+
...secretName && typeof exportName === "string" ? [exportName] : []
|
|
4066
|
+
]);
|
|
4067
|
+
}
|
|
4068
|
+
}
|
|
4018
4069
|
async function recordProducerPreview(preview, region, resolve, input) {
|
|
4019
4070
|
const exportNameOf = await resolvedExportNames(input.template, resolve);
|
|
4071
|
+
await markProducerTaint(preview, resolve, input, exportNameOf);
|
|
4020
4072
|
const readsUnknownPreview = (value) => crossStackReads(value).some((read) => {
|
|
4021
4073
|
return (read.kind === "export" ? preview.exportValue(region, read.name) : preview.stackOutput(read.region ?? region, read.stackName, read.outputName))?.kind === "unknown";
|
|
4022
4074
|
});
|
|
@@ -4074,636 +4126,131 @@ function orderProducersFirst(stacks, dependenciesOf) {
|
|
|
4074
4126
|
return ordered;
|
|
4075
4127
|
}
|
|
4076
4128
|
|
|
4077
|
-
// src/cli/commands/
|
|
4078
|
-
const
|
|
4079
|
-
|
|
4080
|
-
|
|
4081
|
-
|
|
4082
|
-
// src/cli/cfn-stack-states.ts
|
|
4083
|
-
const STABLE_TERMINAL_STATUSES = /* @__PURE__ */ new Set([
|
|
4084
|
-
"CREATE_COMPLETE",
|
|
4085
|
-
"UPDATE_COMPLETE",
|
|
4086
|
-
"UPDATE_ROLLBACK_COMPLETE",
|
|
4087
|
-
"IMPORT_COMPLETE",
|
|
4088
|
-
"IMPORT_ROLLBACK_COMPLETE"
|
|
4089
|
-
]);
|
|
4090
|
-
|
|
4091
|
-
// src/cli/commands/retire-cfn-stack/failure-text.ts
|
|
4092
|
-
const SUPERSEDED_COPY_HINT = "If that update completes (now or later), CloudFormation may have replaced resources; each superseded copy is RETAINED and managed by neither CloudFormation nor cdkd. Find them in the stack's events: rows whose reason reads \"Requested update requires the creation of a new physical resource\" name the old physical id. A re-run does not report them, because the template then already carries the Retain policies and no update runs.";
|
|
4093
|
-
const MANUAL_RETIREMENT_ROUTE = "To retire the stack by hand: (1) UpdateStack with DeletionPolicy=Retain and UpdateReplacePolicy=Retain on every resource, (2) `cdkd import` without --migrate-from-cloudformation (it reads the physical ids from a same-named CloudFormation stack), (3) DeleteStack. The import must adopt every resource before you delete the stack: check its summary.";
|
|
4094
|
-
function describeStackWaiterFailure(error) {
|
|
4095
|
-
if (!(error instanceof Error)) return void 0;
|
|
4096
|
-
let parsed;
|
|
4097
|
-
try {
|
|
4098
|
-
parsed = JSON.parse(error.message);
|
|
4099
|
-
} catch {
|
|
4100
|
-
return;
|
|
4101
|
-
}
|
|
4102
|
-
if (typeof parsed !== "object" || parsed === null || !("state" in parsed)) return void 0;
|
|
4103
|
-
const result = parsed;
|
|
4104
|
-
const state = typeof result.state === "string" ? result.state : "FAILURE";
|
|
4105
|
-
const reason = result.reason;
|
|
4106
|
-
const stacks = typeof reason === "object" && reason !== null && "Stacks" in reason ? reason.Stacks : void 0;
|
|
4107
|
-
const stack = Array.isArray(stacks) && typeof stacks[0] === "object" ? stacks[0] : void 0;
|
|
4108
|
-
const status = typeof stack?.StackStatus === "string" ? stack.StackStatus : void 0;
|
|
4109
|
-
const statusReason = typeof stack?.StackStatusReason === "string" ? stack.StackStatusReason : void 0;
|
|
4110
|
-
return `waiter ${state}` + (status ? `, stack status ${status}` : typeof reason === "string" ? `: ${reason}` : "") + (statusReason ? ` (${statusReason})` : "");
|
|
4111
|
-
}
|
|
4112
|
-
function cfnFailureText(error) {
|
|
4113
|
-
const waiter = describeStackWaiterFailure(error);
|
|
4114
|
-
if (waiter !== void 0 && error instanceof Error) {
|
|
4115
|
-
try {
|
|
4116
|
-
Object.defineProperty(error, "message", {
|
|
4117
|
-
value: waiter,
|
|
4118
|
-
writable: true,
|
|
4119
|
-
configurable: true,
|
|
4120
|
-
enumerable: false
|
|
4121
|
-
});
|
|
4122
|
-
Object.defineProperty(error, "stack", {
|
|
4123
|
-
value: `${error.name}: ${waiter}`,
|
|
4124
|
-
writable: true,
|
|
4125
|
-
configurable: true,
|
|
4126
|
-
enumerable: false
|
|
4127
|
-
});
|
|
4128
|
-
} catch {}
|
|
4129
|
-
return waiter;
|
|
4130
|
-
}
|
|
4131
|
-
const failure = describeAwsFailure(error);
|
|
4132
|
-
if (failure.redacted) getLogger().debug(safeMsg`CloudFormation failure detail: ${failure.detail}`);
|
|
4133
|
-
return failure.summary.replace(/\.+$/, "");
|
|
4134
|
-
}
|
|
4135
|
-
var RetainUpdateFailedError = class extends Error {
|
|
4136
|
-
cause;
|
|
4137
|
-
constructor(cfnStackName, kind, cause) {
|
|
4138
|
-
const text = cfnFailureText(cause);
|
|
4139
|
-
super(safeMsg`The Retain-policy UpdateStack on CloudFormation stack ${displaySafe(cfnStackName)} ` + (kind === "rejected" ? "was rejected" : "did not complete") + safeMsg`: ${text}. cdkd state has not been written. ` + (kind === "unfinished" ? `${SUPERSEDED_COPY_HINT} ` : "") + "Re-run the same command once the cause is fixed. When the cause is a replacement CloudFormation cannot perform (a custom-named resource whose update requires replacing it), the same update by hand fails too: give that resource no custom name or a new one, or take it out of the stack, then re-run. To retire the stack by hand: (1) UpdateStack with DeletionPolicy=Retain and UpdateReplacePolicy=Retain on every resource, (2) `cdkd import` without --migrate-from-cloudformation (it reads the physical ids from a same-named CloudFormation stack), (3) DeleteStack. The import must adopt every resource before you delete the stack: check its summary.");
|
|
4140
|
-
this.name = "RetainUpdateFailedError";
|
|
4141
|
-
this.cause = cause;
|
|
4142
|
-
}
|
|
4143
|
-
};
|
|
4144
|
-
|
|
4145
|
-
// src/cli/yaml-cfn.ts
|
|
4146
|
-
const FN_TAGS = [
|
|
4147
|
-
"GetAtt",
|
|
4148
|
-
"Sub",
|
|
4149
|
-
"Join",
|
|
4150
|
-
"Select",
|
|
4151
|
-
"Split",
|
|
4152
|
-
"If",
|
|
4153
|
-
"Equals",
|
|
4154
|
-
"And",
|
|
4155
|
-
"Or",
|
|
4156
|
-
"Not",
|
|
4157
|
-
"FindInMap",
|
|
4158
|
-
"Base64",
|
|
4159
|
-
"Cidr",
|
|
4160
|
-
"GetAZs",
|
|
4161
|
-
"ImportValue",
|
|
4162
|
-
"Length",
|
|
4163
|
-
"ToJsonString",
|
|
4164
|
-
"ForEach"
|
|
4165
|
-
];
|
|
4166
|
-
function nodeJs(node) {
|
|
4167
|
-
if (node === null || node === void 0) return null;
|
|
4168
|
-
if (typeof node === "object" && node !== null && "toJSON" in node) return node.toJSON();
|
|
4169
|
-
return node;
|
|
4170
|
-
}
|
|
4171
|
-
function buildCustomTags() {
|
|
4172
|
-
const tags = [];
|
|
4173
|
-
tags.push({
|
|
4174
|
-
tag: "!Ref",
|
|
4175
|
-
resolve(value) {
|
|
4176
|
-
return { Ref: value };
|
|
4177
|
-
},
|
|
4178
|
-
identify: () => false
|
|
4179
|
-
});
|
|
4180
|
-
tags.push({
|
|
4181
|
-
tag: "!Condition",
|
|
4182
|
-
resolve(value) {
|
|
4183
|
-
return { Condition: value };
|
|
4184
|
-
},
|
|
4185
|
-
identify: () => false
|
|
4186
|
-
});
|
|
4187
|
-
tags.push({
|
|
4188
|
-
tag: "!Transform",
|
|
4189
|
-
collection: "map",
|
|
4190
|
-
resolve(node) {
|
|
4191
|
-
return { "Fn::Transform": nodeJs(node) };
|
|
4192
|
-
},
|
|
4193
|
-
identify: () => false
|
|
4194
|
-
});
|
|
4195
|
-
tags.push({
|
|
4196
|
-
tag: "!GetAtt",
|
|
4197
|
-
resolve(value) {
|
|
4198
|
-
const dot = value.indexOf(".");
|
|
4199
|
-
if (dot < 0) throw new Error(`${GETATT_SHAPE_REFUSAL}; got '${value}'`);
|
|
4200
|
-
return { "Fn::GetAtt": [value.slice(0, dot), value.slice(dot + 1)] };
|
|
4201
|
-
},
|
|
4202
|
-
identify: () => false
|
|
4203
|
-
});
|
|
4204
|
-
tags.push({
|
|
4205
|
-
tag: "!GetAtt",
|
|
4206
|
-
collection: "seq",
|
|
4207
|
-
resolve(node) {
|
|
4208
|
-
return { "Fn::GetAtt": nodeJs(node) };
|
|
4209
|
-
},
|
|
4210
|
-
identify: () => false
|
|
4211
|
-
});
|
|
4212
|
-
for (const name of FN_TAGS) {
|
|
4213
|
-
if (name === "GetAtt") continue;
|
|
4214
|
-
const longKey = `Fn::${name}`;
|
|
4215
|
-
tags.push({
|
|
4216
|
-
tag: `!${name}`,
|
|
4217
|
-
resolve(value) {
|
|
4218
|
-
return { [longKey]: value };
|
|
4219
|
-
},
|
|
4220
|
-
identify: () => false
|
|
4221
|
-
});
|
|
4222
|
-
tags.push({
|
|
4223
|
-
tag: `!${name}`,
|
|
4224
|
-
collection: "seq",
|
|
4225
|
-
resolve(node) {
|
|
4226
|
-
return { [longKey]: nodeJs(node) };
|
|
4227
|
-
},
|
|
4228
|
-
identify: () => false
|
|
4229
|
-
});
|
|
4230
|
-
tags.push({
|
|
4231
|
-
tag: `!${name}`,
|
|
4232
|
-
collection: "map",
|
|
4233
|
-
resolve(node) {
|
|
4234
|
-
return { [longKey]: nodeJs(node) };
|
|
4235
|
-
},
|
|
4236
|
-
identify: () => false
|
|
4237
|
-
});
|
|
4238
|
-
}
|
|
4239
|
-
return tags;
|
|
4240
|
-
}
|
|
4241
|
-
const CUSTOM_TAGS = buildCustomTags();
|
|
4242
|
-
const GETATT_SHAPE_REFUSAL = "!GetAtt requires '<LogicalId>.<Attribute>'";
|
|
4243
|
-
const YAML_ALIAS_EXHAUSTION = "Excessive alias count indicates a resource exhaustion attack";
|
|
4244
|
-
function describeYamlFinding(err) {
|
|
4245
|
-
if (err instanceof YAMLError) {
|
|
4246
|
-
const at = err.linePos?.[0];
|
|
4247
|
-
const where = at ? ` at line ${at.line}, column ${at.col}` : "";
|
|
4248
|
-
if (err.code === "TAG_RESOLVE_FAILED" && err.message.startsWith(GETATT_SHAPE_REFUSAL)) return `${GETATT_SHAPE_REFUSAL}${where}`;
|
|
4249
|
-
return `${err.name} ${err.code}${where}`;
|
|
4250
|
-
}
|
|
4251
|
-
if (err instanceof Error) return err.message === YAML_ALIAS_EXHAUSTION ? `${err.name}: ${YAML_ALIAS_EXHAUSTION}` : err.name || "Error";
|
|
4252
|
-
return describeAwsFailure(err).detail;
|
|
4253
|
-
}
|
|
4254
|
-
function parseYamlTemplate(body) {
|
|
4255
|
-
const doc = parseDocument(body, { customTags: CUSTOM_TAGS });
|
|
4256
|
-
const logger = getLogger();
|
|
4257
|
-
for (const warning of doc.warnings) {
|
|
4258
|
-
logger.debug(safeMsg`Template YAML warning: ${parseFailureDebugDetail(warning)}`);
|
|
4259
|
-
logger.warn(safeMsg`Template YAML warning: ${describeYamlFinding(warning)}`);
|
|
4260
|
-
}
|
|
4261
|
-
if (doc.errors.length > 0) throw doc.errors[0];
|
|
4262
|
-
return doc.toJS();
|
|
4263
|
-
}
|
|
4264
|
-
function parseCfnTemplate(text) {
|
|
4265
|
-
const format = detectTemplateFormat(text);
|
|
4266
|
-
const body = text.charCodeAt(0) === 65279 ? text.slice(1) : text;
|
|
4267
|
-
let parsed;
|
|
4268
|
-
if (format === "json") try {
|
|
4269
|
-
parsed = JSON.parse(body);
|
|
4270
|
-
} catch (err) {
|
|
4271
|
-
getLogger().debug(safeMsg`Template failed to parse as JSON: ${parseFailureDebugDetail(err)}`);
|
|
4272
|
-
throw new Error(`Template is not valid JSON. Cause: ${describeJsonParseFailure(err, utf8ByteLength(body))}`);
|
|
4273
|
-
}
|
|
4274
|
-
else try {
|
|
4275
|
-
parsed = parseYamlTemplate(body);
|
|
4276
|
-
} catch (err) {
|
|
4277
|
-
getLogger().debug(safeMsg`Template failed to parse as YAML: ${parseFailureDebugDetail(err)}`);
|
|
4278
|
-
throw new Error(`Template is not valid YAML. Cause: ${describeYamlFinding(err)}`);
|
|
4279
|
-
}
|
|
4280
|
-
if (!parsed || typeof parsed !== "object" || Array.isArray(parsed)) throw new Error(`Template root is not an object.`);
|
|
4281
|
-
return parsed;
|
|
4282
|
-
}
|
|
4283
|
-
function stringifyCfnTemplate(template, format) {
|
|
4284
|
-
if (format === "json") return JSON.stringify(template, null, 2);
|
|
4285
|
-
const doc = new Document();
|
|
4286
|
-
doc.contents = jsToYamlNode(template, doc);
|
|
4287
|
-
return stringify(doc, {
|
|
4288
|
-
aliasDuplicateObjects: false,
|
|
4289
|
-
lineWidth: 0
|
|
4290
|
-
});
|
|
4291
|
-
}
|
|
4292
|
-
function jsToYamlNode(value, doc) {
|
|
4293
|
-
if (value === null || value === void 0) return new Scalar(null);
|
|
4294
|
-
if (typeof value !== "object") return doc.createNode(value);
|
|
4295
|
-
if (Array.isArray(value)) {
|
|
4296
|
-
const seq = new YAMLSeq();
|
|
4297
|
-
for (const item of value) seq.items.push(jsToYamlNode(item, doc));
|
|
4298
|
-
return seq;
|
|
4299
|
-
}
|
|
4300
|
-
const keys = Object.keys(value);
|
|
4301
|
-
if (keys.length === 1) {
|
|
4302
|
-
const k = keys[0];
|
|
4303
|
-
const v = value[k];
|
|
4304
|
-
const tag = intrinsicShorthandFor(k);
|
|
4305
|
-
if (tag) return makeIntrinsicNode(tag, v, doc);
|
|
4306
|
-
}
|
|
4307
|
-
const map = new YAMLMap();
|
|
4308
|
-
for (const [k, v] of Object.entries(value)) map.items.push(new Pair(doc.createNode(k), jsToYamlNode(v, doc)));
|
|
4309
|
-
return map;
|
|
4310
|
-
}
|
|
4311
|
-
function intrinsicShorthandFor(key) {
|
|
4312
|
-
if (key === "Ref") return "!Ref";
|
|
4313
|
-
if (key === "Condition") return "!Condition";
|
|
4314
|
-
if (!key.startsWith("Fn::")) return null;
|
|
4315
|
-
const name = key.slice(4);
|
|
4316
|
-
if (name === "Transform") return "!Transform";
|
|
4317
|
-
if (name === "GetAtt") return "!GetAtt";
|
|
4318
|
-
if (FN_TAGS.includes(name)) return `!${name}`;
|
|
4319
|
-
return null;
|
|
4320
|
-
}
|
|
4321
|
-
function makeIntrinsicNode(tag, value, doc) {
|
|
4322
|
-
if (tag === "!Ref" || tag === "!Condition") {
|
|
4323
|
-
const s = new Scalar(typeof value === "string" ? value : String(value));
|
|
4324
|
-
s.tag = tag;
|
|
4325
|
-
return s;
|
|
4326
|
-
}
|
|
4327
|
-
if (tag === "!GetAtt") {
|
|
4328
|
-
if (Array.isArray(value) && value.length === 2 && typeof value[0] === "string" && typeof value[1] === "string") {
|
|
4329
|
-
const s = new Scalar(`${value[0]}.${value[1]}`);
|
|
4330
|
-
s.tag = tag;
|
|
4331
|
-
return s;
|
|
4332
|
-
}
|
|
4333
|
-
const node = jsToYamlNode(value, doc);
|
|
4334
|
-
node.tag = tag;
|
|
4335
|
-
return node;
|
|
4336
|
-
}
|
|
4337
|
-
const node = jsToYamlNode(value, doc);
|
|
4338
|
-
node.tag = tag;
|
|
4339
|
-
return node;
|
|
4340
|
-
}
|
|
4341
|
-
function detectTemplateFormat(text) {
|
|
4342
|
-
const trimmed = (text.charCodeAt(0) === 65279 ? text.slice(1) : text).trimStart();
|
|
4343
|
-
if (trimmed.length === 0) return "json";
|
|
4344
|
-
const first = trimmed.charCodeAt(0);
|
|
4345
|
-
if (first === 123 || first === 91) return "json";
|
|
4346
|
-
return "yaml";
|
|
4347
|
-
}
|
|
4348
|
-
function parseCfnTemplateWithFormat(text) {
|
|
4349
|
-
const format = detectTemplateFormat(text);
|
|
4350
|
-
return {
|
|
4351
|
-
template: parseCfnTemplate(text),
|
|
4352
|
-
format
|
|
4353
|
-
};
|
|
4354
|
-
}
|
|
4355
|
-
|
|
4356
|
-
// src/cli/commands/retire-cfn-stack/retain-injection.ts
|
|
4357
|
-
async function uploadTemplateForUpdateStack(args) {
|
|
4358
|
-
return uploadCfnTemplate({
|
|
4359
|
-
bucket: args.bucket,
|
|
4360
|
-
body: args.body,
|
|
4361
|
-
stackName: args.cfnStackName,
|
|
4362
|
-
...args.format && { format: args.format },
|
|
4363
|
-
...args.s3ClientOpts && { s3ClientOpts: args.s3ClientOpts }
|
|
4364
|
-
});
|
|
4129
|
+
// src/cli/commands/diff-recursive/nested-template.ts
|
|
4130
|
+
const EMPTY_TEMPLATE = { Resources: {} };
|
|
4131
|
+
function isAbsoluteCrossPlatform(p) {
|
|
4132
|
+
return path.isAbsolute(p) || /^[a-zA-Z]:[\\/]/.test(p) || p.startsWith("\\\\");
|
|
4365
4133
|
}
|
|
4366
|
-
function
|
|
4367
|
-
|
|
4368
|
-
let parsed;
|
|
4134
|
+
function readNestedTemplate(templatePath) {
|
|
4135
|
+
let raw;
|
|
4369
4136
|
try {
|
|
4370
|
-
|
|
4137
|
+
raw = fs.readFileSync(templatePath, "utf-8");
|
|
4371
4138
|
} catch (err) {
|
|
4372
|
-
throw new Error(`
|
|
4373
|
-
}
|
|
4374
|
-
if (!("Resources" in parsed) || typeof parsed["Resources"] !== "object" || parsed["Resources"] === null || Array.isArray(parsed["Resources"])) throw new Error(`Template for '${cfnStackName}' has no Resources section — refusing to retire.`);
|
|
4375
|
-
const modified = injectRetainPoliciesOnParsedResources(parsed["Resources"]);
|
|
4376
|
-
return {
|
|
4377
|
-
body: stringifyCfnTemplate(parsed, format),
|
|
4378
|
-
modified,
|
|
4379
|
-
format
|
|
4380
|
-
};
|
|
4381
|
-
}
|
|
4382
|
-
function templateContainsNestedStackRows(templateBody) {
|
|
4383
|
-
let parsed;
|
|
4384
|
-
try {
|
|
4385
|
-
parsed = parseCfnTemplate(templateBody);
|
|
4386
|
-
} catch {
|
|
4387
|
-
return false;
|
|
4388
|
-
}
|
|
4389
|
-
const resources = parsed["Resources"];
|
|
4390
|
-
if (!resources || typeof resources !== "object" || Array.isArray(resources)) return false;
|
|
4391
|
-
for (const resource of Object.values(resources)) {
|
|
4392
|
-
if (!resource || typeof resource !== "object" || Array.isArray(resource)) continue;
|
|
4393
|
-
if (resource["Type"] === "AWS::CloudFormation::Stack") return true;
|
|
4394
|
-
}
|
|
4395
|
-
return false;
|
|
4396
|
-
}
|
|
4397
|
-
function injectRetainPoliciesOnParsedResources(resources) {
|
|
4398
|
-
let modified = false;
|
|
4399
|
-
for (const [, resource] of Object.entries(resources)) {
|
|
4400
|
-
if (!resource || typeof resource !== "object" || Array.isArray(resource)) continue;
|
|
4401
|
-
const r = resource;
|
|
4402
|
-
if (r["Type"] === "AWS::CloudFormation::Stack") continue;
|
|
4403
|
-
if (r["DeletionPolicy"] !== "Retain") {
|
|
4404
|
-
r["DeletionPolicy"] = "Retain";
|
|
4405
|
-
modified = true;
|
|
4406
|
-
}
|
|
4407
|
-
if (r["UpdateReplacePolicy"] !== "Retain") {
|
|
4408
|
-
r["UpdateReplacePolicy"] = "Retain";
|
|
4409
|
-
modified = true;
|
|
4410
|
-
}
|
|
4139
|
+
throw new Error(`Failed to read nested template at ${displayAssemblyPath(templatePath)}: ${describeFileReadFailure(err, templatePath)}`);
|
|
4411
4140
|
}
|
|
4412
|
-
return modified;
|
|
4413
|
-
}
|
|
4414
|
-
async function injectRetainPoliciesRecursive(rootTemplateBody, rootCfnStackName, rootTree, deps) {
|
|
4415
|
-
const cleanups = [];
|
|
4416
4141
|
try {
|
|
4417
|
-
return
|
|
4418
|
-
...await injectRetainPoliciesRecursiveInternal(rootTemplateBody, rootCfnStackName, rootTree, deps, cleanups),
|
|
4419
|
-
cleanups
|
|
4420
|
-
};
|
|
4142
|
+
return JSON.parse(raw);
|
|
4421
4143
|
} catch (err) {
|
|
4422
|
-
throw new
|
|
4144
|
+
throw new Error(`Failed to parse nested template at ${displayAssemblyPath(templatePath)}: ${describeFileReadFailure(err, templatePath)}`);
|
|
4423
4145
|
}
|
|
4424
4146
|
}
|
|
4425
|
-
|
|
4426
|
-
|
|
4427
|
-
|
|
4428
|
-
|
|
4429
|
-
|
|
4430
|
-
|
|
4431
|
-
|
|
4432
|
-
if (
|
|
4433
|
-
|
|
4434
|
-
};
|
|
4435
|
-
|
|
4436
|
-
const format = detectTemplateFormat(templateBody);
|
|
4437
|
-
let parsed;
|
|
4438
|
-
try {
|
|
4439
|
-
parsed = parseCfnTemplate(templateBody);
|
|
4440
|
-
} catch (err) {
|
|
4441
|
-
throw new Error(`Template for '${cfnStackName}' is not a valid CloudFormation template. cdkd's --migrate-from-cloudformation flow supports both JSON and YAML templates (YAML via a CFn-aware codec that preserves !Ref / !GetAtt / !Sub shorthand). Cause: ${describeAwsFailure(err).detail}`);
|
|
4442
|
-
}
|
|
4443
|
-
if (!("Resources" in parsed) || typeof parsed["Resources"] !== "object" || parsed["Resources"] === null || Array.isArray(parsed["Resources"])) throw new Error(`Template for '${cfnStackName}' has no Resources section — refusing to retire.`);
|
|
4444
|
-
const resources = parsed["Resources"];
|
|
4445
|
-
let modified = false;
|
|
4446
|
-
for (const [logicalId, resource] of Object.entries(resources)) {
|
|
4447
|
-
if (!resource || typeof resource !== "object" || Array.isArray(resource)) continue;
|
|
4448
|
-
const r = resource;
|
|
4449
|
-
if (r["Type"] !== "AWS::CloudFormation::Stack") continue;
|
|
4450
|
-
const childNode = tree.nested.get(logicalId);
|
|
4451
|
-
if (!childNode) throw new Error(`Template for '${cfnStackName}' has nested-stack '${logicalId}' (Type: ${NESTED_STACK_RESOURCE_TYPE}) but the CloudFormation resource tree has no matching child entry. AWS may have removed the child since DescribeStackResources ran, or the template was hand-edited mid-flight — re-run ${proseQuoted(cdkdRemedy("cdkd import", "--migrate-from-cloudformation"), "`")} to refresh.`);
|
|
4452
|
-
const childTpl = await deps.cfnClient.send(new GetTemplateCommand({
|
|
4453
|
-
StackName: childNode.physicalId,
|
|
4454
|
-
TemplateStage: "Original"
|
|
4455
|
-
}));
|
|
4456
|
-
if (!childTpl.TemplateBody) throw new Error(`GetTemplate returned no body for nested stack '${logicalId}' (physicalId='${childNode.physicalId}', parent='${cfnStackName}').`);
|
|
4457
|
-
const childResult = await injectRetainPoliciesRecursiveInternal(childTpl.TemplateBody, childNode.stackName, childNode, deps, cleanups);
|
|
4458
|
-
if (childResult.modified) {
|
|
4459
|
-
if (childResult.body.length > TEMPLATE_URL_LIMIT) throw new Error(`Modified nested-stack template for '${logicalId}' is ${childResult.body.length} bytes, exceeds the CloudFormation TemplateURL limit (${TEMPLATE_URL_LIMIT}). cdkd state has not been written; shrink the child template and retry, or retire the stack manually: (1) UpdateStack with Retain policies on the parent and each child, (2) cdkd import, (3) DeleteStack on the parent.`);
|
|
4460
|
-
const uploaded = await uploadCfnTemplate({
|
|
4461
|
-
bucket: deps.stateBucket,
|
|
4462
|
-
body: childResult.body,
|
|
4463
|
-
stackName: `${cfnStackName}__nested__${logicalId}`,
|
|
4464
|
-
format: childResult.format,
|
|
4465
|
-
...deps.s3ClientOpts && { s3ClientOpts: deps.s3ClientOpts }
|
|
4466
|
-
});
|
|
4467
|
-
cleanups.push(uploaded.cleanup);
|
|
4468
|
-
const propsRaw = r["Properties"];
|
|
4469
|
-
const props = propsRaw && typeof propsRaw === "object" && !Array.isArray(propsRaw) ? propsRaw : r["Properties"] = {};
|
|
4470
|
-
props["TemplateURL"] = uploaded.url;
|
|
4471
|
-
modified = true;
|
|
4472
|
-
}
|
|
4147
|
+
function indexNestedChildTemplates(template, templatePath) {
|
|
4148
|
+
const dir = path.dirname(templatePath);
|
|
4149
|
+
const result = nullPrototypeRecord();
|
|
4150
|
+
for (const [logicalId, resource] of Object.entries(template.Resources ?? {})) {
|
|
4151
|
+
if (resource?.Type !== "AWS::CloudFormation::Stack") continue;
|
|
4152
|
+
const assetPath = resource.Metadata?.["aws:asset:path"];
|
|
4153
|
+
if (typeof assetPath !== "string" || assetPath.length === 0) continue;
|
|
4154
|
+
if (isAbsoluteCrossPlatform(assetPath)) throw new Error(`Nested stack ${displayIdent(logicalId)} has Metadata['aws:asset:path']=${displayAssemblyPath(assetPath)} which is absolute. CDK emits relative asset paths for nested templates; an absolute path indicates the synth output was hand-modified or generated by a non-CDK toolchain. Refusing to load.`);
|
|
4155
|
+
const resolved = resolveAssemblyPath(dir, assetPath);
|
|
4156
|
+
if (!resolved.contained) throw new Error(`Nested stack ${displayIdent(logicalId)} has Metadata['aws:asset:path']=${displayAssemblyPath(assetPath)} which ${renderAssemblyPathEscape(resolved, dir)}`);
|
|
4157
|
+
result[logicalId] = resolved.path;
|
|
4473
4158
|
}
|
|
4474
|
-
|
|
4475
|
-
return {
|
|
4476
|
-
body: stringifyCfnTemplate(parsed, format),
|
|
4477
|
-
modified,
|
|
4478
|
-
format
|
|
4479
|
-
};
|
|
4159
|
+
return result;
|
|
4480
4160
|
}
|
|
4481
4161
|
|
|
4482
|
-
// src/cli/commands/
|
|
4483
|
-
|
|
4484
|
-
|
|
4485
|
-
|
|
4486
|
-
|
|
4487
|
-
|
|
4488
|
-
|
|
4489
|
-
const nestedChildren = [];
|
|
4490
|
-
for (const r of resp.StackResources ?? []) {
|
|
4491
|
-
if (!r.LogicalResourceId || !r.PhysicalResourceId) continue;
|
|
4492
|
-
resources.set(r.LogicalResourceId, r.PhysicalResourceId);
|
|
4493
|
-
if (r.ResourceType === "AWS::CloudFormation::Stack") nestedChildren.push({
|
|
4494
|
-
logicalId: r.LogicalResourceId,
|
|
4495
|
-
childArn: r.PhysicalResourceId
|
|
4496
|
-
});
|
|
4497
|
-
}
|
|
4498
|
-
const childPairs = await Promise.all(nestedChildren.map(async ({ logicalId, childArn }) => ({
|
|
4499
|
-
logicalId,
|
|
4500
|
-
node: await walkCfnStackTree(childArn, childArn, cfnClient)
|
|
4501
|
-
})));
|
|
4502
|
-
const nested = /* @__PURE__ */ new Map();
|
|
4503
|
-
for (const { logicalId, node } of childPairs) nested.set(logicalId, node);
|
|
4504
|
-
return {
|
|
4505
|
-
stackName,
|
|
4506
|
-
physicalId,
|
|
4507
|
-
resources,
|
|
4508
|
-
nested
|
|
4509
|
-
};
|
|
4510
|
-
}
|
|
4511
|
-
function findReplacedCfnResources(before, after, nestedPath = []) {
|
|
4512
|
-
const replaced = [];
|
|
4513
|
-
for (const [logicalId, beforeId] of before.resources) {
|
|
4514
|
-
const afterId = after.resources.get(logicalId);
|
|
4515
|
-
if (afterId !== void 0 && afterId !== beforeId) replaced.push({
|
|
4516
|
-
nestedPath,
|
|
4517
|
-
logicalId,
|
|
4518
|
-
before: beforeId,
|
|
4519
|
-
after: afterId
|
|
4520
|
-
});
|
|
4521
|
-
}
|
|
4522
|
-
for (const [childLogicalId, beforeChild] of before.nested) {
|
|
4523
|
-
const afterChild = after.nested.get(childLogicalId);
|
|
4524
|
-
if (afterChild) replaced.push(...findReplacedCfnResources(beforeChild, afterChild, [...nestedPath, childLogicalId]));
|
|
4525
|
-
}
|
|
4526
|
-
return replaced;
|
|
4162
|
+
// src/cli/commands/diff-recursive/cross-stack-taint.ts
|
|
4163
|
+
function crossStackTaintSeedsOf(template, region, preview) {
|
|
4164
|
+
if (preview === void 0 || !preview.anyTainted()) return /* @__PURE__ */ new Set();
|
|
4165
|
+
return crossStackTaintSeeds(template, (source) => {
|
|
4166
|
+
if (source === void 0) return true;
|
|
4167
|
+
return source.kind === "export" ? preview.exportTainted(region, source.name) : preview.stackOutputTainted(source.region ?? region, source.stackName, source.outputName);
|
|
4168
|
+
});
|
|
4527
4169
|
}
|
|
4528
|
-
|
|
4529
|
-
|
|
4530
|
-
|
|
4531
|
-
try {
|
|
4532
|
-
resp = await cfnClient.send(new DescribeStackResourcesCommand({ StackName: stackName }));
|
|
4533
|
-
} catch (err) {
|
|
4534
|
-
if (isStackNotFoundError(err)) {
|
|
4535
|
-
logger.debug(`No CloudFormation stack named '${stackName}'.`);
|
|
4536
|
-
return null;
|
|
4537
|
-
}
|
|
4538
|
-
const reason = describeAwsFailure(err).detail;
|
|
4539
|
-
const subject = isPasteableIdent(stackName) ? `CloudFormation stack '${stackName}'` : "a CloudFormation stack whose name is not a plain identifier";
|
|
4540
|
-
logger.warn(`Could not read ${subject} to resolve physical IDs (${reason}).\nFalling back to per-resource lookup; resources whose physical name CloudFormation generated may be reported as not found. Grant cloudformation:DescribeStackResources, or pass --resource ${commandHole("LogicalId")}=${commandHole("physicalId")} for those resources.`);
|
|
4541
|
-
return null;
|
|
4542
|
-
}
|
|
4543
|
-
const resources = /* @__PURE__ */ new Map();
|
|
4544
|
-
for (const r of resp.StackResources ?? []) {
|
|
4545
|
-
if (!r.LogicalResourceId || !r.PhysicalResourceId) continue;
|
|
4546
|
-
resources.set(r.LogicalResourceId, r.PhysicalResourceId);
|
|
4547
|
-
}
|
|
4548
|
-
return resources;
|
|
4170
|
+
function producerReadsSecretFedName(tainted) {
|
|
4171
|
+
if (tainted === void 0 || tainted.size === 0) return void 0;
|
|
4172
|
+
return (value) => readsTainted(value, tainted);
|
|
4549
4173
|
}
|
|
4550
|
-
|
|
4551
|
-
|
|
4552
|
-
|
|
4553
|
-
return
|
|
4174
|
+
const MAX_NESTED_DEPTH$2 = 32;
|
|
4175
|
+
function taintedOutputsOf(template, tainted) {
|
|
4176
|
+
if (tainted.size === 0) return [];
|
|
4177
|
+
return Object.entries(template.Outputs ?? {}).filter(([, raw]) => {
|
|
4178
|
+
const output = raw;
|
|
4179
|
+
return readsTainted(output?.Value, tainted) || readsTainted(output?.Export, tainted);
|
|
4180
|
+
});
|
|
4554
4181
|
}
|
|
4555
|
-
|
|
4556
|
-
|
|
4557
|
-
|
|
4558
|
-
|
|
4559
|
-
|
|
4560
|
-
|
|
4561
|
-
|
|
4562
|
-
|
|
4563
|
-
|
|
4182
|
+
function readChild(path, cache) {
|
|
4183
|
+
if (!cache.has(path)) try {
|
|
4184
|
+
const template = readNestedTemplate(path);
|
|
4185
|
+
cache.set(path, {
|
|
4186
|
+
template,
|
|
4187
|
+
children: indexNestedChildTemplates(template, path)
|
|
4188
|
+
});
|
|
4189
|
+
} catch {
|
|
4190
|
+
cache.set(path, null);
|
|
4191
|
+
}
|
|
4192
|
+
return cache.get(path) ?? null;
|
|
4193
|
+
}
|
|
4194
|
+
function subtreeTaintedNames(template, nestedTemplates, passed, preview, walk = {}) {
|
|
4195
|
+
const seeds = [...passed, ...crossStackTaintSeedsOf(template, "", preview)];
|
|
4196
|
+
let tainted = taintedNamesOf(template, seeds);
|
|
4197
|
+
const ancestors = walk.ancestors ?? /* @__PURE__ */ new Set();
|
|
4198
|
+
const depth = walk.depth ?? 0;
|
|
4199
|
+
if (nestedTemplates === void 0 || depth >= MAX_NESTED_DEPTH$2) return tainted;
|
|
4200
|
+
const cache = walk.cache ?? /* @__PURE__ */ new Map();
|
|
4201
|
+
const rows = /* @__PURE__ */ new Set();
|
|
4202
|
+
for (const [logicalId, raw] of Object.entries(template.Resources ?? {})) {
|
|
4203
|
+
if (raw?.Type !== "AWS::CloudFormation::Stack" || !Object.hasOwn(nestedTemplates, logicalId)) continue;
|
|
4204
|
+
const childPath = nestedTemplates[logicalId];
|
|
4205
|
+
if (ancestors.has(childPath)) continue;
|
|
4206
|
+
const child = readChild(childPath, cache);
|
|
4207
|
+
if (child === null) continue;
|
|
4208
|
+
const parameters = raw.Properties?.Parameters;
|
|
4209
|
+
const childPassed = [];
|
|
4210
|
+
if (parameters !== null && typeof parameters === "object" && !Array.isArray(parameters)) {
|
|
4211
|
+
for (const [key, value] of Object.entries(parameters)) if (readsTainted(value, tainted) || templateMixesDynamicReference(value)) childPassed.push(key);
|
|
4212
|
+
}
|
|
4213
|
+
const childTainted = subtreeTaintedNames(child.template, child.children, childPassed, preview, {
|
|
4214
|
+
...walk,
|
|
4215
|
+
cache,
|
|
4216
|
+
ancestors: /* @__PURE__ */ new Set([...ancestors, childPath]),
|
|
4217
|
+
depth: depth + 1
|
|
4218
|
+
});
|
|
4219
|
+
const outputs = taintedOutputsOf(child.template, childTainted);
|
|
4220
|
+
for (const [name, output] of outputs) walk.onChildOutput?.(childPath, name, output);
|
|
4221
|
+
if (outputs.length > 0) rows.add(logicalId);
|
|
4222
|
+
}
|
|
4223
|
+
if (rows.size > 0) tainted = taintedNamesOf(template, [...seeds, ...rows]);
|
|
4224
|
+
return tainted;
|
|
4225
|
+
}
|
|
4226
|
+
function exportNameOf(output, stackName) {
|
|
4227
|
+
if (output?.Export === void 0) return void 0;
|
|
4228
|
+
const name = output.Export.Name;
|
|
4229
|
+
if (typeof name === "string") return name;
|
|
4230
|
+
const sub = name?.["Fn::Sub"];
|
|
4231
|
+
if (stackName !== void 0 && name !== null && typeof name === "object" && Object.keys(name).length === 1 && typeof sub === "string") {
|
|
4232
|
+
const resolved = sub.split("${AWS::StackName}").join(stackName);
|
|
4233
|
+
if (!resolved.includes("${")) return resolved;
|
|
4564
4234
|
}
|
|
4235
|
+
return null;
|
|
4565
4236
|
}
|
|
4566
|
-
|
|
4567
|
-
const
|
|
4568
|
-
const
|
|
4569
|
-
|
|
4570
|
-
|
|
4571
|
-
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4575
|
-
|
|
4576
|
-
|
|
4577
|
-
|
|
4578
|
-
TemplateStage: "Original"
|
|
4579
|
-
}));
|
|
4580
|
-
if (!tpl.TemplateBody) throw new Error(`GetTemplate returned no body for '${cfnStackName}'.`);
|
|
4581
|
-
const nestedCleanups = [];
|
|
4582
|
-
const hasNestedChildren = templateContainsNestedStackRows(tpl.TemplateBody);
|
|
4583
|
-
let newBody;
|
|
4584
|
-
let modified;
|
|
4585
|
-
let format;
|
|
4586
|
-
if (hasNestedChildren) {
|
|
4587
|
-
const tree = resourceTree ?? await getCloudFormationResourceTree(cfnStackName, cfnClient);
|
|
4588
|
-
try {
|
|
4589
|
-
const recursive = await injectRetainPoliciesRecursive(tpl.TemplateBody, cfnStackName, tree, {
|
|
4590
|
-
cfnClient,
|
|
4591
|
-
stateBucket,
|
|
4592
|
-
...s3ClientOpts && { s3ClientOpts }
|
|
4593
|
-
});
|
|
4594
|
-
newBody = recursive.body;
|
|
4595
|
-
modified = recursive.modified;
|
|
4596
|
-
format = recursive.format;
|
|
4597
|
-
nestedCleanups.push(...recursive.cleanups);
|
|
4598
|
-
} catch (err) {
|
|
4599
|
-
if (err instanceof RecursiveRetainInjectionError) await drainTemplateUploads(err.cleanups, stateBucket, {
|
|
4600
|
-
what: "partial nested-template upload",
|
|
4601
|
-
when: "during error recovery"
|
|
4602
|
-
});
|
|
4603
|
-
throw err;
|
|
4604
|
-
}
|
|
4605
|
-
} else ({body: newBody, modified, format} = injectRetainPolicies(tpl.TemplateBody, cfnStackName));
|
|
4606
|
-
if (!yes) {
|
|
4607
|
-
let proceed = false;
|
|
4608
|
-
try {
|
|
4609
|
-
proceed = await confirmPrompt$6(`Set DeletionPolicy=Retain and UpdateReplacePolicy=Retain on every resource in CloudFormation stack '${cfnStackName}', and delete the stack once cdkd state is written? AWS resources will NOT be deleted.`);
|
|
4610
|
-
} finally {
|
|
4611
|
-
if (!proceed) await drainTemplateUploads(nestedCleanups, stateBucket, {
|
|
4612
|
-
what: "temporary nested-template upload",
|
|
4613
|
-
when: "during cancel cleanup"
|
|
4614
|
-
});
|
|
4615
|
-
}
|
|
4616
|
-
if (!proceed) {
|
|
4617
|
-
logger.info("CloudFormation stack retirement cancelled. The stack is unchanged and will not be deleted.");
|
|
4618
|
-
return { outcome: "cancelled" };
|
|
4619
|
-
}
|
|
4620
|
-
}
|
|
4621
|
-
let templateUpdated = false;
|
|
4622
|
-
if (!modified) {
|
|
4623
|
-
logger.info(`[2/4] Template already has Retain on every resource — skipping UpdateStack.`);
|
|
4624
|
-
await drainTemplateUploads(nestedCleanups, stateBucket, { what: "temporary nested-template upload" });
|
|
4625
|
-
} else {
|
|
4626
|
-
logger.info(`[2/4] Injected DeletionPolicy=Retain and UpdateReplacePolicy=Retain.`);
|
|
4627
|
-
if (newBody.length > TEMPLATE_URL_LIMIT) throw new Error(`Modified template is ${newBody.length} bytes, exceeds the CloudFormation UpdateStack TemplateURL limit (${TEMPLATE_URL_LIMIT}). cdkd state has not been written; shrink or split the template and retry. ` + MANUAL_RETIREMENT_ROUTE);
|
|
4628
|
-
let updateInput;
|
|
4629
|
-
let s3Cleanup;
|
|
4630
|
-
if (newBody.length <= TEMPLATE_BODY_LIMIT) updateInput = { TemplateBody: newBody };
|
|
4631
|
-
else {
|
|
4632
|
-
logger.info(` Template is ${newBody.length} bytes (over ${TEMPLATE_BODY_LIMIT} inline limit) — uploading to state bucket '${stateBucket}'.`);
|
|
4633
|
-
const uploaded = await uploadTemplateForUpdateStack({
|
|
4634
|
-
bucket: stateBucket,
|
|
4635
|
-
body: newBody,
|
|
4636
|
-
cfnStackName,
|
|
4637
|
-
format,
|
|
4638
|
-
...s3ClientOpts && { s3ClientOpts }
|
|
4639
|
-
});
|
|
4640
|
-
updateInput = { TemplateURL: uploaded.url };
|
|
4641
|
-
s3Cleanup = uploaded.cleanup;
|
|
4642
|
-
}
|
|
4643
|
-
try {
|
|
4644
|
-
logger.info(`[3/4] Updating CloudFormation stack with Retain policies...`);
|
|
4645
|
-
let updateRan = false;
|
|
4646
|
-
try {
|
|
4647
|
-
const previousParameters = (stack.Parameters ?? []).map((p) => ({
|
|
4648
|
-
ParameterKey: p.ParameterKey,
|
|
4649
|
-
UsePreviousValue: true
|
|
4650
|
-
}));
|
|
4651
|
-
await cfnClient.send(new UpdateStackCommand({
|
|
4652
|
-
StackName: cfnStackName,
|
|
4653
|
-
...updateInput,
|
|
4654
|
-
Capabilities: capabilities,
|
|
4655
|
-
...previousParameters.length > 0 && { Parameters: previousParameters }
|
|
4656
|
-
}));
|
|
4657
|
-
updateRan = true;
|
|
4658
|
-
} catch (err) {
|
|
4659
|
-
const msg = describeAwsFailure(err).detail;
|
|
4660
|
-
if (/No updates are to be performed/i.test(msg)) logger.info(` CloudFormation reports no updates needed.`);
|
|
4661
|
-
else throw new RetainUpdateFailedError(cfnStackName, "rejected", err);
|
|
4662
|
-
}
|
|
4663
|
-
if (updateRan) {
|
|
4664
|
-
try {
|
|
4665
|
-
await waitUntilStackUpdateComplete({
|
|
4666
|
-
client: cfnClient,
|
|
4667
|
-
maxWaitTime: 1800,
|
|
4668
|
-
minDelay: 5,
|
|
4669
|
-
maxDelay: 10
|
|
4670
|
-
}, { StackName: cfnStackName });
|
|
4671
|
-
} catch (err) {
|
|
4672
|
-
throw new RetainUpdateFailedError(cfnStackName, "unfinished", err);
|
|
4237
|
+
function markAppProducerTaint(preview, stacks) {
|
|
4238
|
+
const topLevel = new Set(stacks.map((stack) => stack.stackName));
|
|
4239
|
+
const cache = /* @__PURE__ */ new Map();
|
|
4240
|
+
let grew = true;
|
|
4241
|
+
while (grew) {
|
|
4242
|
+
grew = false;
|
|
4243
|
+
for (const { stackName, template, nestedTemplates } of stacks) {
|
|
4244
|
+
const tainted = subtreeTaintedNames(template, nestedTemplates, [], preview, {
|
|
4245
|
+
cache,
|
|
4246
|
+
onChildOutput: (childPath, outputName, output) => {
|
|
4247
|
+
if (preview.markTainted(childPath, outputName, exportNameOf(output, void 0))) grew = true;
|
|
4248
|
+
preview.markNestedOutputsTainted(topLevel);
|
|
4673
4249
|
}
|
|
4674
|
-
|
|
4675
|
-
|
|
4676
|
-
} finally {
|
|
4677
|
-
await drainTemplateUploads([...s3Cleanup ? [s3Cleanup] : [], ...nestedCleanups], stateBucket, { what: "temporary template upload" });
|
|
4250
|
+
});
|
|
4251
|
+
for (const [outputName, output] of taintedOutputsOf(template, tainted)) if (preview.markTainted(stackName, outputName, exportNameOf(output, stackName))) grew = true;
|
|
4678
4252
|
}
|
|
4679
4253
|
}
|
|
4680
|
-
return {
|
|
4681
|
-
outcome: "ready",
|
|
4682
|
-
templateUpdated
|
|
4683
|
-
};
|
|
4684
|
-
}
|
|
4685
|
-
async function confirmPrompt$6(prompt) {
|
|
4686
|
-
return confirmOrRefuse(prompt, { refusal: `The CloudFormation stack retirement confirmation prompt cannot run in a non-interactive environment. Pass -y / --yes on ${cdkdRemedy("cdkd import", "--migrate-from-cloudformation")}. Alternatively, run it from a real terminal. Nothing has been written yet: cdkd state and the CloudFormation stack are unchanged, so re-running with -y / --yes is the whole recovery.` });
|
|
4687
|
-
}
|
|
4688
|
-
|
|
4689
|
-
// src/cli/commands/retire-cfn-stack/delete-stack.ts
|
|
4690
|
-
async function deleteRetiredCloudFormationStack(cfnStackName, cfnClient) {
|
|
4691
|
-
const logger = getLogger();
|
|
4692
|
-
logger.info(`[4/4] Deleting CloudFormation stack '${cfnStackName}' (resources retained)...`);
|
|
4693
|
-
try {
|
|
4694
|
-
await cfnClient.send(new DeleteStackCommand({ StackName: cfnStackName }));
|
|
4695
|
-
await waitUntilStackDeleteComplete({
|
|
4696
|
-
client: cfnClient,
|
|
4697
|
-
maxWaitTime: 1800,
|
|
4698
|
-
minDelay: 5,
|
|
4699
|
-
maxDelay: 10
|
|
4700
|
-
}, { StackName: cfnStackName });
|
|
4701
|
-
} catch (err) {
|
|
4702
|
-
const error = /* @__PURE__ */ new Error(safeMsg`CloudFormation stack ${displaySafe(cfnStackName)} was NOT confirmed deleted: ` + safeMsg`${cfnFailureText(err)}. cdkd state is written and correct, and every resource ` + "carries DeletionPolicy=Retain, so deleting the stack deletes no resource. Delete the stack by hand once its cause is resolved (for example an export another stack still imports).");
|
|
4703
|
-
error.cause = err;
|
|
4704
|
-
throw error;
|
|
4705
|
-
}
|
|
4706
|
-
logger.info(`✓ CloudFormation stack '${cfnStackName}' retired. AWS resources are now solely managed by cdkd.`);
|
|
4707
4254
|
}
|
|
4708
4255
|
|
|
4709
4256
|
// src/cli/commands/diff-recursive/refusals.ts
|
|
@@ -4711,7 +4258,7 @@ function deployRefusesPropertiesReason(logicalIds) {
|
|
|
4711
4258
|
return `${logicalIds.length} resource record(s) hold a 'properties' map that cannot be read. This preview repaired them to empty; 'cdkd deploy' refuses the record instead, so the deploy this previews will not start.`;
|
|
4712
4259
|
}
|
|
4713
4260
|
function nestedStackTypeChangeReason(tc) {
|
|
4714
|
-
return `${displayIdent(tc.logicalId)}: Type changes from ${displayIdent(tc.currentType)} to ${displayIdent(tc.desiredType)}. cdkd does not replace a resource into or out of ${NESTED_STACK_RESOURCE_TYPE}; give the new resource a different logical id, or remove it in one deploy and add its replacement in the next.`;
|
|
4261
|
+
return `${displayIdent(tc.logicalId)}: Type changes from ${displayIdent(tc.currentType)} to ${displayIdent(tc.desiredType)}. cdkd does not replace a resource into or out of ${NESTED_STACK_RESOURCE_TYPE$1}; give the new resource a different logical id, or remove it in one deploy and add its replacement in the next.`;
|
|
4715
4262
|
}
|
|
4716
4263
|
function findUnroutableDropRefusals(template, stateResources, ccRouteUnavailableReason, conditionSettled = () => true) {
|
|
4717
4264
|
const reasons = [];
|
|
@@ -4765,38 +4312,20 @@ function deployRefusesDroppedOrphanRowsReason(logicalIds) {
|
|
|
4765
4312
|
return `${logicalIds.length} rollback-orphan record(s) in 'orphans' cannot be read as resources. This preview dropped them; 'cdkd deploy' refuses the record instead, so the deploy this previews will not start.`;
|
|
4766
4313
|
}
|
|
4767
4314
|
const EMPTY_ALLOW_SET = /* @__PURE__ */ new Set();
|
|
4768
|
-
|
|
4769
|
-
|
|
4770
|
-
|
|
4771
|
-
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
-
|
|
4775
|
-
|
|
4776
|
-
|
|
4777
|
-
|
|
4778
|
-
|
|
4779
|
-
|
|
4780
|
-
|
|
4781
|
-
|
|
4782
|
-
return JSON.parse(raw);
|
|
4783
|
-
} catch (err) {
|
|
4784
|
-
throw new Error(`Failed to parse nested template at ${displayAssemblyPath(templatePath)}: ${describeFileReadFailure(err, templatePath)}`);
|
|
4785
|
-
}
|
|
4786
|
-
}
|
|
4787
|
-
function indexNestedChildTemplates(template, templatePath) {
|
|
4788
|
-
const dir = path.dirname(templatePath);
|
|
4789
|
-
const result = nullPrototypeRecord();
|
|
4790
|
-
for (const [logicalId, resource] of Object.entries(template.Resources ?? {})) {
|
|
4791
|
-
if (resource?.Type !== "AWS::CloudFormation::Stack") continue;
|
|
4792
|
-
const assetPath = resource.Metadata?.["aws:asset:path"];
|
|
4793
|
-
if (typeof assetPath !== "string" || assetPath.length === 0) continue;
|
|
4794
|
-
if (isAbsoluteCrossPlatform(assetPath)) throw new Error(`Nested stack ${displayIdent(logicalId)} has Metadata['aws:asset:path']=${displayAssemblyPath(assetPath)} which is absolute. CDK emits relative asset paths for nested templates; an absolute path indicates the synth output was hand-modified or generated by a non-CDK toolchain. Refusing to load.`);
|
|
4795
|
-
const resolved = resolveAssemblyPath(dir, assetPath);
|
|
4796
|
-
if (!resolved.contained) throw new Error(`Nested stack ${displayIdent(logicalId)} has Metadata['aws:asset:path']=${displayAssemblyPath(assetPath)} which ${renderAssemblyPathEscape(resolved, dir)}`);
|
|
4797
|
-
result[logicalId] = resolved.path;
|
|
4798
|
-
}
|
|
4799
|
-
return result;
|
|
4315
|
+
function previewTypeAndServiceTokenRefusals(changes, stateResources, maskForLog) {
|
|
4316
|
+
const blocking = findNestedStackTypeChanges({
|
|
4317
|
+
changes,
|
|
4318
|
+
stateResources
|
|
4319
|
+
}).map(nestedStackTypeChangeReason);
|
|
4320
|
+
const serviceTokens = findServiceTokenRefusals({
|
|
4321
|
+
changes,
|
|
4322
|
+
stateResources
|
|
4323
|
+
});
|
|
4324
|
+
blocking.push(...serviceTokens.refused.map((refusal) => serviceTokenBlockingReason(refusal, maskForLog)));
|
|
4325
|
+
return {
|
|
4326
|
+
blocking,
|
|
4327
|
+
warnings: serviceTokens.deferred.map(deferredServiceTokenWarning)
|
|
4328
|
+
};
|
|
4800
4329
|
}
|
|
4801
4330
|
|
|
4802
4331
|
// src/cli/commands/diff-recursive/printing.ts
|
|
@@ -5817,7 +5346,7 @@ function noEchoFedChildParameters(parentStackRow, parentNoEchoParameters, parent
|
|
|
5817
5346
|
})) fed.add(name);
|
|
5818
5347
|
return fed;
|
|
5819
5348
|
}
|
|
5820
|
-
async function resolveChildStackParameters(parentStackRow, parentTemplate, parentState, region, parentStackName, stateBackend, parentParameters, parentConditions, cfnFallback, printingSecrets, attributeHealer, unresolvedKeys, trust, derivedNameSink, producerLookup, consumerAccount, secretTokens) {
|
|
5349
|
+
async function resolveChildStackParameters(parentStackRow, parentTemplate, parentState, region, parentStackName, stateBackend, parentParameters, parentConditions, cfnFallback, printingSecrets, attributeHealer, unresolvedKeys, trust, derivedNameSink, producerLookup, consumerAccount, secretTokens, crossStackPreview) {
|
|
5821
5350
|
const rawParams = parentStackRow.Properties?.["Parameters"];
|
|
5822
5351
|
if (!rawParams || typeof rawParams !== "object" || Array.isArray(rawParams)) return {};
|
|
5823
5352
|
const inheritedStandIns = standInTokensOf(secretTokens?.inherited);
|
|
@@ -5838,6 +5367,7 @@ async function resolveChildStackParameters(parentStackRow, parentTemplate, paren
|
|
|
5838
5367
|
secretNameSink: derivedNameSink ?? /* @__PURE__ */ new Map(),
|
|
5839
5368
|
stateBackend,
|
|
5840
5369
|
stackName: parentStackName,
|
|
5370
|
+
...crossStackPreview && { crossStackPreview },
|
|
5841
5371
|
stackIdTail: () => stackIdTailOf(parentState, parentStackName),
|
|
5842
5372
|
stackIdOverride: () => parentState?.signalReceiverStackId,
|
|
5843
5373
|
bestEffort: true,
|
|
@@ -5988,9 +5518,72 @@ async function previewNoEchoMacChanges(args) {
|
|
|
5988
5518
|
return moved;
|
|
5989
5519
|
}
|
|
5990
5520
|
|
|
5521
|
+
// src/cli/commands/diff-recursive/replace-resource-preview.ts
|
|
5522
|
+
async function previewReplaceResourceTargets(input) {
|
|
5523
|
+
if (input.targetIds === void 0 || input.targetIds.size === 0) return [];
|
|
5524
|
+
let replaced;
|
|
5525
|
+
try {
|
|
5526
|
+
const draft = new Map([...input.changes].map(([id, change]) => [id, { ...change }]));
|
|
5527
|
+
const plan = planReplaceResourceTargets(draft, input.targetIds);
|
|
5528
|
+
replaced = plan.replaced;
|
|
5529
|
+
for (const id of replaced) input.changes.set(id, draft.get(id));
|
|
5530
|
+
for (const target of plan.unreplaced) input.warn(renderUnreplacedTarget(input.stackName, target));
|
|
5531
|
+
} catch (error) {
|
|
5532
|
+
if (error instanceof CdkdError && error.code === "REPLACE_RESOURCE_REFUSED") return [error.message];
|
|
5533
|
+
throw error;
|
|
5534
|
+
}
|
|
5535
|
+
const stateful = async (check) => {
|
|
5536
|
+
try {
|
|
5537
|
+
await check();
|
|
5538
|
+
} catch (error) {
|
|
5539
|
+
if (!(error instanceof CdkdError && error.code === "STATEFUL_REPLACE_BLOCKED")) throw error;
|
|
5540
|
+
input.warn(`cdkd deploy refuses this plan unless --force-stateful-recreation is passed:\n${error.message}`);
|
|
5541
|
+
}
|
|
5542
|
+
};
|
|
5543
|
+
await stateful(() => refuseStatefulReplaceResourceTargets({
|
|
5544
|
+
targetIds: replaced,
|
|
5545
|
+
state: input.state,
|
|
5546
|
+
template: input.template,
|
|
5547
|
+
forceStatefulRecreation: false
|
|
5548
|
+
}));
|
|
5549
|
+
await stateful(() => refuseStatefulReplacedReaders({
|
|
5550
|
+
template: input.template,
|
|
5551
|
+
state: input.state,
|
|
5552
|
+
targetIds: replaced,
|
|
5553
|
+
conditions: input.conditions,
|
|
5554
|
+
forceStatefulRecreation: false,
|
|
5555
|
+
targetFlag: "--replace-resource"
|
|
5556
|
+
}));
|
|
5557
|
+
return [];
|
|
5558
|
+
}
|
|
5559
|
+
async function previewReplaceResourcePlan(input) {
|
|
5560
|
+
const { diff, settle, ...plan } = input;
|
|
5561
|
+
const changes = await diff(plan.targetIds);
|
|
5562
|
+
const settled = await settle(changes);
|
|
5563
|
+
const blocking = await previewReplaceResourceTargets({
|
|
5564
|
+
...plan,
|
|
5565
|
+
changes
|
|
5566
|
+
});
|
|
5567
|
+
if (blocking.length === 0 || plan.targetIds === void 0) return {
|
|
5568
|
+
changes,
|
|
5569
|
+
settled,
|
|
5570
|
+
blocking
|
|
5571
|
+
};
|
|
5572
|
+
const unseeded = await diff(void 0, true);
|
|
5573
|
+
return {
|
|
5574
|
+
changes: unseeded,
|
|
5575
|
+
settled: await settle(unseeded),
|
|
5576
|
+
blocking
|
|
5577
|
+
};
|
|
5578
|
+
}
|
|
5579
|
+
function withoutWarnings(calculator) {
|
|
5580
|
+
const logger = Object.create(calculator.logger, { warn: { value: () => void 0 } });
|
|
5581
|
+
return Object.create(calculator, { logger: { value: logger } });
|
|
5582
|
+
}
|
|
5583
|
+
|
|
5991
5584
|
// src/cli/commands/diff-recursive/compute-stack-diff.ts
|
|
5992
5585
|
async function computeStackDiff(loadedState, template, region, stackName, stateBackend, diffCalculator, options = {}) {
|
|
5993
|
-
const { parameters, canonicalizeProperties, ccRouteUnavailableReason, cfnFallback, producerLookup, consumerAccount, noEchoMacCache, macWriteOnlyLookups, inheritSecretBearingTemplate, inheritedSecrets, inheritedSecretTokens, inheritedDerivedNames, attributeHealer: unboundAttributeHealer, readLiveDbInstanceZone, parentUnresolvedParameters, inheritedNoEchoParameters, inheritedNoEchoParametersAnyVerdict, ssmNameHeal = "apply", crossStackPreview, recordCrossStackPreview } = options;
|
|
5586
|
+
const { parameters, canonicalizeProperties, ccRouteUnavailableReason, cfnFallback, producerLookup, consumerAccount, noEchoMacCache, macWriteOnlyLookups, inheritSecretBearingTemplate, inheritedSecrets, inheritedSecretTokens, inheritedDerivedNames, attributeHealer: unboundAttributeHealer, readLiveDbInstanceZone, parentUnresolvedParameters, inheritedNoEchoParameters, inheritedNoEchoParametersAnyVerdict, ssmNameHeal = "apply", crossStackPreview, recordCrossStackPreview, secretFedNames } = options;
|
|
5994
5587
|
const currentState = previewSsmNameHeal(loadedState, template, stackName, ssmNameHeal);
|
|
5995
5588
|
let healResources = currentState.resources ?? {};
|
|
5996
5589
|
let healNamingSecrets;
|
|
@@ -6116,48 +5709,66 @@ async function computeStackDiff(loadedState, template, region, stackName, stateB
|
|
|
6116
5709
|
unbound: unboundParameterNames
|
|
6117
5710
|
});
|
|
6118
5711
|
const resourcesForInputs = stateForDiff.resources;
|
|
6119
|
-
maskedInputs = {
|
|
6120
|
-
|
|
6121
|
-
|
|
6122
|
-
|
|
6123
|
-
|
|
6124
|
-
|
|
6125
|
-
|
|
6126
|
-
|
|
6127
|
-
|
|
6128
|
-
|
|
6129
|
-
|
|
6130
|
-
|
|
6131
|
-
|
|
6132
|
-
|
|
6133
|
-
|
|
6134
|
-
|
|
6135
|
-
|
|
6136
|
-
|
|
6137
|
-
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
|
|
6143
|
-
|
|
6144
|
-
|
|
6145
|
-
|
|
6146
|
-
|
|
5712
|
+
maskedInputs = {
|
|
5713
|
+
sources: {
|
|
5714
|
+
template: effectiveTemplate,
|
|
5715
|
+
parameterInput: classified.parameterInput,
|
|
5716
|
+
conditions,
|
|
5717
|
+
childTemplate: childTemplateLoader(options.nestedTemplates),
|
|
5718
|
+
resolve: async (node) => {
|
|
5719
|
+
const secrets = /* @__PURE__ */ new Map();
|
|
5720
|
+
return {
|
|
5721
|
+
value: await intrinsicResolver.resolve(structuredClone(node), {
|
|
5722
|
+
recordedSecretValues: secrets,
|
|
5723
|
+
secretNameNeedles: stateSecretNameNeedles(resourcesForInputs, liveNamingJudge(resourcesForInputs)),
|
|
5724
|
+
secretNameSink: derivedNames,
|
|
5725
|
+
template: effectiveTemplate,
|
|
5726
|
+
resources: resourcesForInputs,
|
|
5727
|
+
stateBackend,
|
|
5728
|
+
stackName,
|
|
5729
|
+
stackIdTail: () => stackIdTailOf(currentState, stackName),
|
|
5730
|
+
stackIdOverride: () => currentState?.signalReceiverStackId,
|
|
5731
|
+
bestEffort: true,
|
|
5732
|
+
...Object.keys(classified.bound).length > 0 && { parameters: classified.bound },
|
|
5733
|
+
...conditions && Object.keys(conditions).length > 0 && { conditions },
|
|
5734
|
+
skipDynamicReferences: true,
|
|
5735
|
+
staleAttributeHeal: { phase: "probe" }
|
|
5736
|
+
}),
|
|
5737
|
+
secrets
|
|
5738
|
+
};
|
|
5739
|
+
}
|
|
5740
|
+
},
|
|
5741
|
+
publicReferences: publicReferencesOf(diffSecrets, [
|
|
5742
|
+
diffSecrets,
|
|
5743
|
+
noEchoParameterValueSeed(effectiveTemplate.Parameters, mergedParameters, inheritedForResolver, parameters),
|
|
5744
|
+
inheritedSecrets
|
|
5745
|
+
])
|
|
5746
|
+
};
|
|
6147
5747
|
}
|
|
6148
|
-
const
|
|
5748
|
+
const diffWith = (forcedReplacements, quiet) => (quiet === true ? withoutWarnings(diffCalculator) : diffCalculator).calculateDiff(stateForDiff, effectiveTemplate, resolveFn, canonicalizeProperties, void 0, void 0, maskForLog, forcedReplacements, maskedInputs, options.refusalRecovery, noEchoComparisonForTemplate(effectiveTemplate, namingConditions, mergedParameters, stateForDiff.resources, /* @__PURE__ */ new Set([region, stackName]), inheritedNoEchoParameters), {
|
|
6149
5749
|
...options.inheritedReferenceProvenance && { inherited: options.inheritedReferenceProvenance },
|
|
6150
5750
|
crossStackOutputs: crossStackOutputProvenanceSource(crossStackReads, crossStackReads, stateBackend)
|
|
6151
5751
|
}, options.forcedNestedChildRuns, options.updatePolicy === true);
|
|
6152
|
-
|
|
6153
|
-
|
|
6154
|
-
|
|
6155
|
-
|
|
6156
|
-
|
|
5752
|
+
const planned = await previewReplaceResourcePlan({
|
|
5753
|
+
diff: diffWith,
|
|
5754
|
+
settle: (rows) => settleStackTagChildRuns({
|
|
5755
|
+
changes: rows,
|
|
5756
|
+
template: effectiveTemplate,
|
|
5757
|
+
stackTags: options.stackTags,
|
|
5758
|
+
state: stateForDiff,
|
|
5759
|
+
resolve: resolveFn,
|
|
5760
|
+
secrets: diffSecrets
|
|
5761
|
+
}),
|
|
5762
|
+
targetIds: options.replaceResources,
|
|
5763
|
+
stackName,
|
|
6157
5764
|
state: stateForDiff,
|
|
6158
|
-
|
|
6159
|
-
|
|
5765
|
+
template: effectiveTemplate,
|
|
5766
|
+
conditions: namingConditions ?? {},
|
|
5767
|
+
warn: (message) => logger.warn(printing.mask(message))
|
|
6160
5768
|
});
|
|
5769
|
+
const { changes, settled: childStackTags } = planned;
|
|
5770
|
+
blocking = [...blocking, ...planned.blocking];
|
|
5771
|
+
warnLegacySpelling(changes, effectiveTemplate, stackName, logger);
|
|
6161
5772
|
const macConditions = conditions === void 0 ? void 0 : Object.fromEntries(Object.entries(conditions).filter(([name]) => !stillUnknown.includes(name)));
|
|
6162
5773
|
const macMoved = await previewNoEchoMacChanges({
|
|
6163
5774
|
changes,
|
|
@@ -6183,17 +5794,9 @@ async function computeStackDiff(loadedState, template, region, stackName, stateB
|
|
|
6183
5794
|
...conditions !== void 0 && { conditions: Object.fromEntries(Object.entries(conditions).filter(([name]) => !stillUnknown.includes(name))) }
|
|
6184
5795
|
}));
|
|
6185
5796
|
if (noEchoReaders.length > 0) logger.info(safeMsg`Stack ${displayStackName(stackName)}: ${String(noEchoReaders.length)} unchanged resource(s) read a NoEcho parameter, whose value state holds only as ***: the deploy compares it with AWS, and updates a resource whose value changed.`);
|
|
6186
|
-
const
|
|
6187
|
-
|
|
6188
|
-
|
|
6189
|
-
});
|
|
6190
|
-
if (nestedStackTypeChanges.length > 0) blocking = [...blocking, ...nestedStackTypeChanges.map(nestedStackTypeChangeReason)];
|
|
6191
|
-
const serviceTokens = findServiceTokenRefusals({
|
|
6192
|
-
changes,
|
|
6193
|
-
stateResources: stateForDiff.resources
|
|
6194
|
-
});
|
|
6195
|
-
if (serviceTokens.refused.length > 0) blocking = [...blocking, ...serviceTokens.refused.map((refusal) => serviceTokenBlockingReason(refusal, maskForLog))];
|
|
6196
|
-
for (const row of serviceTokens.deferred) logger.warn(printing.mask(deferredServiceTokenWarning(row)));
|
|
5797
|
+
const previewed = previewTypeAndServiceTokenRefusals(changes, stateForDiff.resources, maskForLog);
|
|
5798
|
+
blocking = [...blocking, ...previewed.blocking];
|
|
5799
|
+
for (const warning of previewed.warnings) logger.warn(printing.mask(warning));
|
|
6197
5800
|
blocking = [...blocking, ...findUpdatePolicyReplacementRefusals(changes, effectiveTemplate, stateForDiff.stackInstanceId !== void 0, options.createRouteOf === void 0 ? void 0 : (logicalId, change) => replacementCreateRoutesToCloudControl(options.createRouteOf, change, stateForDiff.resources[logicalId]?.properties))];
|
|
6198
5801
|
for (const reason of findUnwrittenCreateOnlyRefusals(changes, stateForDiff.resources, ccRouteUnavailableReason)) logger.warn(printing.mask(reason));
|
|
6199
5802
|
if (ccRouteUnavailableReason !== void 0) {
|
|
@@ -6254,15 +5857,21 @@ async function computeStackDiff(loadedState, template, region, stackName, stateB
|
|
|
6254
5857
|
diffOutputsAgainst,
|
|
6255
5858
|
stackName
|
|
6256
5859
|
});
|
|
6257
|
-
|
|
5860
|
+
const readsSecretFed = producerReadsSecretFedName(secretFedNames);
|
|
5861
|
+
const producer = {
|
|
6258
5862
|
stackName,
|
|
6259
5863
|
template: effectiveTemplate,
|
|
6260
|
-
changes,
|
|
6261
5864
|
desiredOutputs: resolved.outputs,
|
|
6262
5865
|
storedOutputs: currentState.outputs,
|
|
5866
|
+
...readsSecretFed && { readsSecretFedName: readsSecretFed }
|
|
5867
|
+
};
|
|
5868
|
+
if (crossStackPreview && recordCrossStackPreview) await recordProducerPreview(crossStackPreview, region, resolveFn, {
|
|
5869
|
+
...producer,
|
|
5870
|
+
changes,
|
|
6263
5871
|
...knownConditions !== void 0 && { conditions: knownConditions },
|
|
6264
5872
|
holdsSecret: (text) => printing.mask(text) !== text
|
|
6265
5873
|
});
|
|
5874
|
+
else if (crossStackPreview && readsSecretFed) await markProducerTaint(crossStackPreview, resolveFn, producer);
|
|
6266
5875
|
const printingSecrets = printing.corpus();
|
|
6267
5876
|
let shownChanges = changes;
|
|
6268
5877
|
let shownOutputChanges = outputChanges;
|
|
@@ -6411,7 +6020,7 @@ function childRowRunsEngine(row) {
|
|
|
6411
6020
|
return row?.changeType === "UPDATE" && (row.propertyChanges?.length ?? 0) > 0;
|
|
6412
6021
|
}
|
|
6413
6022
|
async function buildDiffTree(args) {
|
|
6414
|
-
const { stackName, displayName, region, template: synthTemplate, nestedTemplates, recursive, stateBackend, diffCalculator, parentHasSecretReference, parameters, parentUnresolvedParameters, canonicalizeProperties, ccRouteUnavailableReason, assetRedirect, cfnFallback, updatePolicy, createRouteOf, producerLookup, crossStackPreview, consumerAccount, previewOrphanAdoption, attributeHealerFor, liveDbInstanceZoneReaderFor, ancestorTemplatePaths, isNestedChild, ssmNameHeal, inheritedSecrets, inheritedDerivedNames, inheritedNoEchoParameters, inheritedNoEchoParametersAnyVerdict, refusalRecovery, inheritedReferenceProvenance, inheritedSecretTokens, stackTags } = args;
|
|
6023
|
+
const { stackName, displayName, region, template: synthTemplate, nestedTemplates, recursive, stateBackend, diffCalculator, parentHasSecretReference, parameters, parentUnresolvedParameters, canonicalizeProperties, ccRouteUnavailableReason, assetRedirect, cfnFallback, updatePolicy, replaceResources, createRouteOf, producerLookup, crossStackPreview, consumerAccount, previewOrphanAdoption, attributeHealerFor, liveDbInstanceZoneReaderFor, ancestorTemplatePaths, isNestedChild, ssmNameHeal, inheritedSecrets, inheritedDerivedNames, inheritedNoEchoParameters, inheritedNoEchoParametersAnyVerdict, refusalRecovery, inheritedReferenceProvenance, inheritedSecretTokens, stackTags, inheritedMixedSecretParameters, inheritedMixedSecretTagKeys } = args;
|
|
6415
6024
|
const unboundHealer = attributeHealerFor?.(stackName, region);
|
|
6416
6025
|
const stackTagged = applyStackTagsToTemplate(synthTemplate, stackTags, (line) => logger.warn(line));
|
|
6417
6026
|
const { state, unreadable, unreadableContainers, deployRefusals, found } = await loadStateOrEmpty(stackName, region, stateBackend, refusalRecovery);
|
|
@@ -6429,21 +6038,30 @@ async function buildDiffTree(args) {
|
|
|
6429
6038
|
});
|
|
6430
6039
|
for (const row of nestedSsmCheck?.forcedRows ?? []) logger.info(nestedSsmNameRowNote(row));
|
|
6431
6040
|
for (const row of nestedSsmCheck?.deferredRows ?? []) logger.info(nestedSsmNameDeferredNote(row));
|
|
6041
|
+
const ownSecretNames = taintedNamesOf(template, inheritedMixedSecretParameters);
|
|
6042
|
+
const passedSecretNames = crossStackPreview?.anyTainted() ? subtreeTaintedNames(template, nestedTemplates, inheritedMixedSecretParameters ?? [], crossStackPreview, ancestorTemplatePaths ? { ancestors: ancestorTemplatePaths } : {}) : ownSecretNames;
|
|
6043
|
+
const readsTaintedCrossStack = passedSecretNames.size > ownSecretNames.size;
|
|
6044
|
+
const passedSecretRecordNeedles = recordedValuesOf(state.resources ?? {}, passedSecretNames);
|
|
6045
|
+
for (const value of readsTaintedCrossStack ? crossStackPreview?.taintedValues() ?? [] : []) recordLogOnlyValue(passedSecretRecordNeedles, value);
|
|
6046
|
+
const underPassedSecretNeedles = (run) => hasMaskableValues(passedSecretRecordNeedles) ? withPrintingSecrets(passedSecretRecordNeedles, run) : run();
|
|
6047
|
+
const runComputeStackDiff = underPassedSecretNeedles;
|
|
6432
6048
|
let stackDiff;
|
|
6433
6049
|
try {
|
|
6434
|
-
stackDiff = await computeStackDiff(state, template, region, stackName, stateBackend, diffCalculator, {
|
|
6050
|
+
stackDiff = await runComputeStackDiff(() => computeStackDiff(state, template, region, stackName, stateBackend, calculatorMaskingPassedSecretLines(diffCalculator, template, passedSecretNames), {
|
|
6435
6051
|
...parameters && { parameters },
|
|
6436
6052
|
...parentUnresolvedParameters && { parentUnresolvedParameters },
|
|
6437
6053
|
...canonicalizeProperties && { canonicalizeProperties },
|
|
6438
6054
|
...ccRouteUnavailableReason && { ccRouteUnavailableReason },
|
|
6439
6055
|
...cfnFallback !== void 0 && { cfnFallback },
|
|
6440
6056
|
...updatePolicy === true && { updatePolicy },
|
|
6057
|
+
...replaceResources !== void 0 && !isNestedChild && { replaceResources },
|
|
6441
6058
|
...createRouteOf && { createRouteOf },
|
|
6442
6059
|
...producerLookup && { producerLookup },
|
|
6443
6060
|
...consumerAccount && { consumerAccount },
|
|
6444
6061
|
...crossStackPreview && {
|
|
6445
6062
|
crossStackPreview,
|
|
6446
|
-
recordCrossStackPreview: !isNestedChild
|
|
6063
|
+
recordCrossStackPreview: !isNestedChild,
|
|
6064
|
+
secretFedNames: passedSecretNames
|
|
6447
6065
|
},
|
|
6448
6066
|
...previewOrphanAdoption && { previewOrphanAdoption },
|
|
6449
6067
|
...inheritedSecrets && { inheritedSecrets },
|
|
@@ -6461,7 +6079,7 @@ async function buildDiffTree(args) {
|
|
|
6461
6079
|
...nestedSsmCheck && { forcedNestedChildRuns: nestedSsmCheck.forcedRows },
|
|
6462
6080
|
...stackTags && { stackTags },
|
|
6463
6081
|
nestedTemplates
|
|
6464
|
-
});
|
|
6082
|
+
}));
|
|
6465
6083
|
} finally {
|
|
6466
6084
|
createOnlyPrefetch.cancel();
|
|
6467
6085
|
}
|
|
@@ -6473,20 +6091,21 @@ async function buildDiffTree(args) {
|
|
|
6473
6091
|
...adoptedRecords
|
|
6474
6092
|
}
|
|
6475
6093
|
} : state;
|
|
6094
|
+
const ccApiRoutes = collectCcApiRoutes(effectiveTemplate, stateAfterAdoption, changes, ccRouteUnavailableReason ?? (() => void 0));
|
|
6476
6095
|
const node = {
|
|
6477
6096
|
stackName,
|
|
6478
6097
|
displayName,
|
|
6479
6098
|
region,
|
|
6480
|
-
changes,
|
|
6481
|
-
securityDiff,
|
|
6482
|
-
ccApiRoutes
|
|
6483
|
-
outputChanges,
|
|
6099
|
+
changes: maskPassedSecretChanges(changes, template, passedSecretNames, inheritedMixedSecretTagKeys),
|
|
6100
|
+
securityDiff: securityDiffWithPassedSecretWithheld(securityDiff, changes, template, passedSecretNames),
|
|
6101
|
+
ccApiRoutes,
|
|
6102
|
+
outputChanges: maskPassedSecretOutputs(outputChanges, template, passedSecretNames),
|
|
6484
6103
|
adoptedOrphans,
|
|
6485
|
-
blocking: isNestedChild ? blocking : [
|
|
6104
|
+
blocking: maskPassedSecretReasons(isNestedChild ? blocking : [
|
|
6486
6105
|
...deployRefusals,
|
|
6487
6106
|
...adoptedDeployRefusals,
|
|
6488
6107
|
...blocking
|
|
6489
|
-
],
|
|
6108
|
+
], template, passedSecretNames, state.orphans),
|
|
6490
6109
|
unreadable,
|
|
6491
6110
|
unreadableContainers,
|
|
6492
6111
|
unreadableOrphans,
|
|
@@ -6500,7 +6119,7 @@ async function buildDiffTree(args) {
|
|
|
6500
6119
|
if (resource?.Type !== "AWS::CloudFormation::Stack") continue;
|
|
6501
6120
|
templateChildIds.add(logicalId);
|
|
6502
6121
|
const childTemplatePath = nestedTemplates[logicalId];
|
|
6503
|
-
if (!childTemplatePath) throw new Error(`Nested template file not found for ${NESTED_STACK_RESOURCE_TYPE} ${displayIdent(logicalId)} under stack ${displayStackName(stackName)}. Verify the synth output emits Metadata['aws:asset:path'] on this resource (CDK 2.x cdk.NestedStack does so by default), then re-run synth.`);
|
|
6122
|
+
if (!childTemplatePath) throw new Error(`Nested template file not found for ${NESTED_STACK_RESOURCE_TYPE$1} ${displayIdent(logicalId)} under stack ${displayStackName(stackName)}. Verify the synth output emits Metadata['aws:asset:path'] on this resource (CDK 2.x cdk.NestedStack does so by default), then re-run synth.`);
|
|
6504
6123
|
const childStackName = `${stackName}~${logicalId}`;
|
|
6505
6124
|
const resolvedChildPath = path.resolve(childTemplatePath);
|
|
6506
6125
|
const childIdentity = templateIdentity(childTemplatePath);
|
|
@@ -6518,14 +6137,22 @@ async function buildDiffTree(args) {
|
|
|
6518
6137
|
]), void 0, stateAfterAdoption.resources);
|
|
6519
6138
|
const rowDerivedNames = /* @__PURE__ */ new Map();
|
|
6520
6139
|
const childSecretTokens = /* @__PURE__ */ new Map();
|
|
6521
|
-
const childParameters = await resolveChildStackParameters(resource, effectiveTemplate, stateAfterAdoption, region, stackName, stateBackend, resolvedParameters, conditions, cfnFallback, printingSecrets, attributeHealer && healerUnderRecordPrintingBag(attributeHealer, () => stateAfterAdoption.resources ?? {}, namingSecretsFor), childUnresolvedParameters, trust, rowDerivedNames, producerLookup, consumerAccount, {
|
|
6140
|
+
const childParameters = await underPassedSecretNeedles(() => resolveChildStackParameters(resource, effectiveTemplate, stateAfterAdoption, region, stackName, stateBackend, resolvedParameters, conditions, cfnFallback, printingSecrets, attributeHealer && healerUnderRecordPrintingBag(attributeHealer, () => stateAfterAdoption.resources ?? {}, namingSecretsFor), childUnresolvedParameters, trust, rowDerivedNames, producerLookup, consumerAccount, {
|
|
6522
6141
|
inherited: inheritedSecretTokens,
|
|
6523
6142
|
child: childSecretTokens
|
|
6524
|
-
});
|
|
6143
|
+
}, crossStackPreview));
|
|
6144
|
+
const childMixedSecretParameters = mixedSecretRowKeys(resource.Properties, childParameters, passedSecretNames);
|
|
6145
|
+
const childMixedSecretTagKeys = mixedSecretTagKeys(resource.Properties, stackDiff.childStackTags?.get(logicalId), passedSecretNames, inheritedMixedSecretTagKeys);
|
|
6146
|
+
const passedSecretNeedles = /* @__PURE__ */ new Map();
|
|
6147
|
+
for (const key of childMixedSecretParameters) {
|
|
6148
|
+
const value = Object.hasOwn(childParameters, key) ? childParameters[key] : void 0;
|
|
6149
|
+
if (typeof value === "string" && value.length > 0) recordLogOnlyValue(passedSecretNeedles, value);
|
|
6150
|
+
}
|
|
6525
6151
|
const childDerivedNames = diffPrintingSecrets([
|
|
6526
6152
|
inheritedDerivedNames,
|
|
6527
6153
|
rowDerivedNames,
|
|
6528
|
-
nodeStateNames
|
|
6154
|
+
nodeStateNames,
|
|
6155
|
+
passedSecretNeedles
|
|
6529
6156
|
]);
|
|
6530
6157
|
const childReferenceProvenance = inheritedProvenanceForChildDiff({
|
|
6531
6158
|
row: resource,
|
|
@@ -6568,7 +6195,9 @@ async function buildDiffTree(args) {
|
|
|
6568
6195
|
...refusalRecovery && { refusalRecovery },
|
|
6569
6196
|
...childReferenceProvenance && { inheritedReferenceProvenance: childReferenceProvenance },
|
|
6570
6197
|
...childSecretTokens.size > 0 && { inheritedSecretTokens: childSecretTokens },
|
|
6571
|
-
stackTags: stackDiff.childStackTags?.get(logicalId) ?? childStackTags(stackTags, {})
|
|
6198
|
+
stackTags: stackDiff.childStackTags?.get(logicalId) ?? childStackTags(stackTags, {}),
|
|
6199
|
+
...childMixedSecretParameters.size > 0 && { inheritedMixedSecretParameters: childMixedSecretParameters },
|
|
6200
|
+
...childMixedSecretTagKeys.size > 0 && { inheritedMixedSecretTagKeys: childMixedSecretTagKeys }
|
|
6572
6201
|
});
|
|
6573
6202
|
node.children.push(await (hasMaskableValues(childDerivedNames) ? withPrintingSecrets(childDerivedNames, buildChild) : buildChild()));
|
|
6574
6203
|
}
|
|
@@ -6998,7 +6627,19 @@ async function diffCommand(stacks, options) {
|
|
|
6998
6627
|
else throw new Error(`Multiple stacks found: ${allStacks.map(describeStack).join(", ")}. Specify stack name(s) or use --all (top-level stacks; '**' for every stack)`);
|
|
6999
6628
|
if (targetStacks.length === 0) throw new Error(renderNoStackMatch(stackPatterns, allStacks));
|
|
7000
6629
|
refuseFailedLookups(targetStacks, allStacks, result.failedLookups);
|
|
6630
|
+
const replaceTargetIds = [...new Set(options.replaceResource ?? [])];
|
|
6631
|
+
const deployStacks = replaceTargetIds.length > 0 ? withDependencyStacks(targetStacks, allStacks) : targetStacks;
|
|
7001
6632
|
await synthesizer.expandMacrosForStacks(targetStacks, synthOptions);
|
|
6633
|
+
if (replaceTargetIds.length > 0) {
|
|
6634
|
+
const dependencies = deployStacks.filter((stack) => !targetStacks.includes(stack));
|
|
6635
|
+
if (dependencies.length > 0) await synthesizer.expandMacrosForStacks(dependencies, synthOptions);
|
|
6636
|
+
checkReplaceResourceOptions(options, deployStacks);
|
|
6637
|
+
for (const id of replaceTargetIds) {
|
|
6638
|
+
if (targetStacks.some((stack) => Object.hasOwn(stack.template.Resources ?? {}, id))) continue;
|
|
6639
|
+
const owner = deployStacks.find((stack) => Object.hasOwn(stack.template.Resources ?? {}, id));
|
|
6640
|
+
if (owner !== void 0) logger.warn(safeMsg`--replace-resource ${id}: declared by ${owner.stackName}, a dependency stack the deploy includes unless -e is passed; diff that stack to preview its replacement.`);
|
|
6641
|
+
}
|
|
6642
|
+
}
|
|
7002
6643
|
const stateConfig = {
|
|
7003
6644
|
bucket: stateBucket,
|
|
7004
6645
|
prefix: options.statePrefix
|
|
@@ -7096,6 +6737,7 @@ async function diffCommand(stacks, options) {
|
|
|
7096
6737
|
const treeEnvs = [];
|
|
7097
6738
|
const producerLookup = producerLookupOver(allStacks);
|
|
7098
6739
|
const crossStackPreview = new CrossStackPreview();
|
|
6740
|
+
markAppProducerTaint(crossStackPreview, allStacks);
|
|
7099
6741
|
const inferredProducers = inferCrossStackDepsByStack(targetStacks);
|
|
7100
6742
|
targetStacks = orderProducersFirst(targetStacks, (stack) => [...stack.dependencyNames.flatMap((name) => stacksForDependency(name, stack, targetStacks)), ...inferredProducers.get(stack) ?? []]);
|
|
7101
6743
|
const sharedNames = new Set(targetStacks.map((s) => s.stackName).filter((name, i, names) => names.indexOf(name) !== i));
|
|
@@ -7114,6 +6756,7 @@ async function diffCommand(stacks, options) {
|
|
|
7114
6756
|
logger.debug(`Rewrote ${rewritten} asset reference(s) to cdkd asset storage in template of stack ${stackInfo.stackName}`);
|
|
7115
6757
|
}
|
|
7116
6758
|
const stackTags = stackTagsOverride ?? stackInfo.tags;
|
|
6759
|
+
const replaceResources = replaceResourcesForStack(options.replaceResource, stackInfo.stackName, stackInfo.template);
|
|
7117
6760
|
trees.push(await buildDiffTree({
|
|
7118
6761
|
stackName: stackInfo.stackName,
|
|
7119
6762
|
displayName: shownName,
|
|
@@ -7130,6 +6773,7 @@ async function diffCommand(stacks, options) {
|
|
|
7130
6773
|
...assetRedirect && { assetRedirect },
|
|
7131
6774
|
...options.cfnFallback === false && { cfnFallback: false },
|
|
7132
6775
|
...resolveUpdatePolicy(options.updatePolicy) === true && { updatePolicy: true },
|
|
6776
|
+
...replaceResources && { replaceResources: replaceResources.logicalIds },
|
|
7133
6777
|
producerLookup,
|
|
7134
6778
|
crossStackPreview,
|
|
7135
6779
|
...stackInfo.account && { consumerAccount: stackInfo.account },
|
|
@@ -7217,7 +6861,7 @@ async function diffCommand(stacks, options) {
|
|
|
7217
6861
|
}
|
|
7218
6862
|
}
|
|
7219
6863
|
function createDiffCommand() {
|
|
7220
|
-
const cmd = new Command("diff").description("Show difference between current state and desired state").argument("[stacks...]", "Stack name(s) to diff. Accepts CDK display paths (e.g. 'MyStage/Api') with wildcards ('MyStage/*', '**'), or exact physical CloudFormation names (e.g. 'MyStage-Api').").option("--all", "Diff every top-level stack (top-level only; Stage stacks: '**')", false).option("--recursive", "Recurse into each AWS::CloudFormation::Stack row and diff every nested-stack child against its own deployed state (DFS order). Default is non-recursive, matching cdk diff.", false).option("--fail", "Exit with code 1 when any change is detected (matches cdk diff --fail). Alias for --fail-on=any-change.").option("--no-fail", "Never exit with code 1 for a change. Alias for --fail-on=never.").addOption(new Option("--fail-on <kind>", "Exit with code 1 when the diff contains the given kind of change: \"any-change\" fails on any difference, \"broadening\" only on changes that broaden IAM permissions or security-group rules, \"destructive\" only on changes that replace, delete or orphan a resource, \"never\" does not fail (default). \"broadening\" and \"destructive\" always check nested stacks (as --recursive); \"any-change\" does with --recursive. Cannot be used with --fail / --no-fail.").choices(DIFF_FAIL_ON_VALUES).argParser(parseFailOn)).option("--security-only", "Only print the security changes (IAM and security-group) of each stack whose changes broaden permissions, and count only those stacks as differences for --fail-on (matches cdk diff --security-only). Checks nested stacks too. Cannot be used with --json.").option("--json", "Output the diff as JSON (nested tree shape when combined with --recursive)", false).addOption(useCdkBootstrapAssetsOption).addOption(noCfnFallbackOption).addOption(diffUpdatePolicyOptions[0]).addOption(diffUpdatePolicyOptions[1]).action(withErrorHandling(diffCommand));
|
|
6864
|
+
const cmd = new Command("diff").description("Show difference between current state and desired state").argument("[stacks...]", "Stack name(s) to diff. Accepts CDK display paths (e.g. 'MyStage/Api') with wildcards ('MyStage/*', '**'), or exact physical CloudFormation names (e.g. 'MyStage-Api').").option("--all", "Diff every top-level stack (top-level only; Stage stacks: '**')", false).option("--recursive", "Recurse into each AWS::CloudFormation::Stack row and diff every nested-stack child against its own deployed state (DFS order). Default is non-recursive, matching cdk diff.", false).option("--fail", "Exit with code 1 when any change is detected (matches cdk diff --fail). Alias for --fail-on=any-change.").option("--no-fail", "Never exit with code 1 for a change. Alias for --fail-on=never.").addOption(new Option("--fail-on <kind>", "Exit with code 1 when the diff contains the given kind of change: \"any-change\" fails on any difference, \"broadening\" only on changes that broaden IAM permissions or security-group rules, \"destructive\" only on changes that replace, delete or orphan a resource, \"never\" does not fail (default). \"broadening\" and \"destructive\" always check nested stacks (as --recursive); \"any-change\" does with --recursive. Cannot be used with --fail / --no-fail.").choices(DIFF_FAIL_ON_VALUES).argParser(parseFailOn)).option("--security-only", "Only print the security changes (IAM and security-group) of each stack whose changes broaden permissions, and count only those stacks as differences for --fail-on (matches cdk diff --security-only). Checks nested stacks too. Cannot be used with --json.").option("--json", "Output the diff as JSON (nested tree shape when combined with --recursive)", false).addOption(useCdkBootstrapAssetsOption).addOption(noCfnFallbackOption).addOption(diffUpdatePolicyOptions[0]).addOption(diffUpdatePolicyOptions[1]).addOption(diffReplaceResourceOption).action(withErrorHandling(diffCommand));
|
|
7221
6865
|
[
|
|
7222
6866
|
...commonOptions,
|
|
7223
6867
|
...appOptions,
|
|
@@ -15316,6 +14960,79 @@ function resolvablePrincipalLists(resource) {
|
|
|
15316
14960
|
return keys.map((key) => props[key]).filter((value) => isResolvableSecretPrincipalList(value));
|
|
15317
14961
|
}
|
|
15318
14962
|
|
|
14963
|
+
// src/cli/commands/destroy-runner/superseded-schedule.ts
|
|
14964
|
+
function scheduleSupersededDeletes(state, executionLevels, retryLate) {
|
|
14965
|
+
const rows = supersededResourcesOf(state).filter((row) => !isCustomResourceType$1(row.state.resourceType) || retryLate.has(row));
|
|
14966
|
+
if (rows.length === 0) return [];
|
|
14967
|
+
const { resources } = state;
|
|
14968
|
+
const last = executionLevels.length;
|
|
14969
|
+
const stepOf = /* @__PURE__ */ new Map();
|
|
14970
|
+
executionLevels.forEach((level, index) => {
|
|
14971
|
+
for (const logicalId of level) stepOf.set(logicalId, last - 1 - index);
|
|
14972
|
+
});
|
|
14973
|
+
const slot = /* @__PURE__ */ new Map();
|
|
14974
|
+
const lowerOf = /* @__PURE__ */ new Map();
|
|
14975
|
+
const atEnd = /* @__PURE__ */ new Set();
|
|
14976
|
+
for (const row of rows) {
|
|
14977
|
+
const rowType = row.state.resourceType;
|
|
14978
|
+
let upper = last;
|
|
14979
|
+
let lower = 0;
|
|
14980
|
+
const deps = row.state.dependencies;
|
|
14981
|
+
if (Array.isArray(deps)) for (const dep of deps) {
|
|
14982
|
+
if (typeof dep !== "string" || dep === row.logicalId) continue;
|
|
14983
|
+
const step = stepOf.get(dep);
|
|
14984
|
+
if (step !== void 0) upper = Math.min(upper, step);
|
|
14985
|
+
}
|
|
14986
|
+
const mustFollow = typesDeletedBefore(rowType);
|
|
14987
|
+
for (const [logicalId, step] of stepOf) {
|
|
14988
|
+
const record = resources[logicalId];
|
|
14989
|
+
if (typeof record !== "object" || record === null) continue;
|
|
14990
|
+
if (typesDeletedBefore(record.resourceType).includes(rowType)) upper = Math.min(upper, step);
|
|
14991
|
+
if (mustFollow.includes(record.resourceType)) lower = Math.max(lower, step + 1);
|
|
14992
|
+
const its = record.dependencies;
|
|
14993
|
+
if (Array.isArray(its) && its.includes(row.logicalId)) lower = Math.max(lower, step + 1);
|
|
14994
|
+
}
|
|
14995
|
+
const own = stepOf.get(row.logicalId);
|
|
14996
|
+
if (own !== void 0) lower = Math.max(lower, own);
|
|
14997
|
+
lowerOf.set(row, lower);
|
|
14998
|
+
slot.set(row, lower <= upper ? upper : last);
|
|
14999
|
+
if (lower > upper) atEnd.add(row);
|
|
15000
|
+
}
|
|
15001
|
+
let changed = true;
|
|
15002
|
+
const holdAtEnd = (row) => {
|
|
15003
|
+
if (atEnd.has(row)) return;
|
|
15004
|
+
atEnd.add(row);
|
|
15005
|
+
slot.set(row, last);
|
|
15006
|
+
changed = true;
|
|
15007
|
+
};
|
|
15008
|
+
while (changed) {
|
|
15009
|
+
changed = false;
|
|
15010
|
+
for (const row of rows) {
|
|
15011
|
+
const deps = row.state.dependencies;
|
|
15012
|
+
if (!Array.isArray(deps)) continue;
|
|
15013
|
+
for (const other of rows) {
|
|
15014
|
+
if (other.logicalId === row.logicalId || !deps.includes(other.logicalId)) continue;
|
|
15015
|
+
if (atEnd.has(row)) {
|
|
15016
|
+
holdAtEnd(other);
|
|
15017
|
+
continue;
|
|
15018
|
+
}
|
|
15019
|
+
const target = slot.get(other);
|
|
15020
|
+
if (target >= slot.get(row)) continue;
|
|
15021
|
+
if (target >= lowerOf.get(row)) {
|
|
15022
|
+
slot.set(row, target);
|
|
15023
|
+
changed = true;
|
|
15024
|
+
} else {
|
|
15025
|
+
holdAtEnd(row);
|
|
15026
|
+
holdAtEnd(other);
|
|
15027
|
+
}
|
|
15028
|
+
}
|
|
15029
|
+
}
|
|
15030
|
+
}
|
|
15031
|
+
const slots = Array.from({ length: last + 1 }, () => []);
|
|
15032
|
+
for (const row of supersededDependentsFirst(rows)) slots[slot.get(row)].push(row);
|
|
15033
|
+
return slots;
|
|
15034
|
+
}
|
|
15035
|
+
|
|
15319
15036
|
// src/cli/commands/destroy-runner/under-lock-steps.ts
|
|
15320
15037
|
async function recheckUnderLock({ ctx, stackName, state, regionForState, refusalRecovery, lock, restoreBaseRegionAndClients, needsStrongRefCheck }) {
|
|
15321
15038
|
try {
|
|
@@ -16030,7 +15747,7 @@ async function destroyStackUnderLock({ stackName, state, ctx, logger, result, re
|
|
|
16030
15747
|
const replacement = outcome.kind === "failed" ? outcome.replacement : void 0;
|
|
16031
15748
|
if (replacement !== void 0) remainingSuperseded = (remainingSuperseded ?? []).map((row) => row === entry ? replacement : row);
|
|
16032
15749
|
if (early) {
|
|
16033
|
-
logger.info(safeMsg` ${logicalId}'s superseded ${resourceType} (${shownId}) was not deleted yet; retrying
|
|
15750
|
+
logger.info(safeMsg` ${logicalId}'s superseded ${resourceType} (${shownId}) was not deleted yet; retrying it in dependency order`);
|
|
16034
15751
|
return true;
|
|
16035
15752
|
}
|
|
16036
15753
|
const why = outcome.kind === "notDeleted" ? outcome.reason : maskSecretsInText(describeAwsFailure(outcome.error).detail, bag);
|
|
@@ -16052,7 +15769,12 @@ async function destroyStackUnderLock({ stackName, state, ctx, logger, result, re
|
|
|
16052
15769
|
if (!isCustomResourceType$1(entry.state.resourceType)) continue;
|
|
16053
15770
|
if (await deleteSupersededRow(entry, true)) retryLate.add(entry);
|
|
16054
15771
|
}
|
|
15772
|
+
const slots = scheduleSupersededDeletes(state, executionLevels, retryLate);
|
|
15773
|
+
const deleteSupersededSlot = async (step) => {
|
|
15774
|
+
for (const entry of slots[step] ?? []) if (!lock.interrupted) await deleteSupersededRow(entry);
|
|
15775
|
+
};
|
|
16055
15776
|
for (let levelIndex = executionLevels.length - 1; levelIndex >= 0; levelIndex--) {
|
|
15777
|
+
await deleteSupersededSlot(executionLevels.length - 1 - levelIndex);
|
|
16056
15778
|
if (lock.interrupted) {
|
|
16057
15779
|
logger.debug("Interrupted (draining) — not scheduling further deletion levels");
|
|
16058
15780
|
break;
|
|
@@ -16064,11 +15786,7 @@ async function destroyStackUnderLock({ stackName, state, ctx, logger, result, re
|
|
|
16064
15786
|
const deletePromises = level.map((logicalId) => withPrintingSecrets(printingBagOf(logicalId), () => deleteStackResource(resourceFrame, logicalId, stackRegion)));
|
|
16065
15787
|
await Promise.all(deletePromises);
|
|
16066
15788
|
}
|
|
16067
|
-
|
|
16068
|
-
if (lock.interrupted) break;
|
|
16069
|
-
if (isCustomResourceType$1(entry.state.resourceType) && !retryLate.has(entry)) continue;
|
|
16070
|
-
await deleteSupersededRow(entry);
|
|
16071
|
-
}
|
|
15789
|
+
await deleteSupersededSlot(executionLevels.length);
|
|
16072
15790
|
const unreadableSuperseded = Array.isArray(state.supersededResources) ? state.supersededResources.filter((row) => !isSupersededResourceRecord(row)).length : holdsSupersededResources(state) ? 1 : 0;
|
|
16073
15791
|
if (unreadableSuperseded > 0) {
|
|
16074
15792
|
result.skippedCount += unreadableSuperseded;
|
|
@@ -18096,7 +17814,7 @@ async function walkCdkdStateStackTree(stackName, region, state, stateBackend, re
|
|
|
18096
17814
|
const childResult = await stateBackend.getState(childStackName, region);
|
|
18097
17815
|
if (!childResult) {
|
|
18098
17816
|
const orphan = orphanCommandFor(stackName, region, recovery);
|
|
18099
|
-
throw new Error(`cdkd state is missing nested-child ${quotedOrNotShown(childStackName)} (${quotedRegion(region)}). Parent stack ${quotedOrNotShown(stackName)} lists ${quotedOrNotShown(logicalId)} as an ${NESTED_STACK_RESOURCE_TYPE} row but no child state file exists at ${quotedOrNotShown(`cdkd/${childStackName}/${region}/state.json`)}. The cdkd state tree is inconsistent — re-deploy the parent stack to refresh, or drop the parent's record and re-import.${orphan.note}\nDrop it with: ${orphan.command}`);
|
|
17817
|
+
throw new Error(`cdkd state is missing nested-child ${quotedOrNotShown(childStackName)} (${quotedRegion(region)}). Parent stack ${quotedOrNotShown(stackName)} lists ${quotedOrNotShown(logicalId)} as an ${NESTED_STACK_RESOURCE_TYPE$1} row but no child state file exists at ${quotedOrNotShown(`cdkd/${childStackName}/${region}/state.json`)}. The cdkd state tree is inconsistent — re-deploy the parent stack to refresh, or drop the parent's record and re-import.${orphan.note}\nDrop it with: ${orphan.command}`);
|
|
18100
17818
|
}
|
|
18101
17819
|
if (childResult.divergentBodyRegion !== void 0) throw new Error(`cdkd state region mismatch: nested-child ${quotedOrNotShown(childStackName)} has state.region=${quotedOrNotShown(childResult.divergentBodyRegion)} but its parent ${quotedOrNotShown(stackName)} is being walked against region=${quotedOrNotShown(region)}. AWS does not support cross-region nested stacks; the state tree appears corrupt — re-deploy the parent stack to refresh.`);
|
|
18102
17820
|
nestedChildren.set(logicalId, await walkCdkdStateStackTree(childStackName, region, childResult.state, stateBackend, recovery));
|
|
@@ -20476,7 +20194,7 @@ async function runPerStackImportPhases(ctx) {
|
|
|
20476
20194
|
phase1BTemplate["Resources"][row.logicalId] = rewrittenRow;
|
|
20477
20195
|
rewrittenNestedRows.set(row.logicalId, rewrittenRow);
|
|
20478
20196
|
phase1BResources.push({
|
|
20479
|
-
ResourceType: NESTED_STACK_RESOURCE_TYPE,
|
|
20197
|
+
ResourceType: NESTED_STACK_RESOURCE_TYPE$1,
|
|
20480
20198
|
LogicalResourceId: row.logicalId,
|
|
20481
20199
|
ResourceIdentifier: { StackId: childArn }
|
|
20482
20200
|
});
|
|
@@ -37765,4 +37483,4 @@ function collectVerbFlags(program) {
|
|
|
37765
37483
|
}
|
|
37766
37484
|
|
|
37767
37485
|
export { effectiveInventoryItem as $, withRecordedCidrSpelling as A, LIFECYCLE_DEFAULT_STATUS as B, securityGroupReadbackDelays as C, stackIngressRuleHolder as D, singleSecurityGroupRuleId as E, clearLifecycleWritesOf as F, canonicalizeItemList as G, LIFECYCLE_RULE_PATH as H, lifecycleSettleTarget as I, lifecycleUsesFilterForm as J, effectiveLifecycleConfiguration as K, recordLifecycleWrite as L, sgRemovalRuleKey as M, sgRuleListMember as N, survivingRecordOfRuleId as O, LIFECYCLE_BASELINE_REREAD_DELAYS_MS as P, effectiveIntelligentTieringItem as Q, settleLifecycleRead as R, reconcileSgRules as S, sgRuleKey as T, LIFECYCLE_TAG_FILTERS_PATH as U, LIFECYCLE_FILTER_PATH as V, canonicalizeBlock as W, EVENTBRIDGE_CONFIG_PATH as X, parseCfnTimestamp as Y, effectiveAnalyticsItem as Z, ingressRuleIdentity as _, refuseRevertRevokingSiblingRules as a, declaresBucketObjectLock as at, isResendableSocketFailure as b, buildProgram, siblingIdOwnedSgRules as c, isPlainObject as ct, authorizeDefinitelyNotApplied as d, shownLifecycleRuleId as dt, effectiveNotificationConfiguration as et, canonicalizeSgInlineRuleProtocols as f, flattenIpPermissions as g, descriptionKey as h, resolveSecretDerivedPrincipals as i, configItemId as it, markCopiesAgreed as j, tagListsMatch as k, SG_READBACK_RETRY_DELAY_MS as l, manualBucketDeletionClause as lt, comparableIngressIdentity as m, holdsUnprovenSecretPrincipalToken as n, caughtErrorName as nt, sgRuleDiffKey as o, declaresNestedObjectLock as ot, canonicalizeSgRuleProtocol as p, lifecycleRuleScope as q, isResolvableSecretPrincipalList as r, coerceCfnNumber as rt, readSgIngressById as s, describeValue as st, runDestroyForStack as t, eventBridgeEnabledOf as tt, SG_RULE_PAGE_SIZE$1 as u, mergeLegacySingular as ut, isConnectTimeout as v, securityGroupRuleMatchesCfnIngress as w, narrowIngressIpProtocol as x, isDefaultEgressRule as y, takeLifecycleWrite as z };
|
|
37768
|
-
//# sourceMappingURL=program-
|
|
37486
|
+
//# sourceMappingURL=program-BPrn1MhZ.js.map
|