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

Unable to import module in project with Terraform 0.13.4 #10

Open
wgebis opened this issue Oct 21, 2020 · 5 comments
Open

Unable to import module in project with Terraform 0.13.4 #10

wgebis opened this issue Oct 21, 2020 · 5 comments

Comments

@wgebis
Copy link

wgebis commented Oct 21, 2020

Describe the bug
Unable to import module in project with Terraform 13.4 due to:

Error: Invalid reference from destroy provisioner

  on .terraform/modules/linkerd/crds.tf line 17, in resource "null_resource" "crds":
  17:     command = "kubectl delete -f - <<EOF\n${data.template_file.crds.rendered}\nEOF"

Also two warning about deprecation also are there:

Warning: Interpolation-only expressions are deprecated

  on .terraform/modules/linkerd/controller.tf line 216, in resource "kubernetes_deployment" "linkerd_controller":
 216:             "${local.linkerd_deployment_incoming_proxy_port}",

(and 38 more similar warnings elsewhere)

....

Warning: Quoted keywords are deprecated

  on .terraform/modules/linkerd/crds.tf line 16, in resource "null_resource" "crds":
  16:     when = "destroy"

To Reproduce

  1. Put module in tf file
module "linkerd" {
  source = "git::ssh://[email protected]/rtlnl/terraform-aws-linkerd2.git?ref=main"
}
  1. Import it
terraform init

Expected behavior
Possibility to import module on Terraform >=0.13.4

Desktop (please complete the following information):

  • OS: macos
  • Terraform: 0.13.4
@spaghettifunk
Copy link
Contributor

Thank you for reporting this bug @wgebis. I will take a look into this and solve it asap.

@spaghettifunk
Copy link
Contributor

The problem has been fixed and tested with terraform 0.13.5 and kind. Let me know if the problem still appear! Thank you again 👍

@wgebis
Copy link
Author

wgebis commented Nov 5, 2020

Hi @spaghettifunk ,
Not sure if it is referred to that ticket, but I think you shout mark empty_dir under followed volume as lifecycle ignored:

 ~ volume {
                        name = "data"

                      - empty_dir {}
                    }

Every terraform apply discover that change (promethues and grafana deployment)

@wgebis
Copy link
Author

wgebis commented Nov 5, 2020

And also that issue I've got:

It appears that you are trying to reach this service with a host of 'my_domain.
This does not match /^(localhost|127\.0\.0\.1|linkerd-web\.linkerd\.svc\.cluster\.local|linkerd-web\.linkerd\.svc|\[::1\])(:\d+)?$/ and has been denied for security reasons.
Please see https://linkerd.io/dns-rebinding for an explanation of what is happening and how to fix it.

@spaghettifunk
Copy link
Contributor

I'll take a look at it tomorrow. Thanks for reporting 👍

@spaghettifunk spaghettifunk reopened this Nov 8, 2020
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