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 for_each + templatefile instead of template_dir #157

Closed
wants to merge 1 commit into from

Conversation

vroad
Copy link

@vroad vroad commented Nov 9, 2019

To avoid template provider issue on windows: hashicorp/terraform-provider-template#73

Even though this PR still uses local_file resource, the change would also make it easier to change resource type to aws_s3_bucket_object by patching the content of the module.
I'd like to customize the module for putting all generated files to s3 instead of local filesystem.
Changing all local_file to aws_s3_bucket_object still requires some work when new files are added to the module, but better than nothing.

I suppose it's also possible to output only content of generated manifests. That way, users of the module could put content to remote store like S3 if they want.
Let's start with this PR anyway, so that we could avoid making BC-breaking changes to the module.

template_dir resource type doesn't support outputting to s3 and probably never will. Since the name of generated files is not included in the plan, it's not possible to consume generated files either without writing hand-written scripts.

@dghubble
Copy link
Member

Structuring this as #159, but thanks anyway!

@dghubble dghubble closed this Nov 14, 2019
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

Successfully merging this pull request may close these issues.

2 participants