Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use local TF backend by default #52

Closed
nathanagood opened this issue Dec 16, 2019 · 7 comments
Closed

Use local TF backend by default #52

nathanagood opened this issue Dec 16, 2019 · 7 comments
Assignees

Comments

@nathanagood
Copy link
Contributor

Is your feature request related to a problem? Please describe.

If I am using the CLI, I may not want to keep TF state in a S3 bucket.

Describe the solution you'd like

By default, the CLI will use a TF local state file for the backend configuration.

Describe alternatives you've considered

Additional context

@nathanagood
Copy link
Contributor Author

See related issue #15

@nathanagood
Copy link
Contributor Author

nathanagood commented Dec 16, 2019

A bit duplicate of #18 (more or less). Closing #18 and moving here.

@nathanagood
Copy link
Contributor Author

Should the remote (S3) behavior be preserved? Should there be an optional flag or something (eg., "--use-s3-backend") that when set would use the existing behavior but the default will simply be the local backend?

@eschwartz
Copy link
Contributor

The plan we discussed was to not create any kind of TF backend for you, but to allow the end-user to configure their own backend in dce.yml

eg, something like:

terraform:
  backend:
    type: s3
    bucket: my-state-bucket
    key: terraform.tfstate

@eschwartz
Copy link
Contributor

Should the remote (S3) behavior be preserved

Also note that the s3 backend never actually worked -- it would create a new backend and tfstate file with every call to dce system deploy.

@nathanagood
Copy link
Contributor Author

The plan we discussed was to not create any kind of TF backend for you, but to allow the end-user to configure their own backend in dce.yml

eg, something like:

terraform:
  backend:
    type: s3
    bucket: my-state-bucket
    key: terraform.tfstate

OK. I re-opened #15 to handle the second part of this problem. This issue is specifically addressing not creating any kind of TF backend for you.

@nathanagood
Copy link
Contributor Author

Using a local terraform backend is currently now the default behavior for the dce system deploy command, and technically the only supported behavior until #54 is pushed out (which is my next priority). The backend file is created in ~/.dce/.cache/module/main.tf.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants