nearly CloudFormation can not replace a stack when a custom-named useful resource requires changing | by Teri Radichel | Bugs That Chew | Oct, 2022 will cowl the most recent and most present help not far off from the world. door slowly correspondingly you perceive capably and appropriately. will accrual your data cleverly and reliably
Ought to CloudFormation deal with this drawback robotically within the background?
I added a buyer managed prefix listing to a safety group after which began getting this error message:
CloudFormation can not replace a stack when a custom-named useful resource requires changing
It is a very unusual error message for me. What precisely is a {custom} named useful resource? I give a reputation to many sources that I create with CloudFormation. What makes one thing a “{custom} named useful resource” as an alternative of another useful resource, I merely give it a reputation.
It is not even clear on this case that the prefix listing is the issue, however I suppose it’s, as a result of that is the one factor I modified or added to this safety group.
I am unsure why the prefix listing requires substitute both. Or is it the safety group that requires substitute as a result of it is utilizing a listing of prefixes?
What I ponder on this case is why CloudFormation cannot deal with this drawback for the consumer. No matter is inflicting this isn’t very clear to me and it looks as if it may very well be dealt with within the backend.
The opposite factor is that this error message tells me to “rename” my safety group. That is the identify I need for my safety group. If I rename my present safety group, I will have a bizarre safety group hanging round that I do not want or need. If I write any automated code, it’ll simply maintain creating increasingly more safety teams. Would not it make extra sense to delete the safety group, or can CloudFormation create a brand new one? Or ought to I rename the useful resource, run the code, after which run it once more with the brand new identify?
I additionally discovered this put up, but it surely’s not that useful when it comes to answering my questions. It additionally says to rename the useful resource.
Right here is the following drawback… I attempted to take away the sources associated to this error.
First I attempted to take away the safety group:
However it will probably’t be deleted due to the principles:
So I’ve to take away these as effectively:
And… now my useful resource is caught in “Delete in progress state”
He is been sitting that method for fairly a while.
I later realized that although I used to be caught in that state, I used to be capable of click on on the useful resource and the occasion listing has an error code:
DependencyViolation
Sadly it would not say which dependency, however I am assuming it is my EC2 occasion. So you could possibly delete this group after which add it again to the EC2 occasion later. Sure, that works. As quickly as I deleted the safety group from my occasion, the useful resource was deleted.
Hopefully somebody at AWS reads this and sees how painful this error is.
I do not absolutely perceive what’s inflicting this error. I want it was clearer, however what I actually want is for AWS CloudFormation to simply deal with it correctly. It appears like AWS CloudFormation may change the useful resource identify in a transaction after which change it again to what it is imagined to be if that is what must occur right here. AWS may additionally briefly take away the SG from the pool and take away and re-add it. Higher but, resolve the issue in a method that does not have an effect on the safety group or EC2 occasion, simply the principles, as a result of that is the one factor that is altering in my case.
These are the sorts of issues that make deployments in cloud environments troublesome.
Teri Radichel
For those who like this story please applaud and proceed:
Medium: Teri Radichel or E mail Checklist: Teri Radichel
Twitter: @teriradichel or @2ndSightLab
Requests companies through LinkedIn: Teri Radichel or IANS Analysis
© second sight lab 2022
____________________________________________
Creator:
Cybersecurity for executives within the cloud period at Amazon
Do you want cloud safety coaching? 2nd Sight Lab Cloud Safety Coaching
Is your cloud safe? Rent 2nd Sight Lab for a penetration take a look at or safety evaluation.
Do you might have a query about cybersecurity or cloud safety? Ask Teri Radichel by scheduling a name with IANS Analysis.
Cybersecurity and Cloud Safety Assets by Teri Radichel: Cybersecurity and cloud safety courses, articles, white papers, shows, and podcasts
I hope the article about CloudFormation can not replace a stack when a custom-named useful resource requires changing | by Teri Radichel | Bugs That Chew | Oct, 2022 provides acuteness to you and is helpful for add-on to your data
CloudFormation cannot update a stack when a custom-named resource requires replacing | by Teri Radichel | Bugs That Bite | Oct, 2022