mach-composer-cli icon indicating copy to clipboard operation
mach-composer-cli copied to clipboard

Provide a way to force init

Open tleguijt opened this issue 2 years ago • 0 comments

There is logic in the cli that prevents unnecessary terraform init calls. This function checks the MACH composer CLI lock-file to see if there are any changes. If not; it will skip init.

In some cases this might cause issues, resulting in Terraform returning there is no package for registry.terraform.io/labd/commercetools 1.4.3 cached in .terraform/providers errors.

To work around this we could force an init, but mach-composer terraform init goes through the same method. For this it would be good to either explicitly force an init (mach-composer terraform init --force) or let the command itself be explicit in itself and skip the lock-file check.

tleguijt avatar Sep 18 '23 19:09 tleguijt