dce
dce copied to clipboard
Unable to overide variables with dce client / have to deploy with Terraform
Version information
- DCE version: 0.5
- OS version: MacOS 10.15.7
- Go version: whatever DCE CLI comes with
- Terraform version : whatever DCE CLI comes with
Describe the bug
After deploying DCE with the DCE CLI using dce system deploy
unable to override the variables reset_nuke_template_bucket
and reset_nuke_template_key
with Terraform afterwards as the TF init directory is located at $HOME/.dce/.cache/module/.terraform
directory that contains only main.tf
as it's module and does not contain these variables. Tried to init the directory $HOME/.dce/.cache/module/.terraform/modules/dce/modules
using the state file produced by DCE CLI deployment but the tf plan
wants to remove all the infrastructure and replace it with a complete new set of DCE infrastructure and I would have expected a plan that at most will replace the CodeBuild infrastructure or even better just update the Environment variables of the Code Build project.
To Reproduce Steps to reproduce the behavior:
- Deploy DCE with CLI i.e. "dce system deploy"
- Try
tf plan -var reset_nuke_template_bucket=some-bucket-name -var reset_nuke_template_key=custom-config-files/aws-nuke-default.yaml
that naturally errors out that the variables are not specified in modulemain.tf
- Also tried
dce system deploy --tf-apply-options "-var reset_nuke_template_bucket=some-bucket-name -var reset_nuke_template_key=custom-config-files/aws-nuke-default.yaml"
which exits with code 1 without any explanation and didn't find any logs that could help 🤷♂️
Expected behavior
Would expect the DCE CLI --tf-apply-options
to work though now exits with error code 1.
Additional context Is modifying TF variables supported when using DCE CLI, and is it supported to modify then post deployment, or do you have to specify the variable overide values at the time of deployment? What if you want to change the variables after deployment? Is TF deployment the better option if one feels the need to override any variables?`
Hi, did you find a solution with the dce cli to update the deployement ? I ve got the same issue on my side.
Version information
- DCE version: 0.5
- OS version: MacOS 10.15.7
- Go version: whatever DCE CLI comes with
- Terraform version : whatever DCE CLI comes with
Describe the bug After deploying DCE with the DCE CLI using
dce system deploy
unable to override the variablesreset_nuke_template_bucket
andreset_nuke_template_key
with Terraform afterwards as the TF init directory is located at$HOME/.dce/.cache/module/.terraform
directory that contains onlymain.tf
as it's module and does not contain these variables. Tried to init the directory$HOME/.dce/.cache/module/.terraform/modules/dce/modules
using the state file produced by DCE CLI deployment but thetf plan
wants to remove all the infrastructure and replace it with a complete new set of DCE infrastructure and I would have expected a plan that at most will replace the CodeBuild infrastructure or even better just update the Environment variables of the Code Build project.To Reproduce Steps to reproduce the behavior:
- Deploy DCE with CLI i.e. "dce system deploy"
- Try
tf plan -var reset_nuke_template_bucket=some-bucket-name -var reset_nuke_template_key=custom-config-files/aws-nuke-default.yaml
that naturally errors out that the variables are not specified in modulemain.tf
- Also tried
dce system deploy --tf-apply-options "-var reset_nuke_template_bucket=some-bucket-name -var reset_nuke_template_key=custom-config-files/aws-nuke-default.yaml"
which exits with code 1 without any explanation and didn't find any logs that could help 🤷♂️Expected behavior Would expect the DCE CLI
--tf-apply-options
to work though now exits with error code 1.Additional context Is modifying TF variables supported when using DCE CLI, and is it supported to modify then post deployment, or do you have to specify the variable overide values at the time of deployment? What if you want to change the variables after deployment? Is TF deployment the better option if one feels the need to override any variables?`
Is this still an issue? I am having issue with terraform deploy and lambda being not ready. So would try this but want to override nuke settings