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

Stop using deprecated template_file (use templatefile instead) #19

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

npwolf
Copy link

@npwolf npwolf commented Dec 19, 2023

When running on my M1 Mac, I was getting the following error:

│ Error: Incompatible provider version
│
│ Provider registry.terraform.io/hashicorp/template v2.2.0 does not have a package available for your current platform, darwin_arm64.
│
│ Provider releases are separate from Terraform CLI releases, so not all providers are available for all platforms. Other versions of
│ this provider may have different platforms supported.

This PR stops the error by moving away from the deprecated template_file to templatefile.

@@ -91,7 +87,7 @@ module "vpn_server" {
key_name = var.vpn_key_pair
associate_public_ip_address = true
vpc_security_group_ids = [module.security_group_vpn.security_group_id]
user_data = join("", data.template_file.pritunl[*].rendered)
user_data = templatefile("${path.module}/scripts/pritunl-vpn.sh")
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not really sure why template_file or templatefile is actually needed. There is nothing being replaced in this file from what I can see.

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.

1 participant