Reputation: 767
Is this expected?
Upvotes: 7
Views: 5637
Reputation: 802
Indeed, cdk diff
will only compare the specified stack with the local template file (created by the previous cdk deploy
).
Thus, if you made some changes in the AWS Console, the AWS CDK will not detect the drift.
Since version 1.17.0, you can now do the following to detect and show drifted changes:
cdk deploy --no-execute
From the PR description:
You will be able to see the ChangeSet in AWS CloudFormation Console, validate the resources and discard or execute the ChangeSet.
Upvotes: 6