Preserve aws deployment state in a file and then use to redeploy.

0

How can we achieve following? Is there a command/cli for doing this:

Preserve aws deployment state in a file and then use to redeploy. Use this file to deploy and clean and then redploy to bring in same running instances and services. Can we use Sam or another command to save the state in a yaml or a similar file?

  1. command save-state <aws-state.yaml>
  2. command clean-existing-state //wipes and cleans off aws deployed state, can probably turn off or even remove
  3. command restore-state <aws-state.yaml>
  4. vim aws-state.yaml //manually make certain changes
  5. command clean-existing-state
  6. command restore-state <aws-state.yaml> //redploy updated state

Thanks

rejji
asked 2 years ago160 views
1 Answer
0

If you want to define a repeatable deployment that you can use to manage your infrastructure, you've just defined cloudformation

While there are some attempts to turn existing infrastructure into CloudFormation, such as Cloudformer - it's quite difficult to do this reliably.

You can use Drift Detection to show where your infrastructure has changed

answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions