|
|
|
|
|
by JohnMakin
770 days ago
|
|
I know many people find it painful but isn't this fairly simple with "terraform state mv?" my process is roughly: comment out the resource in the module, run a plan -> get output like: "module.foo1.aws_resource.bar will be deleted" Then copy my resource in source to module.foo2.aws_resource.bar, the command becomes: terraform state mv module.foo1.aws_resource.bar module.foo2.aws_resource.bar I guess this might be harder if you're using upstream "official" modules, but I avoid those like the plague. |
|