containerlab
containerlab copied to clipboard
add `redeploy` command
redeploy command answers the need to quickly re-deploy a lab. It should be possible to redeploy a lab with and without keeping the lab directory.
Conceptually, redeploying a lab is a sequence of a destroy and deploy commands.
I'd like to try and tackle this if possible.
Sure. Thanks Alexandre!
On Thu, 29 Sep 2022 at 23:33, Alexandre Hassan @.***> wrote:
I'd like to try and tackle this if possible.
— Reply to this email directly, view it on GitHub https://github.com/srl-labs/containerlab/issues/1010#issuecomment-1262840392, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABLKV5J6LFIC356EKBTQG5LWAYDL7ANCNFSM6AAAAAAQBPARAE . You are receiving this because you authored the thread.Message ID: @.***>
@hellt - re: keeping the lab directory, am I correct in these assumptions?
- In keeping the directory - the user has made changes, and wants a clean slate to reset the lab
- In destroying the directory - the user has made changes in the
node.cfgfiles and wants to rebuild the lab with the new config files
@scotho3
- you want to keep a directory if you want some artifacts from it to be picked up when you destroy+deploy it again. Typically, this is related to the configuration that users saved during lab lifetime and they want these configs to be applied once they redeployt the lab. For example, you launched a lab, added some configs to the nodes, saved those configs so that they got written to disk (lab directory). Now you want to redeploy the lab for whatever reason, maybe you want to free up resources and get back to that lab later. You destroy the lab without removing the lab directory. Then you deploy the lab again, and those files from the lab directory will be picked up as startup config.
- When you remove the lab dir, all your configs that were persisted before will be flushed. You will start from a completely clean slate.
HTH