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

Support provider aliases and 0.13 identities #164

Closed
paultyng opened this issue Jun 15, 2020 · 3 comments · Fixed by #255
Closed

Support provider aliases and 0.13 identities #164

paultyng opened this issue Jun 15, 2020 · 3 comments · Fixed by #255
Assignees
Labels
Milestone

Comments

@paultyng
Copy link
Contributor

Terraform Version

This affects 0.13 mostly, but to a lesser degree 0.12

Terraform Configuration Files

terraform {
  required_providers {
    null = {
      source = "hashicorp/null"
      version = "2.1.2"
    }
    null2 = {
      source = "paultyng/null"
      version = "0.1.0"
    }
  }
}

provider "null2" {
    alias = "null3"
}

resource "null_resource" "foo" {

}

resource "null_resource" "bar" {
    provider = null2
}

resource "null_resource" "baz" {
    provider = null2.null3
}

Expected Behavior

Auto-completion with multiple providers that have conflicting resource names should include the addition of the provider = attribute.

Actual Behavior

I believe resources with the same type names currently are just overwritten by the last one in. This can also probably be observed in 0.12 with google and google-beta.

@paultyng
Copy link
Contributor Author

https://github.com/hashicorp/terraform-config-inspect does not yet support listing out possible aliases, only ones in used on resources, so that will need to be addressed upstream (or parsed out manually).

@radeksimko
Copy link
Member

Just realized that provider block completion doesn't work at all with 0.13, since we're looking e.g. for aws, but 0.13 indexes that as registry.terraform.io/hashicorp/aws.

Also provider labels are completed with the FQN too, which is wrong:

Screenshot 2020-06-30 at 19 42 54

@ghost
Copy link

ghost commented Sep 6, 2020

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the context necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Sep 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants