@cdkd/cli 0.334.1 → 0.334.2
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/{asg-provider-DFD40oJv.js → asg-provider-DTZ_iFWa.js} +2 -2
- package/dist/{asg-provider-DFD40oJv.js.map → asg-provider-DTZ_iFWa.js.map} +1 -1
- package/dist/cli.js +2 -2
- package/dist/{db-instance-modify-retry-Dpj04RL2.js → db-instance-modify-retry-zm23duXt.js} +3 -3
- package/dist/{db-instance-modify-retry-Dpj04RL2.js.map → db-instance-modify-retry-zm23duXt.js.map} +1 -1
- package/dist/{deploy-engine-BO_w6XzZ.js → deploy-engine-Dq_RyFZd.js} +6219 -5949
- package/dist/deploy-engine-Dq_RyFZd.js.map +1 -0
- package/dist/{iam-role-provider-Bfiu3VQU.js → iam-role-provider-DwAhjMfG.js} +2 -2
- package/dist/{iam-role-provider-Bfiu3VQU.js.map → iam-role-provider-DwAhjMfG.js.map} +1 -1
- package/dist/index.d.ts +48 -54
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/{neptune-provider-hIgTrVEI.js → neptune-provider-BFDPuF1_.js} +17 -9
- package/dist/{neptune-provider-hIgTrVEI.js.map → neptune-provider-BFDPuF1_.js.map} +1 -1
- package/dist/{program-Ctf5zWf1.js → program-Be87SvBg.js} +155 -123
- package/dist/program-Be87SvBg.js.map +1 -0
- package/dist/{provider-classes-IuPgHvuR.js → provider-classes-D0isRHVc.js} +21 -10
- package/dist/{provider-classes-IuPgHvuR.js.map → provider-classes-D0isRHVc.js.map} +1 -1
- package/dist/{rds-provider-mY4c2UdN.js → rds-provider-CYwGhhxE.js} +16 -5
- package/dist/rds-provider-CYwGhhxE.js.map +1 -0
- package/dist/{version-FHU_Fu1I.js → version-CagOv0Ke.js} +2 -2
- package/dist/{version-FHU_Fu1I.js.map → version-CagOv0Ke.js.map} +1 -1
- package/package.json +1 -1
- package/dist/deploy-engine-BO_w6XzZ.js.map +0 -1
- package/dist/program-Ctf5zWf1.js.map +0 -1
- package/dist/rds-provider-mY4c2UdN.js.map +0 -1
|
@@ -2,8 +2,8 @@ import { a as runWithStackAwsClients, i as resetAwsClients, l as s3ClientDefault
|
|
|
2
2
|
import { $ as safeMsg, B as SAFE_MSG_ALTERED_CHAR, C as PATTERN_B_RESOURCE_TYPES, F as isNameGeneration, G as cutMarker, H as STACK_REF_MAX_CODE_POINTS, J as displaySafe, K as displayAwsMessage, L as withSkipPrefix, Q as plainIdentOr, R as withStackScope, S as PATTERN_B_NAME_PROPERTIES, T as generateResourceName, U as UNRENDERABLE, V as SECRET_REF_MAX_CODE_POINTS, W as asIsMessage, X as isPasteableIdent, Y as displayStackName, _ as explicitNamePropertyFor, a as safeStringify, c as isStdoutReservedForPayload, d as runStackBuffered, et as stringifyJsonPayload, l as reserveStdoutForPayload, m as getLiveRenderer, n as describeAwsFailure, nt as truncateCodePoints, q as displayIdent, s as getLogger, tt as terminalSafe, w as derivesPatternBName, x as PATTERN_B_NAME_OPTIONS } from "./aws-failure-text-CoS1huLy.js";
|
|
3
3
|
import { $n as markNonRetryable, $t as formatLockExpiry, Ar as shellQuote, Bn as stripForDisplay, Dn as StackHasActiveImportsError, Dr as plainOrDescribed, En as ResourceUpdateNotSupportedError, Et as logicalIdShown, H as assertRegionMatch, Jn as isTransientServerError, M as VALUE_NOT_SHOWN, Mr as setPasteableRunFlags, Nr as setPasteableVerbFlags, On as StackTerminationProtectionError, Or as quotedOrDescribed, Ot as resourceTypeShown, Qn as isThrottlingError, Qt as forceQuitRecoveryClause, Rn as escapeRegExp, Sr as commandHole, Tn as PartialFailureError, Tr as pasteableCommand, U as isMarkedNotGone, V as RESOURCE_NOT_FOUND, Wn as isAmbiguousOutcomeError, Xt as buildForceUnlockCommand, Yn as retryClassificationText, Yt as UNREPRODUCIBLE_LOCK_CLAUSE, Zn as isMarkedNonRetryable, Zt as buildLockContentionMessage, _n as formatError, _t as beginCommandInterruptScope, an as DEFAULT_STATE_PREFIX, ar as MalformedProducerRecordRefusalError, bn as LocalStartServiceError, br as SHELL_ACTIVE_WHY, bt as isInterruptedWaitError, cn as producerCoordinateKey, cr as CdkdError, dn as withPasteableAwsProfile, dr as LocalInvokeBuildError$1, en as formatLockOperation, fn as ambientClientDefaults, gn as normalizeAwsError, gr as SynthesisError, hn as credentialFingerprint, hr as StateError, in as CUSTOM_RESOURCE_RESPONSE_PREFIX, ir as IntrinsicResolutionRefusalError, it as runDeleteAttempt, jr as withheldTargetClause, kr as shellBoundedDisplay, ln as producerRecordKey, lr as DeployCancelledError, m as RESOLVED_PREVIOUS_PRINCIPAL_KEYS, mn as clientDefaultsFor, mr as ResourceTimeoutError, nr as CrossAccountSecretRefusalError, on as injectiveKey, or as AccountIdUnavailableError, p as IAM_PRINCIPAL_NAME, pn as ambientCredentialConfig, pr as ProvisioningError, qn as isRetryableTransientError, rr as DynamicReferenceRegionAmbiguousError, tn as formatLockOwner, un as setPasteableAwsProfile, ut as isAwsCliLiteral, vr as TIMEOUT_FLAG_RESOURCE_TYPE, vt as endCommandInterruptScope, wn as NestedStackChildDirectDestroyError, wr as isInertUnquoted, y as readRecordedPrincipals, yn as withErrorHandling, yt as interruptWatchListenerCount, z as remedyLogicalId, zn as stripControlChars } from "./update-removal-C_x1-FM4.js";
|
|
4
4
|
import { a as setAssumedRoleCredentials, d as formatAuthority, i as getPreAssumeEnvCredentials, n as awsClientDefaults, r as getAssumedRoleCredentials, u as runInStackAwsScope } from "./aws-client-defaults-BLXFsfMa.js";
|
|
5
|
-
import { $a as classifyRecordedSecretRegion, $l as importableOutputKeys, $n as retiredAfterRollback, $r as isSupersededResourceRecord, $s as malformedOutputsWarning, $t as isHandledOrphan, $u as runDockerForeground, Ad as AssemblyReader, Ai as createPreDeleteFinalSnapshot, Al as recordPhysicalNameCopy, An as demoteSupersededOrphans, Ao as unsettledItemsField, Ar as movedToHint, As as refuseMalformedResourceEntriesForImport, At as makeCanonicalizePropertiesFn, Au as isCrossRegionRedirect, Ba as resolveDynamicReferences, Bc as maskAtCoordinates, Bd as ownValue, Bl as wholeStringLeavesOf, Bn as orphanNeedsIdentity, Bo as renderStatefulReason, Br as destroyStackRecordsView, Bs as refuseMalformedResourcePropertiesForOrphan, Bt as dropSettledNestedJournals, Bu as describeDockerExecFailure, Ca as deleteLeftInPlace, Cc as findHandledUnwrittenCreateOnly, Cd as CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION, Ci as ATOMIC_FINAL_SNAPSHOT_TYPES, Cl as spelledKeysOf, Cn as recordAfterRollbackUpdate, Co as carriesFetchableDynamicReference, Cr as DEFAULT_RESOURCE_WARN_AFTER_MS, Cs as malformedLocalResourcesWarning, Cu as createAssetRedirectResolver, Dc as NO_CC_HANDLERS_REASON, Dd as canonicalizeRegion, Di as isFinalSnapshotError, Dn as equalModuloMarkedMask, Do as withSharedDrainBudget, Dr as formatDestructiveChange, Ds as refuseMalformedResourceEntries, Dt as isSecretBearingReferenceString, Du as ensureAssetStorage, Ed as PARTITION_TABLE, Ei as effectiveDeletionPolicy, El as inheritNestedStackParameterAssociations, En as calculateResourceDrift, Eo as keepsSecretReferenceToken, Er as findDestructiveChanges, Es as refuseMalformedResourceAttributesForOrphan, Et as diffSecurity, Eu as AssetModeResolver, Fa as DiffCalculator, Fd as utf8ByteLength, Fi as withSecretPhysicalIdsMaskedInState, Fl as recordMaskOnlyValue, Fn as recheckFailedPlan, Fo as findReplacedReadersOfRecreateTargets, Fr as mappingPairs, Fs as malformedDriftResourcePropertiesWarning, Ft as keptForRetainedRecord, Fu as validateContainerRepoName, Ga as assertSendableRoleArn, Gc as noEchoLeavesOf, Gd as resolveAssemblyPath, Gl as S3StateBackend, Gr as cyan, Gs as malformedOrphansWarning, Gt as revertedNestedRowIds, Gu as dockerSpawnEnvWithSensitive, Ha as refuseUnreadableCdkCrossAccountRefs, Hc as maskWholeValue, Hd as describeFileReadFailure, Hi as DeploymentEventsStore, Hl as isSingleDynamicReferenceToken, Hr as withStackRecords, Hs as UNREADABLE_ORPHANS_CONTAINER_ROW, Ht as nestedChildStackName$1, Hu as redactedCause, Ia as IntrinsicFunctionResolver, Ic as DagBuilder, Id as defineOwnKey, Il as recordMaskOnlyValuesIn, In as recordUnderIdIsNotOwn, Io as shownType, Ir as parseMappingFile, Is as malformedResourcePropertiesWarning, It as recordRetainedForReadoption, Iu as BOOTSTRAP_MARKER_PREFIX, Ja as sendableAssumeRoleCommand, Jc as readbackPathFor, Jl as describeRegionValueKind, Jn as updatePartialMessage, Jr as red, Js as repairMalformedOrphansForReadOnly, Jt as getCurrentNestedStackContext, Ju as warnFinchArgvExposure, Ka as explicitRoleArnOrThrow, Kc as noEchoOutputsComparison, Kd as injectAwsRegion, Kl as splitImportedOps, Ko as coerceCfnBoolean, Kr as gray, Ks as refuseMalformedOrphans, Kt as withNestedRevertRun, Ku as finchSecretArgvRefusal, La as isAlwaysLiveAttribute, Lc as TemplateParser, Ld as hasOwnKey, Li as ledgerForStack, Ll as recordNoEchoAttributeValues, Ln as replacementNeverSwapped, Lo as MULTI_REGION_RECREATE_BLOCKED_TYPES, Lr as proposeRenames, Ls as refuseMalformedResourcePropertiesForDestroy, Lt as NESTED_PENDING_PARENT_REASON, Lu as buildDockerImage, Md as processStackMessages, Ml as splitGetAttStringForm, Mn as isReplacementOrphan, Mo as unsettledPropertiesOf, Mr as withMovedTo, Ms as refuseMalformedResourceEntriesForOrphan, Mt as planOrphanAdoption, Mu as parseBootstrapMarker, Nd as describeJsonParseFailure, Nl as carriesSecretMask, Nn as planFailedOps, No as withUnsettledProperties, Nr as isPairableType, Ns as repairMalformedResourceEntriesForReadOnly, Nt as pendingRequestCount, Nu as readBootstrapMarkerBody, Oc as hasNoCloudControlHandlers, Od as derivePartitionAndUrlSuffix, Oi as refusesFinalSnapshot, Ol as physicalNameCopiesOf, On as equalModuloMask, Oo as INTRINSIC_KEYS, Or as findRefactorHints, Os as refuseMalformedResourceEntriesForDeploy, Ot as keptWholeReasonText, Ou as buildDenyExternalAccessPolicy, Pa as isWaitAbandonedError, Pd as parseFailureDebugDetail, Pi as secretSegmentsOfState, Pl as provenPublicValue, Pn as planRollback, Po as withoutUnsettledProperties, Pr as looselyEqual, Ps as unreadableResourceEntries, Pt as resolvePendingCloudControlRequests, Pu as validateAssetBucketName, Qa as envCredentialsAreAssumedRole, Qc as liveMatchesUnresolvedTokenFrame, Ql as hasUnverifiableParameterRefusal, Qn as nameScopeOf, Qr as holdsSupersededResources, Qs as malformedOutputsRefusalMessage, Qt as dropFailedHint, Qu as getDockerCmd, Ra as poisonRenderedSpellingsCollidingIn, Rc as canonicalCoordinates, Rd as hasPlainPrototype, Rl as recordNoEchoParameterFreshValue, Rn as resolveReplacementOldType, Ro as isStatefulRecreateTargetForReplace, Rs as refuseMalformedResourcePropertiesForDrift, Rt as displacedOpClause, Ru as resolveDockerContextDirectory, Sa as deleteIndeterminateGuards, Sc as findActionableSdkUnwired, Sd as uploadCfnTemplate, Si as storedSecretNameNeedles, Sl as isUncertifiedBaselineMaskPosition, Sn as removeProtectionTypeList, So as isImpossibleEmptyStoredAttribute, Sr as DEFAULT_RESOURCE_TIMEOUT_MS, Ss as malformedLocalResourceEntriesWarning, St as readRecordedConditionVerdicts, Su as buildAssetRedirectMap, Tc as unwrittenCreateOnlyReplacement, Td as expectedOwnerParam, Ti as ccRoutedFinalSnapshotError, Tl as identityKeyFor, Tn as withUnprovenUnsettled, To as carriesDynamicReference, Tr as constructPathOf$1, Ts as malformedScrubResourceEntriesRefusalMessage, Tt as withResourceDeadline, Tu as rewriteTemplateAssetReferences, Ua as applyRoleArnIfSet, Uc as maskedLeafCoordinatesOf, Ud as displayAssemblyPath, Ui as extractDeploymentEventError, Ul as LockManager, Un as inheritProducerRegions, Us as hasReadableOrphans, Ut as recordDisplacedSkips, Uu as redactedDockerCause, Va as producerLookupOver, Vc as maskReadbackAtCoordinates, Vd as absoluteAssemblyPathEscape, Vi as DeploymentEventsReader, Vl as WHOLE_DYNAMIC_REFERENCE_PATTERN, Vn as findNestedStackTypeChanges, Vs as repairMalformedResourcePropertiesForReadOnly, Vu as describeDockerFailure, Wa as assertFlagRoleArn, Wc as noEchoCoordinatesOf, Wd as renderAssemblyPathEscape, Wl as isLockInfoExpired, Wr as bold, Ws as malformedOrphansRefusalMessage, Wu as redactDockerArgvValues, Xa as applyCallerIdentityCredentials, Xc as recordedNoEchoValuesOf, Xl as hasReadableExportSet, Xn as nameGenerationCarriedFrom, Xr as addSuperseded, Xs as malformedExportSourceWarning, Xt as deleteJournaledOrphans, Xu as isMalformedEnvKey, Ya as AWS_CREDENTIAL_ENV_KEYS, Yc as readsNoEchoSource, Yd as resolveBucketRegion, Yl as exportNamesCarriedFrom, Yn as updatePartialReason, Yr as yellow, Ys as malformedExportNamesWarning, Yt as withNestedStackContext, Yu as isDockerClientEnvKey, Za as callerEnvCredentials, Zc as valueAtCoordinate, Zl as hasReasonlessBaselineRefusal, Zn as nameGenerationHighWaterOf, Zr as deleteSupersededEntry, Zs as malformedLocalOutputsWarning, Zt as dropFailedCommands, Zu as formatDockerLoginError, _c as STATE_RESOURCES_MALFORMED, _d as ssmResolvedValueType, _i as secretNamePrintingBag, _l as scrubResourceRecord, _n as pendingMovesOutOf, _o as keepHeldTokenProvenance, _r as noEchoParameterValueSeed, _s as refuseMalformedOrphansForOrphan, _t as renderNestedTemplateTreeDefect, _u as withStackInstanceIdWithheld, a as isProtectionValueActive, aa as wouldReturnToSdkProvider, ac as refuseDivergentRecordRegionForDestroy, ad as getDefaultStateBucketName, ai as withoutSuperseded, al as hasMaskableValues, ar as reachableDivergentParameters, as as withRetry, au as stackInstanceIdCarriedFrom, ba as RollbackInlinePolicyWriters, bc as hasReadableOutputs, bd as MIGRATE_TMP_PREFIX, bi as secretNamedRecordNeedles, bl as DYNAMIC_REFERENCE_TOKEN_SCAN, bn as replayFailedOperations, bo as recordedReferenceRegions, br as isExportAliasCollision, bs as unreadableOrphanRecords, bt as conditionInputsFrom, bu as stringifyValue, ca as customResourceResponseExpirationWarning, cc as malformedStateRefusalMessage, cd as resolveApp, ci as noEchoExactEchoLeavesOf, cl as printingCorpusOf, co as coerceParameterTypedValue, cr as displayTextOrWithheld, cs as declaresNoEcho, ct as crossStackOutputProvenanceSource, cu as timePhase, da as isCustomResourceType$1, dc as refuseMalformedResourcesForExport, dd as resolveSkipPrefix, di as createReadOnlyAttributeHealerFactory, dl as shareLogOnlyValues, dn as refactorMarkerMovesOf, do as AWS_NO_VALUE, dr as secretBearingStateKeyWarning, ds as malformedOrphanRecordsRefusalMessage, dt as findServiceTokenRefusals, du as CrossPrefixScanCache, ed as runDockerStreaming, ei as removeSuperseded, el as redactForState, en as journaledOrphanLines, eo as classifyReplaySecretRegion, er as retiredNameGenerationsAfter, eu as importableOutputs, fc as refuseMalformedState, fd as resolveStateBucketWithDefault, fi as completedReplayEntries, fl as unionOfSecretBags, fn as refactorMarkerRefusalMessage, fo as cfnRefValueFromPhysicalId, fr as secretSafeKeyDisplay, fs as malformedOrphanRecordsWarning, ft as serviceTokenBlockingReason, fu as applyCrossPrefixScan, gc as withheldAccountClause, gd as warnDeprecatedNoPrefixCliFlag, gi as orphanRecordsPrintingBag, gl as maskSecretsInText, gn as hasPendingMovesOut, gr as isWholeDynamicReferenceValue, gs as refuseMalformedOrphanRecordsForDestroy, gt as listNestedTemplateRows, gu as stackInstanceIdOf, ha as CloudControlProvider, hc as accountArgs, hd as stateBucketExistenceConfirmed, hi as namingSecretsWithRecordedNoEcho, hl as maskSecretsInError, hn as updateRefactorMarker, ho as refStateLookupFromResource, hr as exportNameSecretExposure, hs as refuseMalformedOrphanRecords, ht as isAbsoluteAssetPath, hu as isNotImplemented, i as PROTECTION_PROPERTY_BY_TYPE, ia as isCustomResource, ic as STATE_REGION_DIVERGED, id as synthesisStatusMessage, ii as supersededResourcesOf, il as createUnionSecretMasker, in as formatResourceLine, ir as namesAnyDeclaredParameter, is as describeTypeWithThrottleRetry, iu as shouldRetainResource, jd as StageLoadError, ji as buildFinalSnapshotIdentifier, jl as recordNestedStackParameterExpressions, jn as isJournaledOrphan, jo as unsettledItemsOf, jr as rollbackOrphanIds, js as refuseMalformedResourceEntriesForImportSave, jt as makeSiblingClaimReader, ju as getBootstrapMarkerKey, kd as refuseFailedLookups, ki as unsupportedFinalSnapshotError, kn as undeclaredEmptyObservedKeys, kr as hintSidesOf, ks as refuseMalformedResourceEntriesForDestroy, kt as mergeNoChangeOutputs, ku as assertAssetBucketRegion, la as TemplateNoEchoReresolver, lc as refuseMalformedResourcesForDeploy, ld as resolveAutoAssetStorage, li as noEchoParameterNamesOf, ll as recordLogOnlyParameterValue, ln as readRefactorMarker, lo as isUnboundTemplateParameter, lr as exportAliasCollisionScrubWarning, ls as deployRefusesOrphanRowsReason, lt as inheritedProvenanceForChildDiff, lu as rebuildClientForBucketRegion, mc as JSON_LISTING_HOLE_VALUE, md as resolveUseCdkBootstrapAssets, mi as maskEventTextWithBoundBags, ml as errorCauseChain, mn as sameMove, mo as lacksRecordedTableArn, mr as exportNameNoEchoParameters, ms as previewableOrphanRecords, mt as findNestedTemplateTreeDefect, mu as isAccessDenied, n as recordedProtectionEvidence, na as ProviderRegistry, nc as refuseMalformedOutputsForDestroy, nd as getDockerImageBySourceHash, ni as supersededHeldByOtherTypeWarning, nn as sameJournaledOrphans, no as regionLessSecretName, nr as withNameGenerationReached, ns as prefetchCreateOnlyPropertyPaths, nu as orphansAfterRollback, o as perType, oa as CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID, oc as malformedRenderedContainersWarning, od as getLegacyStateBucketName, oi as noEchoAttributeNamesOf, ol as literalSplitDelimitersOf, or as resourcesNamingDeclaredParameter, os as parameterInputsFor, ot as IMPLICIT_DELETE_DEPENDENCIES, ou as PhaseClock, pa as withPrintingSecrets, pc as repairMalformedResourcesForReadOnly, pd as resolveStateBucketWithDefaultAndSource, pi as journaledOrphanPrintingBag, pl as createSecretMasker, pn as refuseRefactorMarker, po as isStalePlaceholderArnAttribute, pr as carriedExportAliasExposure, ps as malformedOrphanRowsKeptWarning, pt as childTemplateLoader, pu as crossPrefixDeniedWarning, qa as isIamRoleArn, qd as injectedAwsRegionValue, ql as acceptedCreateOnlyDropsOf, qr as green, qs as refuseMalformedOrphansForDestroy, qt as collectNestedChildUnaddressed, qu as partitionSensitiveEnv, r as recordedProtectionNote, ra as ccBrokenReason, rc as repairMalformedOutputsForReadOnly, rd as Synthesizer, ri as supersededHolderOf, rl as carryLogOnlyValues, rn as makeForeignHolderScan, rr as computeParameterTaint, rs as templateResourceTypes, ru as orphansCarriedFrom, s as readProtection, sa as applyCustomResourceResponseExpiration, sc as malformedResourcesWarning, sd as loadCdkJson, si as noEchoComparisonForTemplate, sl as logOnlyValueCount, sr as WITHHELD_NAME_DISPLAY, st as computeImplicitDeleteEdges, su as renderPhaseTimings, t as DeployEngine, ta as CC_BROKEN_REASON, tc as refuseMalformedOutputs, td as AssetManifestLoader, ti as supersededAfterRollback, tn as loadJournaledOrphans, to as producerRegionsFromState, tr as retiredNameGenerationsLeaving, tu as isReadableBag, ua as readsNoEchoDeleteValues, uc as refuseMalformedResourcesForDestroy, ud as resolveCaptureObservedState, ui as withAttemptedItemsMasked, ul as recordLogOnlyValue, un as readRefactorMarkerOnce, uo as parameterTypeMayLoseSecretIdentity, ur as secretBearing, us as isReadableOrphanRecord, ut as deferredServiceTokenWarning, uu as CrossPrefixReadError, va as setResolvedResourceTimeouts, vc as UNREADABLE_RESOURCES_MAP_ROW, vd as CFN_TEMPLATE_BODY_LIMIT, vi as secretNamePrintingBags, vl as withPhysicalNameCopies, vn as pendingMovesRefusalMessage, vr as collectDeclaredOutputNames, vs as repairMalformedOrphanRecordsForReadOnly, vt as templateIdentity, vu as AssetPublisher, wa as deleteSkipReason, wd as decodeListingKey, wi as PRE_DELETE_SNAPSHOT_TYPES, wl as pathCrossesDottedKey, wn as settleUnsettledPrevious, wo as isNamelessDynamicReferenceError, wr as maskingRetryLogger, ws as malformedResourceEntriesWarning, wu as loadPublishableAssetManifest, xa as UNSPECIFIED_SKIP_REASON, xc as hasReadableResources, xd as findLargeInlineResources, xi as stateSecretNameNeedles, xl as dynamicReferenceTokens, xn as replayRollback, xo as getAccountInfo, xr as bindingSkippedOutputs, xs as isReadableResourceEntry, xt as parentSuppliedValues, xu as WorkGraph, ya as slowCcOperationTimeoutMs, yc as displayLogicalId, yd as CFN_TEMPLATE_URL_LIMIT, yn as refusePendingMovesOut, yo as recordedOutputReferenceRegions, yr as collectPublishedOutputNames, ys as unpreviewableOrphanRecords, yt as conditionFingerprint, yu as isSensitiveAttributeName, zc as isMarkedCoordinate, zd as nullPrototypeRecord, zi as withCreateTokenLedger, zl as recordProvenPublicExpression, zn as seedsDeleteFirstGuard, zo as isStatefulRecreateTargetSync, zs as refuseMalformedResourcePropertiesForExport, zt as displacedPhysicalIdShown, zu as describeDockerCapturedOutput } from "./deploy-engine-BO_w6XzZ.js";
|
|
6
|
-
import { t as getCdkdVersion } from "./version-
|
|
5
|
+
import { $a as classifyRecordedSecretRegion, $l as importableOutputKeys, $n as demoteSupersededOrphans, $r as gray, $s as malformedOutputsWarning, $t as deleteJournaledOrphans, $u as runDockerForeground, Ad as AssemblyReader, Ai as extractDeploymentEventError, Al as recordPhysicalNameCopy, An as isPairableType, Ao as unsettledItemsField, Ar as secretBearing, As as refuseMalformedResourceEntriesForImport, At as recordRetainedForReadoption, Au as isCrossRegionRedirect, Ba as resolveDynamicReferences, Bc as maskAtCoordinates, Bd as ownValue, Bl as wholeStringLeavesOf, Bn as calculateResourceDrift, Bo as renderStatefulReason, Br as isExportAliasCollision, Bs as refuseMalformedResourcePropertiesForOrphan, Bt as sameMove, Bu as describeDockerExecFailure, Ca as deleteLeftInPlace, Cc as findHandledUnwrittenCreateOnly, Cd as CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION, Ci as orphanRecordsPrintingBag, Cl as spelledKeysOf, Cn as findDestructiveChanges, Co as carriesFetchableDynamicReference, Cr as computeParameterTaint, Cs as malformedLocalResourcesWarning, Ct as withResourceDeadline, Cu as createAssetRedirectResolver, Dc as NO_CC_HANDLERS_REASON, Dd as canonicalizeRegion, Di as secretNamedRecordNeedles, Dn as movedToHint, Do as withSharedDrainBudget, Dr as WITHHELD_NAME_DISPLAY, Ds as refuseMalformedResourceEntries, Dt as mergeNoChangeOutputs, Du as ensureAssetStorage, Ed as PARTITION_TABLE, El as inheritNestedStackParameterAssociations, En as hintSidesOf, Eo as keepsSecretReferenceToken, Er as resourcesNamingDeclaredParameter, Es as refuseMalformedResourceAttributesForOrphan, Et as keptWholeReasonText, Eu as AssetModeResolver, Fa as DiffCalculator, Fd as utf8ByteLength, Fi as isFinalSnapshotError, Fl as recordMaskOnlyValue, Fn as replayFailedOperations, Fo as findReplacedReadersOfRecreateTargets, Fr as exportNameSecretExposure, Fs as malformedDriftResourcePropertiesWarning, Ft as readRefactorMarker, Fu as validateContainerRepoName, Ga as assertSendableRoleArn, Gc as noEchoLeavesOf, Gd as resolveAssemblyPath, Gl as S3StateBackend, Gn as updatePartialReason, Gs as malformedOrphansWarning, Gt as refusePendingMovesOut, Gu as dockerSpawnEnvWithSensitive, Ha as refuseUnreadableCdkCrossAccountRefs, Hc as maskWholeValue, Hd as describeFileReadFailure, Hi as secretSegmentsOfState, Hl as isSingleDynamicReferenceToken, Hn as equalModuloMask, Hr as DEFAULT_RESOURCE_TIMEOUT_MS, Hs as UNREADABLE_ORPHANS_CONTAINER_ROW, Ht as hasPendingMovesOut, Hu as redactedCause, Ia as IntrinsicFunctionResolver, Ic as DagBuilder, Id as defineOwnKey, Ii as refusesFinalSnapshot, Il as recordMaskOnlyValuesIn, In as replayRollback, Io as shownType, Ir as isWholeDynamicReferenceValue, Is as malformedResourcePropertiesWarning, It as readRefactorMarkerOnce, Iu as BOOTSTRAP_MARKER_PREFIX, Ja as sendableAssumeRoleCommand, Jc as readbackPathFor, Jl as describeRegionValueKind, Js as repairMalformedOrphansForReadOnly, Jt as formatResourceLine, Ju as warnFinchArgvExposure, Ka as explicitRoleArnOrThrow, Kc as noEchoOutputsComparison, Kd as injectAwsRegion, Kl as splitImportedOps, Ko as coerceCfnBoolean, Ks as refuseMalformedOrphans, Ku as finchSecretArgvRefusal, La as isAlwaysLiveAttribute, Lc as TemplateParser, Ld as hasOwnKey, Li as unsupportedFinalSnapshotError, Ll as recordNoEchoAttributeValues, Ln as recordAfterRollbackUpdate, Lo as MULTI_REGION_RECREATE_BLOCKED_TYPES, Lr as noEchoParameterValueSeed, Ls as refuseMalformedResourcePropertiesForDestroy, Lt as refactorMarkerMovesOf, Lu as buildDockerImage, Md as processStackMessages, Mi as PRE_DELETE_SNAPSHOT_TYPES, Ml as splitGetAttStringForm, Mn as mappingPairs, Mo as unsettledPropertiesOf, Mr as secretSafeKeyDisplay, Ms as refuseMalformedResourceEntriesForOrphan, Mu as parseBootstrapMarker, Nd as describeJsonParseFailure, Ni as ccRoutedFinalSnapshotError, Nl as carriesSecretMask, Nn as parseMappingFile, No as withUnsettledProperties, Nr as carriedExportAliasExposure, Ns as repairMalformedResourceEntriesForReadOnly, Nu as readBootstrapMarkerBody, Oc as hasNoCloudControlHandlers, Od as derivePartitionAndUrlSuffix, Oi as stateSecretNameNeedles, Ol as physicalNameCopiesOf, On as rollbackOrphanIds, Oo as INTRINSIC_KEYS, Or as displayTextOrWithheld, Os as refuseMalformedResourceEntriesForDeploy, Ot as makeCanonicalizePropertiesFn, Ou as buildDenyExternalAccessPolicy, Pa as isWaitAbandonedError, Pd as parseFailureDebugDetail, Pi as effectiveDeletionPolicy, Pl as provenPublicValue, Pn as proposeRenames, Po as withoutUnsettledProperties, Pr as exportNameNoEchoParameters, Ps as unreadableResourceEntries, Pu as validateAssetBucketName, Qa as envCredentialsAreAssumedRole, Qc as liveMatchesUnresolvedTokenFrame, Ql as hasUnverifiableParameterRefusal, Qn as seedsDeleteFirstGuard, Qr as cyan, Qs as malformedOutputsRefusalMessage, Qt as resolvePendingCloudControlRequests, Qu as getDockerCmd, Ra as poisonRenderedSpellingsCollidingIn, Rc as canonicalCoordinates, Rd as hasPlainPrototype, Ri as createPreDeleteFinalSnapshot, Rl as recordNoEchoParameterFreshValue, Rn as settleUnsettledPrevious, Ro as isStatefulRecreateTargetForReplace, Rr as collectDeclaredOutputNames, Rs as refuseMalformedResourcePropertiesForDrift, Rt as refactorMarkerRefusalMessage, Ru as resolveDockerContextDirectory, Sa as deleteIndeterminateGuards, Sc as findActionableSdkUnwired, Sd as uploadCfnTemplate, Si as namingSecretsWithRecordedNoEcho, Sl as isUncertifiedBaselineMaskPosition, Sn as constructPathOf$1, So as isImpossibleEmptyStoredAttribute, Sr as inheritProducerRegions, Ss as malformedLocalResourceEntriesWarning, Su as buildAssetRedirectMap, Tc as unwrittenCreateOnlyReplacement, Td as expectedOwnerParam, Ti as secretNamePrintingBags, Tl as identityKeyFor, Tn as findRefactorHints, To as carriesDynamicReference, Tr as reachableDivergentParameters, Ts as malformedScrubResourceEntriesRefusalMessage, Tt as isSecretBearingReferenceString, Tu as rewriteTemplateAssetReferences, Ua as applyRoleArnIfSet, Uc as maskedLeafCoordinatesOf, Ud as displayAssemblyPath, Ui as withSecretPhysicalIdsMaskedInState, Ul as LockManager, Un as undeclaredEmptyObservedKeys, Ur as DEFAULT_RESOURCE_WARN_AFTER_MS, Us as hasReadableOrphans, Ut as pendingMovesOutOf, Uu as redactedDockerCause, Va as producerLookupOver, Vc as maskReadbackAtCoordinates, Vd as absoluteAssemblyPathEscape, Vl as WHOLE_DYNAMIC_REFERENCE_PATTERN, Vn as equalModuloMarkedMask, Vr as bindingSkippedOutputs, Vs as repairMalformedResourcePropertiesForReadOnly, Vt as updateRefactorMarker, Vu as describeDockerFailure, Wa as assertFlagRoleArn, Wc as noEchoCoordinatesOf, Wd as renderAssemblyPathEscape, Wl as isLockInfoExpired, Wn as updatePartialMessage, Wr as maskingRetryLogger, Ws as malformedOrphansRefusalMessage, Wt as pendingMovesRefusalMessage, Wu as redactDockerArgvValues, Xa as applyCallerIdentityCredentials, Xc as recordedNoEchoValuesOf, Xl as hasReadableExportSet, Xs as malformedExportSourceWarning, Xt as planOrphanAdoption, Xu as isMalformedEnvKey, Ya as AWS_CREDENTIAL_ENV_KEYS, Yc as readsNoEchoSource, Yd as resolveBucketRegion, Yl as exportNamesCarriedFrom, Yn as withCreateTokenLedger, Yr as withStackRecords, Ys as malformedExportNamesWarning, Yt as makeSiblingClaimReader, Yu as isDockerClientEnvKey, Za as callerEnvCredentials, Zc as valueAtCoordinate, Zl as hasReasonlessBaselineRefusal, Zn as planRollback, Zr as bold, Zs as malformedLocalOutputsWarning, Zt as pendingRequestCount, Zu as formatDockerLoginError, _c as STATE_RESOURCES_MALFORMED, _d as ssmResolvedValueType, _i as withAttemptedItemsMasked, _l as scrubResourceRecord, _n as collectNestedChildUnaddressed, _o as keepHeldTokenProvenance, _r as retiredAfterRollback, _s as refuseMalformedOrphansForOrphan, _t as conditionFingerprint, _u as withStackInstanceIdWithheld, a as isProtectionValueActive, aa as wouldReturnToSdkProvider, ac as refuseDivergentRecordRegionForDestroy, ad as getDefaultStateBucketName, ai as holdsSupersededResources, al as hasMaskableValues, an as sameJournaledOrphans, ar as replacementNeverSwapped, as as withRetry, at as computeImplicitDeleteEdges, au as stackInstanceIdCarriedFrom, ba as RollbackInlinePolicyWriters, bc as hasReadableOutputs, bd as MIGRATE_TMP_PREFIX, bi as journaledOrphanPrintingBag, bl as DYNAMIC_REFERENCE_TOKEN_SCAN, bn as DeploymentEventsReader, bo as recordedReferenceRegions, br as withNameGenerationReached, bs as unreadableOrphanRecords, bt as readRecordedConditionVerdicts, bu as stringifyValue, ca as customResourceResponseExpirationWarning, cc as malformedStateRefusalMessage, cd as resolveApp, ci as supersededAfterRollback, cl as printingCorpusOf, cn as displacedOpClause, co as coerceParameterTypedValue, cs as declaresNoEcho, ct as deferredServiceTokenWarning, cu as timePhase, da as isCustomResourceType$1, dc as refuseMalformedResourcesForExport, dd as resolveSkipPrefix, di as supersededResourcesOf, dl as shareLogOnlyValues, do as AWS_NO_VALUE, ds as malformedOrphanRecordsRefusalMessage, dt as childTemplateLoader, du as CrossPrefixScanCache, ed as runDockerStreaming, ei as green, el as redactForState, en as dropFailedCommands, eo as classifyReplaySecretRegion, er as isJournaledOrphan, eu as importableOutputs, fc as refuseMalformedState, fd as resolveStateBucketWithDefault, fi as withoutSuperseded, fl as unionOfSecretBags, fn as nestedChildStackName$1, fo as cfnRefValueFromPhysicalId, fr as removeProtectionTypeList, fs as malformedOrphanRecordsWarning, ft as findNestedTemplateTreeDefect, fu as applyCrossPrefixScan, gc as withheldAccountClause, gd as warnDeprecatedNoPrefixCliFlag, gi as noEchoParameterNamesOf, gl as maskSecretsInText, gn as withNestedRevertRun, gr as nameScopeOf, gs as refuseMalformedOrphanRecordsForDestroy, gt as templateIdentity, gu as stackInstanceIdOf, ha as CloudControlProvider, hc as accountArgs, hd as stateBucketExistenceConfirmed, hi as noEchoExactEchoLeavesOf, hl as maskSecretsInError, hn as revertedNestedRowIds, ho as refStateLookupFromResource, hr as nameGenerationHighWaterOf, hs as refuseMalformedOrphanRecords, ht as renderNestedTemplateTreeDefect, hu as isNotImplemented, i as PROTECTION_PROPERTY_BY_TYPE, ia as isCustomResource, ic as STATE_REGION_DIVERGED, id as synthesisStatusMessage, ii as deleteSupersededEntry, il as createUnionSecretMasker, in as loadJournaledOrphans, ir as recordUnderIdIsNotOwn, is as describeTypeWithThrottleRetry, it as IMPLICIT_DELETE_DEPENDENCIES, iu as shouldRetainResource, jd as StageLoadError, ji as ATOMIC_FINAL_SNAPSHOT_TYPES, jl as recordNestedStackParameterExpressions, jn as looselyEqual, jo as unsettledItemsOf, jr as secretBearingStateKeyWarning, js as refuseMalformedResourceEntriesForImportSave, ju as getBootstrapMarkerKey, kd as refuseFailedLookups, ki as storedSecretNameNeedles, kn as withMovedTo, kr as exportAliasCollisionScrubWarning, ks as refuseMalformedResourceEntriesForDestroy, kt as keptForRetainedRecord, ku as assertAssetBucketRegion, la as TemplateNoEchoReresolver, lc as refuseMalformedResourcesForDeploy, ld as resolveAutoAssetStorage, li as supersededHeldByOtherTypeWarning, ll as recordLogOnlyParameterValue, ln as displacedPhysicalIdShown, lo as isUnboundTemplateParameter, ls as deployRefusesOrphanRowsReason, lt as findServiceTokenRefusals, lu as rebuildClientForBucketRegion, mc as JSON_LISTING_HOLE_VALUE, md as resolveUseCdkBootstrapAssets, mi as noEchoComparisonForTemplate, ml as errorCauseChain, mo as lacksRecordedTableArn, mr as nameGenerationCarriedFrom, ms as previewableOrphanRecords, mt as listNestedTemplateRows, mu as isAccessDenied, n as recordedProtectionEvidence, na as ProviderRegistry, nc as refuseMalformedOutputsForDestroy, nd as getDockerImageBySourceHash, ni as yellow, nn as isHandledOrphan, no as regionLessSecretName, nr as planFailedOps, ns as prefetchCreateOnlyPropertyPaths, nu as orphansAfterRollback, o as perType, oa as CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID, oc as malformedRenderedContainersWarning, od as getLegacyStateBucketName, oi as isSupersededResourceRecord, ol as literalSplitDelimitersOf, on as makeForeignHolderScan, or as resolveReplacementOldType, os as parameterInputsFor, ot as crossStackOutputProvenanceSource, ou as PhaseClock, pa as withPrintingSecrets, pc as repairMalformedResourcesForReadOnly, pd as resolveStateBucketWithDefaultAndSource, pi as noEchoAttributeNamesOf, pl as createSecretMasker, pn as recordDisplacedSkips, po as isStalePlaceholderArnAttribute, pr as orphanNeedsIdentity, ps as malformedOrphanRowsKeptWarning, pt as isAbsoluteAssetPath, pu as crossPrefixDeniedWarning, qa as isIamRoleArn, qd as injectedAwsRegionValue, ql as acceptedCreateOnlyDropsOf, qn as ledgerForStack, qr as destroyStackRecordsView, qs as refuseMalformedOrphansForDestroy, qu as partitionSensitiveEnv, r as recordedProtectionNote, ra as ccBrokenReason, rc as repairMalformedOutputsForReadOnly, rd as Synthesizer, ri as addSuperseded, rl as carryLogOnlyValues, rn as journaledOrphanLines, rr as recheckFailedPlan, rs as templateResourceTypes, ru as orphansCarriedFrom, s as readProtection, sa as applyCustomResourceResponseExpiration, sc as malformedResourcesWarning, sd as loadCdkJson, si as removeSuperseded, sl as logOnlyValueCount, sn as NESTED_PENDING_PARENT_REASON, sr as findNestedStackTypeChanges, st as inheritedProvenanceForChildDiff, su as renderPhaseTimings, t as DeployEngine, ta as CC_BROKEN_REASON, tc as refuseMalformedOutputs, td as AssetManifestLoader, ti as red, tn as dropFailedHint, to as producerRegionsFromState, tr as isReplacementOrphan, tu as isReadableBag, ua as readsNoEchoDeleteValues, uc as refuseMalformedResourcesForDestroy, ud as resolveCaptureObservedState, ui as supersededHolderOf, ul as recordLogOnlyValue, un as dropSettledNestedJournals, uo as parameterTypeMayLoseSecretIdentity, us as isReadableOrphanRecord, ut as serviceTokenBlockingReason, uu as CrossPrefixReadError, va as setResolvedResourceTimeouts, vc as UNREADABLE_RESOURCES_MAP_ROW, vd as CFN_TEMPLATE_BODY_LIMIT, vi as createReadOnlyAttributeHealerFactory, vl as withPhysicalNameCopies, vn as getCurrentNestedStackContext, vr as retiredNameGenerationsAfter, vs as repairMalformedOrphanRecordsForReadOnly, vt as conditionInputsFrom, vu as AssetPublisher, wa as deleteSkipReason, wd as decodeListingKey, wi as secretNamePrintingBag, wl as pathCrossesDottedKey, wn as formatDestructiveChange, wo as isNamelessDynamicReferenceError, wr as namesAnyDeclaredParameter, ws as malformedResourceEntriesWarning, wt as diffSecurity, wu as loadPublishableAssetManifest, xa as UNSPECIFIED_SKIP_REASON, xc as hasReadableResources, xd as findLargeInlineResources, xi as maskEventTextWithBoundBags, xl as dynamicReferenceTokens, xn as DeploymentEventsStore, xo as getAccountInfo, xs as isReadableResourceEntry, xu as WorkGraph, ya as slowCcOperationTimeoutMs, yc as displayLogicalId, yd as CFN_TEMPLATE_URL_LIMIT, yi as completedReplayEntries, yn as withNestedStackContext, yo as recordedOutputReferenceRegions, yr as retiredNameGenerationsLeaving, ys as unpreviewableOrphanRecords, yt as parentSuppliedValues, yu as isSensitiveAttributeName, zc as isMarkedCoordinate, zd as nullPrototypeRecord, zi as buildFinalSnapshotIdentifier, zl as recordProvenPublicExpression, zn as withUnprovenUnsettled, zo as isStatefulRecreateTargetSync, zr as collectPublishedOutputNames, zs as refuseMalformedResourcePropertiesForExport, zt as refuseRefactorMarker, zu as describeDockerCapturedOutput } from "./deploy-engine-Dq_RyFZd.js";
|
|
6
|
+
import { t as getCdkdVersion } from "./version-CagOv0Ke.js";
|
|
7
7
|
import { t as cdkdCacheHome } from "./cli.js";
|
|
8
8
|
import { randomBytes, randomUUID } from "node:crypto";
|
|
9
9
|
import { CopyObjectCommand, CreateBucketCommand, DeleteBucketCommand, DeleteObjectsCommand, GetBucketLocationCommand, GetObjectCommand, HeadBucketCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, NotFound, PutBucketEncryptionCommand, PutBucketPolicyCommand, PutBucketVersioningCommand, PutObjectCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
|
|
@@ -1852,7 +1852,7 @@ function collectCrossStackRefs(node, onRef, unconditional) {
|
|
|
1852
1852
|
// src/provisioning/register-providers.ts
|
|
1853
1853
|
let providerClasses;
|
|
1854
1854
|
function loadProviderClasses() {
|
|
1855
|
-
providerClasses ??= import("./provider-classes-
|
|
1855
|
+
providerClasses ??= import("./provider-classes-D0isRHVc.js");
|
|
1856
1856
|
return providerClasses;
|
|
1857
1857
|
}
|
|
1858
1858
|
function registerAllProviders(registry, classes) {
|
|
@@ -13430,7 +13430,7 @@ function skippedDestroyMessage(totalSkipped, totalOrphanSkips, rerunCommand) {
|
|
|
13430
13430
|
return `Destroy skipped ${recordSkips} entr${recordSkips === 1 ? "y" : "ies"} whose delete cdkd did not confirm, so the underlying resources may still exist in AWS. A skipped nested stack counts as ONE entry and may cover several of its own resources — the per-stack summaries above give the exact breakdown. State preserved (the records are kept). The per-resource 'skipped (...)' lines and their warnings name each cause and whether repairing the record in state.json helps: where it does, repair it and re-run '${rerunCommand}'; otherwise (for example a custom-resource Delete handler that reported FAILED), delete the resources by hand and drop the records with 'cdkd state orphan <stack> --stack-region <region>'.` + (totalOrphanSkips > 0 ? ` Separately, ${orphanSentence}` : "");
|
|
13431
13431
|
}
|
|
13432
13432
|
|
|
13433
|
-
// src/cli/commands/destroy.ts
|
|
13433
|
+
// src/cli/commands/destroy/helpers.ts
|
|
13434
13434
|
function orderConsumersBeforeProducers(stackNames, consumerToProducers) {
|
|
13435
13435
|
const pendingConsumers = /* @__PURE__ */ new Map();
|
|
13436
13436
|
for (const name of stackNames) pendingConsumers.set(name, /* @__PURE__ */ new Set());
|
|
@@ -13467,6 +13467,147 @@ async function purgeEventsAfterDestroy(reader, stackName, region, opts, logger)
|
|
|
13467
13467
|
return null;
|
|
13468
13468
|
}
|
|
13469
13469
|
}
|
|
13470
|
+
|
|
13471
|
+
// src/cli/commands/destroy/select-targets.ts
|
|
13472
|
+
async function selectDestroyTargets(stackArgs, options, stateBackend, logger) {
|
|
13473
|
+
const appCmd = options.app || resolveApp();
|
|
13474
|
+
let appStacks = [];
|
|
13475
|
+
let synthScanStacks = [];
|
|
13476
|
+
let synthesized = false;
|
|
13477
|
+
let synthError;
|
|
13478
|
+
if (appCmd) try {
|
|
13479
|
+
const synthesizer = new Synthesizer();
|
|
13480
|
+
const context = parseContextOptions(options.context);
|
|
13481
|
+
const result = await synthesizer.synthesize({
|
|
13482
|
+
app: appCmd,
|
|
13483
|
+
output: options.output || "cdk.out",
|
|
13484
|
+
...Object.keys(context).length > 0 && { context },
|
|
13485
|
+
deferMacroExpansion: true,
|
|
13486
|
+
failedLookupsCheckedByCaller: true
|
|
13487
|
+
});
|
|
13488
|
+
appStacks = result.stacks.map((s) => ({
|
|
13489
|
+
stackName: s.stackName,
|
|
13490
|
+
displayName: s.displayName,
|
|
13491
|
+
...s.stagePath !== void 0 && { stagePath: s.stagePath },
|
|
13492
|
+
...s.region && { region: s.region },
|
|
13493
|
+
...s.account && { account: s.account },
|
|
13494
|
+
...s.terminationProtection !== void 0 && { terminationProtection: s.terminationProtection },
|
|
13495
|
+
template: s.template,
|
|
13496
|
+
...s.nestedTemplates !== void 0 && { nestedTemplates: s.nestedTemplates }
|
|
13497
|
+
}));
|
|
13498
|
+
synthScanStacks = result.stacks.map((s) => ({
|
|
13499
|
+
stackName: s.stackName,
|
|
13500
|
+
template: s.template
|
|
13501
|
+
}));
|
|
13502
|
+
synthesized = true;
|
|
13503
|
+
} catch (error) {
|
|
13504
|
+
if (error instanceof StageLoadError) {
|
|
13505
|
+
const named = new StageLoadError(`${error.message} To destroy a deployed stack without the app: cdkd state destroy ${commandHole("stack")}.`);
|
|
13506
|
+
if (typeof error.stack === "string") {
|
|
13507
|
+
const headerLines = `${error.name}: ${error.message}`.split("\n").length;
|
|
13508
|
+
const frames = error.stack.split("\n").slice(headerLines).join("\n");
|
|
13509
|
+
if (frames.length > 0) named.stack = `${named.name}: ${named.message}\n${frames}`;
|
|
13510
|
+
}
|
|
13511
|
+
throw named;
|
|
13512
|
+
}
|
|
13513
|
+
synthError = error instanceof Error ? error : new Error(safeStringify(error));
|
|
13514
|
+
logger.debug("Could not synthesize app, falling back to state-based stack list");
|
|
13515
|
+
}
|
|
13516
|
+
const stackPatterns = stackArgs.length > 0 ? stackArgs : options.stack ? [options.stack] : [];
|
|
13517
|
+
const wildcardPatterns = stackPatterns.filter((p) => p.includes("*") || p.includes("?"));
|
|
13518
|
+
if (appStacks.length === 0 && (options.all || wildcardPatterns.length > 0)) {
|
|
13519
|
+
const selector = options.all ? "--all" : wildcardPatterns.map((p) => displaySafe(p)).join(", ");
|
|
13520
|
+
if (synthesized) throw new Error(`${selector} selects among the stacks this app synthesizes, and it synthesized none; refusing to fall back to every stack in state.`);
|
|
13521
|
+
const hole = commandHole("stack");
|
|
13522
|
+
throw new CdkdError(`${selector} selects among the stacks this app synthesizes, and ` + (synthError ? "the app could not be synthesized" : "no app is configured") + "; refusing to fall back to every stack in state, which spans every app sharing this state bucket. " + (synthError ? "Fix the app so it synthesizes" : "Configure the app with --app or cdk.json") + `, or name each stack exactly: cdkd destroy ${hole}, or cdkd state destroy ${hole}, which needs no app.`, "DESTROY_NO_APP_SCOPE", synthError);
|
|
13523
|
+
}
|
|
13524
|
+
if (options.all && appStacks.length > 0) {
|
|
13525
|
+
const app = partitionTopLevel(appStacks);
|
|
13526
|
+
if (app.topLevel.length === 0) throw new Error(renderAllNoTopLevelStacks(app.inStages));
|
|
13527
|
+
}
|
|
13528
|
+
const allStateRefs = await stateBackend.listStacks();
|
|
13529
|
+
let candidateStacks;
|
|
13530
|
+
if (appStacks.length > 0) {
|
|
13531
|
+
const stateNames = new Set(allStateRefs.map((r) => r.stackName));
|
|
13532
|
+
candidateStacks = appStacks.filter((s) => stateNames.has(s.stackName));
|
|
13533
|
+
} else if (stackArgs.length > 0 || options.stack) {
|
|
13534
|
+
const seen = /* @__PURE__ */ new Set();
|
|
13535
|
+
candidateStacks = [];
|
|
13536
|
+
for (const ref of allStateRefs) {
|
|
13537
|
+
if (seen.has(ref.stackName)) continue;
|
|
13538
|
+
seen.add(ref.stackName);
|
|
13539
|
+
candidateStacks.push({ stackName: ref.stackName });
|
|
13540
|
+
}
|
|
13541
|
+
} else throw new CdkdError("Could not determine which stacks belong to this app. Specify stack names explicitly, or ensure --app / cdk.json is configured.", "DESTROY_NO_STACK_SELECTED", synthError);
|
|
13542
|
+
const appStackSet = new Set(appStacks);
|
|
13543
|
+
const toTarget = (s) => ({
|
|
13544
|
+
stackName: s.stackName,
|
|
13545
|
+
synth: appStackSet.has(s) ? s : void 0
|
|
13546
|
+
});
|
|
13547
|
+
let targets;
|
|
13548
|
+
const namesAppStack = /* @__PURE__ */ new Set();
|
|
13549
|
+
if (options.all) {
|
|
13550
|
+
const { topLevel, inStages } = partitionTopLevel(candidateStacks);
|
|
13551
|
+
if (inStages.length > 0) logger.warn(renderAllLeftOutStageStacks(inStages));
|
|
13552
|
+
targets = topLevel.map(toTarget);
|
|
13553
|
+
} else if (stackPatterns.length > 0) {
|
|
13554
|
+
const selectFrom = appStacks.length > 0 ? appStacks : candidateStacks;
|
|
13555
|
+
const inState = new Set(candidateStacks.map((s) => s.stackName));
|
|
13556
|
+
targets = matchStacks(selectFrom, stackPatterns, { dedupe: "identity" }).filter((s) => inState.has(s.stackName)).map(toTarget);
|
|
13557
|
+
if (appStacks.length > 0) {
|
|
13558
|
+
const gone = stacksNoLongerSelected(candidateStacks, stackPatterns, new Set(targets.map((t) => t.stackName)));
|
|
13559
|
+
if (gone.stacks.length > 0) logger.warn(renderStacksNoLongerSelected(gone.patterns, gone.stacks));
|
|
13560
|
+
}
|
|
13561
|
+
const stateNames = new Set(allStateRefs.map((r) => r.stackName));
|
|
13562
|
+
const unmatched = unmatchedPatterns(selectFrom, stackPatterns, (s) => inState.has(s.stackName));
|
|
13563
|
+
if (appStacks.length > 0) {
|
|
13564
|
+
for (const p of stackPatterns) if (appStacks.some((s) => stackMatchesPattern(s, p))) namesAppStack.add(p);
|
|
13565
|
+
}
|
|
13566
|
+
const inStateOnly = unmatched.filter((p) => stateNames.has(p) && !namesAppStack.has(p));
|
|
13567
|
+
const absent = unmatched.filter((p) => !inStateOnly.includes(p));
|
|
13568
|
+
if (absent.length > 0) logger.warn(renderUnmatchedPatternsWarning(absent, "in state"));
|
|
13569
|
+
if (targets.length > 0 && inStateOnly.length > 0) logger.warn(renderNotInAppWarning(inStateOnly));
|
|
13570
|
+
} else if (candidateStacks.length === 1) targets = candidateStacks.map(toTarget);
|
|
13571
|
+
else if (candidateStacks.length === 0) {
|
|
13572
|
+
logger.info("No stacks found in state");
|
|
13573
|
+
return;
|
|
13574
|
+
} else throw new Error(`Multiple stacks found: ${candidateStacks.map(describeStack).join(", ")}. Specify stack name(s) or use --all (top-level stacks; '**' for every stack)`);
|
|
13575
|
+
return {
|
|
13576
|
+
appStacks,
|
|
13577
|
+
synthScanStacks,
|
|
13578
|
+
stackPatterns,
|
|
13579
|
+
allStateRefs,
|
|
13580
|
+
targets,
|
|
13581
|
+
namesAppStack
|
|
13582
|
+
};
|
|
13583
|
+
}
|
|
13584
|
+
async function orderDestroyTargets(targets, appStacks, synthScanStacks, regionForStack, logger) {
|
|
13585
|
+
const uniqueNames = [...new Set(targets.map((t) => t.stackName))];
|
|
13586
|
+
if (synthScanStacks.length > 0 && uniqueNames.length > 1) {
|
|
13587
|
+
const inSet = new Set(uniqueNames);
|
|
13588
|
+
const inferred = inferCrossStackStackDeps(synthScanStacks.filter((s) => inSet.has(s.stackName)));
|
|
13589
|
+
targets = orderConsumersBeforeProducers(uniqueNames, inferred).flatMap((name) => targets.filter((t) => t.stackName === name));
|
|
13590
|
+
}
|
|
13591
|
+
const sharedAppNames = new Set(appStacks.map((s) => s.stackName).filter((name, i, names) => names.indexOf(name) !== i));
|
|
13592
|
+
const strictRegion = /* @__PURE__ */ new Map();
|
|
13593
|
+
for (const target of targets) {
|
|
13594
|
+
if (!sharedAppNames.has(target.stackName) || target.synth === void 0) continue;
|
|
13595
|
+
strictRegion.set(target, target.synth.region ?? await regionForStack(target.stackName));
|
|
13596
|
+
}
|
|
13597
|
+
const strictBySynth = new Map(targets.flatMap((t) => t.synth !== void 0 && strictRegion.has(t) ? [[t.synth, strictRegion.get(t)]] : []));
|
|
13598
|
+
const strictNames = new Set([...strictBySynth.keys()].map((s) => s.stackName));
|
|
13599
|
+
refuseStackNameRegionCollisions(appStacks.filter((s) => strictBySynth.has(s) || strictNames.has(s.stackName) && s.region !== void 0), (s) => strictBySynth.get(s) ?? s.region, new Set(strictBySynth.keys()));
|
|
13600
|
+
const describeTarget = (t) => t.synth !== void 0 && strictRegion.has(t) ? `${describeStack(t.synth)} in ${displaySafe(strictRegion.get(t))}` : displaySafe(t.stackName);
|
|
13601
|
+
logger.info(`Found ${targets.length} stack(s) to destroy: ${targets.map(describeTarget).join(", ")}`);
|
|
13602
|
+
return {
|
|
13603
|
+
targets,
|
|
13604
|
+
uniqueNames,
|
|
13605
|
+
strictRegion,
|
|
13606
|
+
describeTarget
|
|
13607
|
+
};
|
|
13608
|
+
}
|
|
13609
|
+
|
|
13610
|
+
// src/cli/commands/destroy/command.ts
|
|
13470
13611
|
async function destroyCommand(stackArgs, options) {
|
|
13471
13612
|
const providerClasses = await loadProviderClasses();
|
|
13472
13613
|
const logger = getLogger();
|
|
@@ -13553,114 +13694,16 @@ async function destroyCommand(stackArgs, options) {
|
|
|
13553
13694
|
registerAllProviders(providerRegistry, providerClasses);
|
|
13554
13695
|
providerRegistry.setCustomResourceResponseBucket(stateBucket);
|
|
13555
13696
|
if (options.allowUnsupportedTypes?.length) providerRegistry.allowUnsupportedTypes(options.allowUnsupportedTypes);
|
|
13556
|
-
const
|
|
13557
|
-
|
|
13558
|
-
|
|
13559
|
-
let
|
|
13560
|
-
let synthError;
|
|
13561
|
-
if (appCmd) try {
|
|
13562
|
-
const synthesizer = new Synthesizer();
|
|
13563
|
-
const context = parseContextOptions(options.context);
|
|
13564
|
-
const result = await synthesizer.synthesize({
|
|
13565
|
-
app: appCmd,
|
|
13566
|
-
output: options.output || "cdk.out",
|
|
13567
|
-
...Object.keys(context).length > 0 && { context },
|
|
13568
|
-
deferMacroExpansion: true,
|
|
13569
|
-
failedLookupsCheckedByCaller: true
|
|
13570
|
-
});
|
|
13571
|
-
appStacks = result.stacks.map((s) => ({
|
|
13572
|
-
stackName: s.stackName,
|
|
13573
|
-
displayName: s.displayName,
|
|
13574
|
-
...s.stagePath !== void 0 && { stagePath: s.stagePath },
|
|
13575
|
-
...s.region && { region: s.region },
|
|
13576
|
-
...s.account && { account: s.account },
|
|
13577
|
-
...s.terminationProtection !== void 0 && { terminationProtection: s.terminationProtection },
|
|
13578
|
-
template: s.template,
|
|
13579
|
-
...s.nestedTemplates !== void 0 && { nestedTemplates: s.nestedTemplates }
|
|
13580
|
-
}));
|
|
13581
|
-
synthScanStacks = result.stacks.map((s) => ({
|
|
13582
|
-
stackName: s.stackName,
|
|
13583
|
-
template: s.template
|
|
13584
|
-
}));
|
|
13585
|
-
synthesized = true;
|
|
13586
|
-
} catch (error) {
|
|
13587
|
-
if (error instanceof StageLoadError) {
|
|
13588
|
-
const named = new StageLoadError(`${error.message} To destroy a deployed stack without the app: cdkd state destroy ${commandHole("stack")}.`);
|
|
13589
|
-
if (typeof error.stack === "string") {
|
|
13590
|
-
const headerLines = `${error.name}: ${error.message}`.split("\n").length;
|
|
13591
|
-
const frames = error.stack.split("\n").slice(headerLines).join("\n");
|
|
13592
|
-
if (frames.length > 0) named.stack = `${named.name}: ${named.message}\n${frames}`;
|
|
13593
|
-
}
|
|
13594
|
-
throw named;
|
|
13595
|
-
}
|
|
13596
|
-
synthError = error instanceof Error ? error : new Error(safeStringify(error));
|
|
13597
|
-
logger.debug("Could not synthesize app, falling back to state-based stack list");
|
|
13598
|
-
}
|
|
13599
|
-
const stackPatterns = stackArgs.length > 0 ? stackArgs : options.stack ? [options.stack] : [];
|
|
13600
|
-
const wildcardPatterns = stackPatterns.filter((p) => p.includes("*") || p.includes("?"));
|
|
13601
|
-
if (appStacks.length === 0 && (options.all || wildcardPatterns.length > 0)) {
|
|
13602
|
-
const selector = options.all ? "--all" : wildcardPatterns.map((p) => displaySafe(p)).join(", ");
|
|
13603
|
-
if (synthesized) throw new Error(`${selector} selects among the stacks this app synthesizes, and it synthesized none; refusing to fall back to every stack in state.`);
|
|
13604
|
-
const hole = commandHole("stack");
|
|
13605
|
-
throw new CdkdError(`${selector} selects among the stacks this app synthesizes, and ` + (synthError ? "the app could not be synthesized" : "no app is configured") + "; refusing to fall back to every stack in state, which spans every app sharing this state bucket. " + (synthError ? "Fix the app so it synthesizes" : "Configure the app with --app or cdk.json") + `, or name each stack exactly: cdkd destroy ${hole}, or cdkd state destroy ${hole}, which needs no app.`, "DESTROY_NO_APP_SCOPE", synthError);
|
|
13606
|
-
}
|
|
13607
|
-
if (options.all && appStacks.length > 0) {
|
|
13608
|
-
const app = partitionTopLevel(appStacks);
|
|
13609
|
-
if (app.topLevel.length === 0) throw new Error(renderAllNoTopLevelStacks(app.inStages));
|
|
13610
|
-
}
|
|
13611
|
-
const allStateRefs = await stateBackend.listStacks();
|
|
13612
|
-
let candidateStacks;
|
|
13613
|
-
if (appStacks.length > 0) {
|
|
13614
|
-
const stateNames = new Set(allStateRefs.map((r) => r.stackName));
|
|
13615
|
-
candidateStacks = appStacks.filter((s) => stateNames.has(s.stackName));
|
|
13616
|
-
} else if (stackArgs.length > 0 || options.stack) {
|
|
13617
|
-
const seen = /* @__PURE__ */ new Set();
|
|
13618
|
-
candidateStacks = [];
|
|
13619
|
-
for (const ref of allStateRefs) {
|
|
13620
|
-
if (seen.has(ref.stackName)) continue;
|
|
13621
|
-
seen.add(ref.stackName);
|
|
13622
|
-
candidateStacks.push({ stackName: ref.stackName });
|
|
13623
|
-
}
|
|
13624
|
-
} else throw new CdkdError("Could not determine which stacks belong to this app. Specify stack names explicitly, or ensure --app / cdk.json is configured.", "DESTROY_NO_STACK_SELECTED", synthError);
|
|
13697
|
+
const selection = await selectDestroyTargets(stackArgs, options, stateBackend, logger);
|
|
13698
|
+
if (selection === void 0) return;
|
|
13699
|
+
const { appStacks, synthScanStacks, stackPatterns, allStateRefs, namesAppStack } = selection;
|
|
13700
|
+
let targets = selection.targets;
|
|
13625
13701
|
let totalErrors = 0;
|
|
13626
13702
|
let totalSkipped = 0;
|
|
13627
13703
|
let totalOrphanSkips = 0;
|
|
13628
13704
|
let interrupted = false;
|
|
13629
13705
|
const runInterrupted = () => interrupted || interruptWatch.interrupted();
|
|
13630
13706
|
let stoppedEarly = false;
|
|
13631
|
-
const appStackSet = new Set(appStacks);
|
|
13632
|
-
const toTarget = (s) => ({
|
|
13633
|
-
stackName: s.stackName,
|
|
13634
|
-
synth: appStackSet.has(s) ? s : void 0
|
|
13635
|
-
});
|
|
13636
|
-
let targets;
|
|
13637
|
-
const namesAppStack = /* @__PURE__ */ new Set();
|
|
13638
|
-
if (options.all) {
|
|
13639
|
-
const { topLevel, inStages } = partitionTopLevel(candidateStacks);
|
|
13640
|
-
if (inStages.length > 0) logger.warn(renderAllLeftOutStageStacks(inStages));
|
|
13641
|
-
targets = topLevel.map(toTarget);
|
|
13642
|
-
} else if (stackPatterns.length > 0) {
|
|
13643
|
-
const selectFrom = appStacks.length > 0 ? appStacks : candidateStacks;
|
|
13644
|
-
const inState = new Set(candidateStacks.map((s) => s.stackName));
|
|
13645
|
-
targets = matchStacks(selectFrom, stackPatterns, { dedupe: "identity" }).filter((s) => inState.has(s.stackName)).map(toTarget);
|
|
13646
|
-
if (appStacks.length > 0) {
|
|
13647
|
-
const gone = stacksNoLongerSelected(candidateStacks, stackPatterns, new Set(targets.map((t) => t.stackName)));
|
|
13648
|
-
if (gone.stacks.length > 0) logger.warn(renderStacksNoLongerSelected(gone.patterns, gone.stacks));
|
|
13649
|
-
}
|
|
13650
|
-
const stateNames = new Set(allStateRefs.map((r) => r.stackName));
|
|
13651
|
-
const unmatched = unmatchedPatterns(selectFrom, stackPatterns, (s) => inState.has(s.stackName));
|
|
13652
|
-
if (appStacks.length > 0) {
|
|
13653
|
-
for (const p of stackPatterns) if (appStacks.some((s) => stackMatchesPattern(s, p))) namesAppStack.add(p);
|
|
13654
|
-
}
|
|
13655
|
-
const inStateOnly = unmatched.filter((p) => stateNames.has(p) && !namesAppStack.has(p));
|
|
13656
|
-
const absent = unmatched.filter((p) => !inStateOnly.includes(p));
|
|
13657
|
-
if (absent.length > 0) logger.warn(renderUnmatchedPatternsWarning(absent, "in state"));
|
|
13658
|
-
if (targets.length > 0 && inStateOnly.length > 0) logger.warn(renderNotInAppWarning(inStateOnly));
|
|
13659
|
-
} else if (candidateStacks.length === 1) targets = candidateStacks.map(toTarget);
|
|
13660
|
-
else if (candidateStacks.length === 0) {
|
|
13661
|
-
logger.info("No stacks found in state");
|
|
13662
|
-
return;
|
|
13663
|
-
} else throw new Error(`Multiple stacks found: ${candidateStacks.map(describeStack).join(", ")}. Specify stack name(s) or use --all (top-level stacks; '**' for every stack)`);
|
|
13664
13707
|
if (targets.length === 0) {
|
|
13665
13708
|
if (stackPatterns.length > 0) {
|
|
13666
13709
|
const allStateNamesSet = new Set(allStateRefs.map((r) => r.stackName));
|
|
@@ -13683,22 +13726,9 @@ async function destroyCommand(stackArgs, options) {
|
|
|
13683
13726
|
logger.info("No matching stacks found in state");
|
|
13684
13727
|
return;
|
|
13685
13728
|
}
|
|
13686
|
-
const
|
|
13687
|
-
|
|
13688
|
-
|
|
13689
|
-
targets = orderConsumersBeforeProducers(uniqueNames, inferCrossStackStackDeps(synthScanStacks.filter((s) => inSet.has(s.stackName)))).flatMap((name) => targets.filter((t) => t.stackName === name));
|
|
13690
|
-
}
|
|
13691
|
-
const sharedAppNames = new Set(appStacks.map((s) => s.stackName).filter((name, i, names) => names.indexOf(name) !== i));
|
|
13692
|
-
const strictRegion = /* @__PURE__ */ new Map();
|
|
13693
|
-
for (const target of targets) {
|
|
13694
|
-
if (!sharedAppNames.has(target.stackName) || target.synth === void 0) continue;
|
|
13695
|
-
strictRegion.set(target, target.synth.region ?? await regionForStack(target.stackName));
|
|
13696
|
-
}
|
|
13697
|
-
const strictBySynth = new Map(targets.flatMap((t) => t.synth !== void 0 && strictRegion.has(t) ? [[t.synth, strictRegion.get(t)]] : []));
|
|
13698
|
-
const strictNames = new Set([...strictBySynth.keys()].map((s) => s.stackName));
|
|
13699
|
-
refuseStackNameRegionCollisions(appStacks.filter((s) => strictBySynth.has(s) || strictNames.has(s.stackName) && s.region !== void 0), (s) => strictBySynth.get(s) ?? s.region, new Set(strictBySynth.keys()));
|
|
13700
|
-
const describeTarget = (t) => t.synth !== void 0 && strictRegion.has(t) ? `${describeStack(t.synth)} in ${displaySafe(strictRegion.get(t))}` : displaySafe(t.stackName);
|
|
13701
|
-
logger.info(`Found ${targets.length} stack(s) to destroy: ${targets.map(describeTarget).join(", ")}`);
|
|
13729
|
+
const ordering = await orderDestroyTargets(targets, appStacks, synthScanStacks, regionForStack, logger);
|
|
13730
|
+
targets = ordering.targets;
|
|
13731
|
+
const { uniqueNames, strictRegion, describeTarget } = ordering;
|
|
13702
13732
|
const accountId = "unknown";
|
|
13703
13733
|
const stateRefsByName = /* @__PURE__ */ new Map();
|
|
13704
13734
|
for (const ref of allStateRefs) {
|
|
@@ -13921,6 +13951,8 @@ async function destroyCommand(stackArgs, options) {
|
|
|
13921
13951
|
stateBackendForCleanup?.destroyClient();
|
|
13922
13952
|
}
|
|
13923
13953
|
}
|
|
13954
|
+
|
|
13955
|
+
// src/cli/commands/destroy.ts
|
|
13924
13956
|
function createDestroyCommand() {
|
|
13925
13957
|
const cmd = new Command("destroy").description("Destroy all resources in the stack").argument("[stacks...]", "Stack name(s) to destroy. Accepts CDK display paths (e.g. 'MyStage/Api') with wildcards ('MyStage/*', '**'), or exact physical CloudFormation names (e.g. 'MyStage-Api').").option("--all", "Destroy every top-level stack (top-level only; Stage stacks: '**')", false).option("--purge-events", `After a clean destroy, also delete the stack's deployment-event history, purging every earlier version under the stack's deployments/ prefix on a versioned state bucket too unless a warning says otherwise. By default events survive destroy as post-mortem context. Skipped when the destroy fails or is interrupted (those events aid the retry). Equivalent for an already-destroyed stack: cdkd events prune ${commandHole("stack")} --all.`, false).action(withErrorHandling(destroyCommand));
|
|
13926
13958
|
[
|
|
@@ -32759,4 +32791,4 @@ function collectVerbFlags(program) {
|
|
|
32759
32791
|
}
|
|
32760
32792
|
|
|
32761
32793
|
export { resolveSecretDerivedPrincipals as a, buildProgram, isResolvableSecretPrincipalList as i, runDestroyForStack as n, canonicalizeIpProtocolValue as o, holdsUnprovenSecretPrincipalToken as r, canonicalizeIpv4Cidr as t };
|
|
32762
|
-
//# sourceMappingURL=program-
|
|
32794
|
+
//# sourceMappingURL=program-Be87SvBg.js.map
|