[Solved] Serverless loses state, you lose stack -- how to get back? production ready for important resources?

Yesterday I upgraded to 1.26. I am not sure this is related or not, but somehow serverless lost track of the stack I’m working on. So, I’m in a situation now where I have the stack that serverless created up in Cloud Front. It’s got a data/state in it that I’d like to retain (still in dev though, so we’re ok), but serverless locally claims to know nothing about it. The result is, I get errors about resources already existing. If I comment these out, I believe I will lose the resources in question on deploy. It seems like there ought to be a way to tell severless “hey, use that stack up there, after all you created it” but there’s likely something I’m missing or don’t understand.

The general question is: is there some way out of this situation? I’m a little spooked about moving to production because if this happens there it’s hard to understand the ramifications.

I have read the stuff about creating a separate repo for resources that are permanent and will do that. But it seems like the same thing could happen with that repo too. What then? It doesn’t seem like serverless is intended to be run it once in production and then walk away. Or is it w/r/t to important resources?

Thank you all an any who have comments or questions or, ideally, suggestions on how to save the stack.

Interesting. What are the specific resources that are clashing?

Whats the error messages?

The stack data should all be in CF. I’m unaware of how the local stack files in .serverless folder would effect this.

Ok, so 30 seconds ago I realized my particular predicament was ENTIRELY USER ERROR ON MY PART. I started deploying to QA with a second checkout and switched aws access keys and accounts on myself but did not switch back again when I moved back to dev. I’m sorry to have thrown any shadow in the direction of the servlerless project. It’s truly been a delight to work with. I’m moving toward production and had a bit of a panic moment when this happened this morning. I’m an relieved that this would have been surprising. Thank you again.

And I just setup of aws profiles to avoid this in the future…
For my particular question about retaining resources, this plugin looks promising to me:

Glad we (you did all the work =)) figured it out!

Super stoked for you and your project going to production! :tada:

Can you share any details on the project or is it top secret?

the business side is confidential, but the techish side:
healthcare space, lots of records, step functions delegating to humans, typescript front and back ends


Sounds awesome!

I love seeing step functions with a human component in the flow =)

Being in the healthcare space, what kinds of compliance standards do you need to follow?

And follow up to that, were you able to achieve that (easily) with the framework?

(also ignore me if you are busy :smiley:)