Skip to content

Commit

Permalink
Loosen pinning on CDP provider (#72)
Browse files Browse the repository at this point in the history
Signed-off-by: Jim Enright <[email protected]>
  • Loading branch information
jimright authored Jul 24, 2024
1 parent 61b41df commit 50db9ee
Show file tree
Hide file tree
Showing 11 changed files with 92 additions and 18 deletions.
6 changes: 3 additions & 3 deletions modules/terraform-cdp-aws-pre-reqs/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ terraform {
}
http = {
source = "hashicorp/http"
version = "3.2.1"
version = "~> 3.2.1"
}
random = {
source = "hashicorp/random"
version = "3.4.3"
version = "~> 3.4.3"
}
time = {
source = "hashicorp/time"
version = "0.9.1"
version = "~> 0.9.1"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-azure-pre-reqs/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ terraform {
}
random = {
source = "hashicorp/random"
version = "3.4.3"
version = "~> 3.4.3"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-deploy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ In each directory an example `terraform.tfvars.sample` values file is included t
| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.3.0 |
| <a name="requirement_cdp"></a> [cdp](#requirement\_cdp) | 0.6.1 |
| <a name="requirement_cdp"></a> [cdp](#requirement\_cdp) | ~> 0.6.1 |

## Providers

Expand Down
34 changes: 26 additions & 8 deletions modules/terraform-cdp-deploy/examples/ex01-aws-basic/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,32 @@
# See the License for the specific language governing permissions and
# limitations under the License.

terraform {
required_version = ">= 1.5.7"
required_providers {
cdp = {
source = "cloudera/cdp"
version = "~> 0.6.1"
}
aws = {
source = "hashicorp/aws"
version = "~>5.30"
}
tls = {
source = "hashicorp/tls"
version = "~> 4.0.5"
}
local = {
source = "hashicorp/local"
version = "~> 2.5.1"
}
http = {
source = "hashicorp/http"
version = "~> 3.2.1"
}
}
}

provider "aws" {
region = var.aws_region
}
Expand Down Expand Up @@ -84,12 +110,4 @@ module "cdp_deploy" {
}

# Use the CDP Terraform Provider to find the xaccount account and external ids
terraform {
required_providers {
cdp = {
source = "cloudera/cdp"
version = "0.6.1"
}
}
}
data "cdp_environments_aws_credential_prerequisites" "cdp_prereqs" {}
30 changes: 30 additions & 0 deletions modules/terraform-cdp-deploy/examples/ex02-azure-basic/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,36 @@
# See the License for the specific language governing permissions and
# limitations under the License.

terraform {
required_version = ">= 1.5.7"
required_providers {
cdp = {
source = "cloudera/cdp"
version = "~> 0.6.1"
}
azurerm = {
source = "hashicorp/azurerm"
version = "3.84.0"
}
azuread = {
source = "hashicorp/azuread"
version = "2.46.0"
}
tls = {
source = "hashicorp/tls"
version = "~> 4.0.5"
}
local = {
source = "hashicorp/local"
version = "~> 2.5.1"
}
http = {
source = "hashicorp/http"
version = "~> 3.2.1"
}
}
}

provider "azurerm" {
features {
resource_group {
Expand Down
26 changes: 26 additions & 0 deletions modules/terraform-cdp-deploy/examples/ex03-gcp-basic/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,32 @@
# See the License for the specific language governing permissions and
# limitations under the License.

terraform {
required_version = ">= 1.5.7"
required_providers {
cdp = {
source = "cloudera/cdp"
version = "~> 0.6.1"
}
google = {
source = "hashicorp/google"
version = "4.84.0"
}
tls = {
source = "hashicorp/tls"
version = "~> 4.0.5"
}
local = {
source = "hashicorp/local"
version = "~> 2.5.1"
}
http = {
source = "hashicorp/http"
version = "~> 3.2.1"
}
}
}

provider "google" {
project = var.gcp_project
region = var.gcp_region
Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-deploy/modules/aws/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ terraform {
required_providers {
cdp = {
source = "cloudera/cdp"
version = "0.6.1"
version = "~> 0.6.1"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-deploy/modules/azure/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ terraform {
required_providers {
cdp = {
source = "cloudera/cdp"
version = "0.6.1"
version = "~> 0.6.1"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-deploy/modules/gcp/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ terraform {
required_providers {
cdp = {
source = "cloudera/cdp"
version = "0.6.1"
version = "~> 0.6.1"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-deploy/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ terraform {
required_providers {
cdp = {
source = "cloudera/cdp"
version = "0.6.1"
version = "~> 0.6.1"
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/terraform-cdp-gcp-pre-reqs/provider.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ terraform {
}
random = {
source = "hashicorp/random"
version = "3.4.3"
version = "~> 3.4.3"
}
}

Expand Down

0 comments on commit 50db9ee

Please sign in to comment.