-
Notifications
You must be signed in to change notification settings - Fork 984
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
Load config from an output or data resource #383
Conversation
Hi and thanks for trying to address this! It's a really useful feature that's been missing in the provider. However, I do have reservations about dumping the intermediate config to disk (only to load it back up again soon after). This has security implications that aren't visible to the majority of users due to the "behind the scenes" nature of this approach. So unless the user actually scrutinizes the implementation they will not understand that sensitive credentials are persisted to disk (and also not cleaned up on destroy). I'd like to propose an alternative implementation that would make use of direct loading of client config from an in-memory source. What do you think? |
@alexsomesan I share your reservations and apologize I didn't look much beyond how the provider itself was loading the config. You pointed me exactly in the right direction for ridding this of that pesky tempfile ;) I'll give this a serious stab as soon as I can. Thanks! |
Had a quick skim through the latest changes and they're looking good. |
@alexsomesan more than happy to add a test for that. This has been a great opportunity to explore Terraform's guts. I hope I didn't butcher it up too badly. Thank you for your guidance. |
Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement Learn more about why HashiCorp requires a CLA and what the CLA includes Have you signed the CLA already but the status is still pending? Recheck it. |
Sorry guys, just now noticing this is still open and no longer needed. Thanks for allowing me to participate! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks! |
Streamline the kubernetes provisioner to work in more harmony with the infrastructure where the kubernetes cluster is deployed.
It is helpful to think in the module context, such as a fluentd module which uses terraform to provision resources in kubernetes (daemonset, maybe a configmap), some cloudwatch log groups, and IAM roles. Such terraform files would already have very specific things set (AWS region, credentials) to move the author into the line of thought where a Kubernetes cluster is under the AWS umbrella rather than one umbrella for AWS and one umbrella for Kubernetes.
Example Usage
For example, if we're working with an EKS cluster in Amazon deployed by the eks_cluster resource from the AWS provider, imagine an output specifying the kube config file (absolutely free of secrets).
In the future, this can be tidied up and recycled across multiple providers, not just AWS. Imagine a data resource on aws_eks_cluster called
config_file
.This should allow us the additional benefit of keeping EKS tokens out of statefiles.
This PR is a rehash of #380.