Inspectopedia Help

Duplicated provider

Reports duplicate providers.

Example of a problem:

provider "kubernetes" { config_path = "~/.kube/config" } provider "kubernetes" { config_path = "~/kube/kubeconfig-0728633f-2c4a-4d2b-9eb7-bc629d5e7f37" }

One of the ways to solve this problem is to add an alias and explicitly specify it when creating resources in the required provider.

Example of correction:

provider "kubernetes" { config_path = "~/.kube/config" } provider "kubernetes" { config_path = "~/kube/kubeconfig-0728633f-2c4a-4d2b-9eb7-bc629d5e7f37" alias = "cloud" }

Powered by: Terraform and HCL plugin

Locating this inspection

By ID

Can be used to locate inspection in e.g. Qodana configuration files, where you can quickly enable or disable it, or adjust its settings.

TFDuplicatedProvider
Via Settings dialog

Path to the inspection settings via IntelliJ Platform IDE Settings dialog, when you need to adjust inspection settings directly from your IDE.

Settings or Preferences | Editor | Inspections | Terraform | Duplicates

Availability

By default bundled with

IntelliJ IDEA 2024.1, Qodana for JVM 2024.1,

Can be installed with plugin

Terraform and HCL, 241.18072

Last modified: 18 June 2024