Open gautam-nutalapati opened 3 years ago
Hi @huanjani thanks for quick response. Yes root cause is same.
I see in 1.7.0, condition strings.Contains(descr.StatusReason, "didn't contain changes"
was added to avoid the deployment failure when nested stack didn't have any changes.
When we use transform, cloudformation seems to have a diferent stack status reason No updates are to be performed.
Yes, when this issue first came up a couple of months ago, we contacted the CloudFormation team to propose that this is a bug on their end. This issue seems deeper than Copilot; we will dig into this again to see what we can do.
I'm sorry you are being blocked by this; as a work-around, can you make a nominal change to the add-ons template to generate a change set?
Yes, Making a nominal change to add-ons template is our temporary approach to get things deployed.
Copilot version 1.7.1.
When Using serverless transform
AWS::Serverless-2016-10-31
in add-ons template, Service deployment fails when updating ECS task with new docker image without change to add-ons.Error seen:
Further investigation:
WithOut
AWS::Serverless-2016-10-31
: Add-ons stack change set status is failed with reasonThe submitted information didn't contain changes. Submit different information to create a change set.
. Butdeployment is successful
.With
AWS::Serverless-2016-10-31
: Add-ons stack change set status is failed with reasonNo updates are to be performed.
anddeployment fails
.Deeper investigation :)
Using custom built copilot with some extra logs, was able to pin point where the issue happens. After change set is created, copilot waits for completion of change set creation and error is thrown. Link Below err is thrown:
Summary:
If add-ons template containing
AWS::Serverless-2016-10-31
has no changes compared to previous deployment, I am not sure whyroot stack change-set
is detecting changes in add-ons stack and looks for its status, which is in Failed state and then whole deployment fails. Where as add-ons template NOT containingAWS::Serverless-2016-10-31
, theroot stack change-set
doesn't see any add-ons stack changes, and thus root stack deployment passes, even though add-ons stack is in failed state.How to reproduce:
Simply add
Transform: AWS::Serverless-2016-10-31
to any add-ons template and try to deploy new docker image viacopilot svc deploy -e <ENV> --tag <NewTag>
Sample template I used:
This prevents us from deploying new version of service hence a critical blocker.