Displaying a list of providers used in a configuration
When we use several Terraform providers inside a Terraform configuration, it’s important to have governance over the providers list to upgrade them frequently.
In this recipe, we will learn how to display the list of providers used in our Terraform configuration with their versions.
Let’s get started!
Getting ready
To complete this recipe, we will use a sample Terraform configuration that contains some providers.
The following code contains the Terraform configuration:
terraform {
required_version = ">= 1.0"
required_providers {
random = {
source = "hashicorp/random"
version = "3.4.3"
}
azurerm = {
source = "hashicorp/azurerm"
version = "3.29.1"
}
http = {
source = "hashicorp/http"
version = "3.2.1"
}
null = {
source = "hashicorp/null"...