Skip to content

Commit 74c4c6f

Browse files
fix(migrate): --from-stack does not retrieved processed template (#29035)
---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent 798ea05 commit 74c4c6f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/aws-cdk/lib/commands/migrate.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ export function readFromPath(inputPath: string): string {
120120
export async function readFromStack(stackName: string, sdkProvider: SdkProvider, environment: Environment): Promise<string | undefined> {
121121
const cloudFormation = (await sdkProvider.forEnvironment(environment, Mode.ForReading)).sdk.cloudFormation();
122122

123-
const stack = await CloudFormationStack.lookup(cloudFormation, stackName);
123+
const stack = await CloudFormationStack.lookup(cloudFormation, stackName, true);
124124
if (stack.stackStatus.isDeploySuccess || stack.stackStatus.isRollbackSuccess) {
125125
return JSON.stringify(await stack.template());
126126
} else {

0 commit comments

Comments
 (0)