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

Update "cloudposse/utils" provider versions to 1.7.1 #62

Merged
merged 3 commits into from
Feb 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright 2021-2022 Cloud Posse, LLC
Copyright 2021-2023 Cloud Posse, LLC

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -346,13 +346,13 @@ Available targets:
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 0.14.0 |
| <a name="requirement_external"></a> [external](#requirement\_external) | >= 2.0 |
| <a name="requirement_local"></a> [local](#requirement\_local) | >= 1.3 |
| <a name="requirement_utils"></a> [utils](#requirement\_utils) | >= 1.5.0 |
| <a name="requirement_utils"></a> [utils](#requirement\_utils) | >= 1.7.1 |

## Providers

| Name | Version |
|------|---------|
| <a name="provider_utils"></a> [utils](#provider\_utils) | >= 1.5.0 |
| <a name="provider_utils"></a> [utils](#provider\_utils) | >= 1.7.1 |

## Modules

Expand Down
4 changes: 2 additions & 2 deletions docs/terraform.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 0.14.0 |
| <a name="requirement_external"></a> [external](#requirement\_external) | >= 2.0 |
| <a name="requirement_local"></a> [local](#requirement\_local) | >= 1.3 |
| <a name="requirement_utils"></a> [utils](#requirement\_utils) | >= 1.5.0 |
| <a name="requirement_utils"></a> [utils](#requirement\_utils) | >= 1.7.1 |

## Providers

| Name | Version |
|------|---------|
| <a name="provider_utils"></a> [utils](#provider\_utils) | >= 1.5.0 |
| <a name="provider_utils"></a> [utils](#provider\_utils) | >= 1.7.1 |

## Modules

Expand Down
2 changes: 1 addition & 1 deletion examples/backend/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion examples/complete/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion examples/remote-state/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion examples/spacelift/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = "1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion examples/stack/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion examples/stacks/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/backend/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/env/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/remote-state/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ terraform {
# add a != constraint for that version.
# Leave a redundant != constraint for the last known bad version
# as an example of how to add a constraint for a bad version.
version = ">= 1.5.0, != 1.4.0, <= 1.5.0"
version = ">= 1.7.1, != 1.4.0, <= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/settings/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/spacelift/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
2 changes: 1 addition & 1 deletion modules/vars/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ terraform {
}
utils = {
source = "cloudposse/utils"
version = ">= 1.5.0"
version = ">= 1.7.1"
}
}
}
8 changes: 4 additions & 4 deletions test/src/examples_remote_state_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ func TestExamplesRemoteState(t *testing.T) {
terraform.InitAndApply(t, terraformOptions)

// Run `terraform output` to get the value of an output variable
var output interface{}
var output any

terraform.OutputStruct(t, terraformOptions, "remote_state_using_stack", &output)
remoteStateUsingStack := output.(map[string]interface{})
remoteStateUsingStack := output.(map[string]any)

// Verify we're getting back the outputs we expect
assert.NotNilf(t, remoteStateUsingStack, "remote state is empty")
Expand All @@ -37,7 +37,7 @@ func TestExamplesRemoteState(t *testing.T) {
assert.Equal(t, nil, remoteStateUsingStack["val4"])

terraform.OutputStruct(t, terraformOptions, "remote_state_using_context", &output)
remoteStateUsingContext := output.(map[string]interface{})
remoteStateUsingContext := output.(map[string]any)

// Verify we're getting back the outputs we expect
assert.NotNilf(t, remoteStateUsingContext, "remote state is empty")
Expand All @@ -47,7 +47,7 @@ func TestExamplesRemoteState(t *testing.T) {
assert.Equal(t, nil, remoteStateUsingContext["val4"])

terraform.OutputStruct(t, terraformOptions, "remote_state_using_context_ignore_errors", &output)
remoteStateUsingContextIgnoreErrors := output.(map[string]interface{})
remoteStateUsingContextIgnoreErrors := output.(map[string]any)

// Verify we're getting back the outputs we expect
assert.NotNilf(t, remoteStateUsingContextIgnoreErrors, "remote state is empty")
Expand Down
44 changes: 20 additions & 24 deletions test/src/examples_spacelift_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,54 +24,50 @@ func TestExamplesSpacelift(t *testing.T) {
terraform.InitAndApply(t, terraformOptions)

// Run `terraform output` to get the value of an output variable
var output interface{}
var output any
terraform.OutputStruct(t, terraformOptions, "spacelift_stacks", &output)
spaceliftStacks := output.(map[string]interface{})
spaceliftStacks := output.(map[string]any)

// Verify we're getting back the outputs we expect
assert.Equal(t, 30, len(spaceliftStacks))

tenant1Ue2DevInfraVpcStack := spaceliftStacks["tenant1-ue2-dev-infra-vpc"].(map[string]interface{})
tenant1Ue2DevInfraVpcStack := spaceliftStacks["tenant1-ue2-dev-infra-vpc"].(map[string]any)
tenant1Ue2DevInfraVpcStackInfrastructureStackName := tenant1Ue2DevInfraVpcStack["stack"].(string)
tenant1Ue2DevInfraVpcStackBackend := tenant1Ue2DevInfraVpcStack["backend"].(map[string]interface{})
tenant1Ue2DevInfraVpcStackBackend := tenant1Ue2DevInfraVpcStack["backend"].(map[string]any)
tenant1Ue2DevInfraVpcStackBackendWorkspaceKeyPrefix := tenant1Ue2DevInfraVpcStackBackend["workspace_key_prefix"].(string)
assert.Equal(t, "tenant1-ue2-dev", tenant1Ue2DevInfraVpcStackInfrastructureStackName)
assert.Equal(t, "infra-vpc", tenant1Ue2DevInfraVpcStackBackendWorkspaceKeyPrefix)

tenant1Ue2DevTestTestComponentOverrideComponent := spaceliftStacks["tenant1-ue2-dev-test-test-component-override"].(map[string]interface{})
tenant1Ue2DevTestTestComponentOverrideComponent := spaceliftStacks["tenant1-ue2-dev-test-test-component-override"].(map[string]any)
tenant1Ue2DevTestTestComponentOverrideComponentInfrastructureStackName := tenant1Ue2DevTestTestComponentOverrideComponent["stack"].(string)
tenant1Ue2DevTestTestComponentOverrideComponentBackend := tenant1Ue2DevTestTestComponentOverrideComponent["backend"].(map[string]interface{})
tenant1Ue2DevTestTestComponentOverrideComponentBackend := tenant1Ue2DevTestTestComponentOverrideComponent["backend"].(map[string]any)
tenant1Ue2DevTestTestComponentOverrideComponentBaseComponent := tenant1Ue2DevTestTestComponentOverrideComponent["base_component"].(string)
tenant1Ue2DevTestTestComponentOverrideComponentBackendWorkspaceKeyPrefix := tenant1Ue2DevTestTestComponentOverrideComponentBackend["workspace_key_prefix"].(string)
tenant1Ue2DevTestTestComponentOverrideComponentDeps := tenant1Ue2DevTestTestComponentOverrideComponent["deps"].([]interface{})
tenant1Ue2DevTestTestComponentOverrideComponentLabels := tenant1Ue2DevTestTestComponentOverrideComponent["labels"].([]interface{})
tenant1Ue2DevTestTestComponentOverrideComponentDeps := tenant1Ue2DevTestTestComponentOverrideComponent["deps"].([]any)
tenant1Ue2DevTestTestComponentOverrideComponentLabels := tenant1Ue2DevTestTestComponentOverrideComponent["labels"].([]any)
tenant1Ue2DevTestTestComponentOverrideTerraformWorkspace := tenant1Ue2DevTestTestComponentOverrideComponent["workspace"]
assert.Equal(t, "tenant1-ue2-dev", tenant1Ue2DevTestTestComponentOverrideComponentInfrastructureStackName)
assert.Equal(t, "test-test-component", tenant1Ue2DevTestTestComponentOverrideComponentBackendWorkspaceKeyPrefix)
assert.Equal(t, "test/test-component", tenant1Ue2DevTestTestComponentOverrideComponentBaseComponent)
assert.Equal(t, 11, len(tenant1Ue2DevTestTestComponentOverrideComponentDeps))
assert.Equal(t, 10, len(tenant1Ue2DevTestTestComponentOverrideComponentDeps))
assert.Equal(t, "catalog/terraform/services/service-1", tenant1Ue2DevTestTestComponentOverrideComponentDeps[0])
assert.Equal(t, "catalog/terraform/services/service-1-override", tenant1Ue2DevTestTestComponentOverrideComponentDeps[1])
assert.Equal(t, "catalog/terraform/services/service-2", tenant1Ue2DevTestTestComponentOverrideComponentDeps[2])
assert.Equal(t, "catalog/terraform/services/service-2-override", tenant1Ue2DevTestTestComponentOverrideComponentDeps[3])
assert.Equal(t, "catalog/terraform/tenant1-ue2-dev", tenant1Ue2DevTestTestComponentOverrideComponentDeps[4])
assert.Equal(t, "catalog/terraform/test-component", tenant1Ue2DevTestTestComponentOverrideComponentDeps[5])
assert.Equal(t, "catalog/terraform/test-component-override", tenant1Ue2DevTestTestComponentOverrideComponentDeps[6])
assert.Equal(t, "globals/globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[7])
assert.Equal(t, "globals/tenant1-globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[8])
assert.Equal(t, "globals/ue2-globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[9])
assert.Equal(t, "tenant1/ue2/dev", tenant1Ue2DevTestTestComponentOverrideComponentDeps[10])
assert.Equal(t, 36, len(tenant1Ue2DevTestTestComponentOverrideComponentLabels))
assert.Equal(t, "catalog/terraform/test-component-override", tenant1Ue2DevTestTestComponentOverrideComponentDeps[5])
assert.Equal(t, "globals/globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[6])
assert.Equal(t, "globals/tenant1-globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[7])
assert.Equal(t, "globals/ue2-globals", tenant1Ue2DevTestTestComponentOverrideComponentDeps[8])
assert.Equal(t, 35, len(tenant1Ue2DevTestTestComponentOverrideComponentLabels))
assert.Equal(t, "deps:stacks/catalog/terraform/services/service-2.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[25])
assert.Equal(t, "deps:stacks/catalog/terraform/services/service-2-override.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[26])
assert.Equal(t, "deps:stacks/catalog/terraform/tenant1-ue2-dev.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[27])
assert.Equal(t, "deps:stacks/catalog/terraform/test-component.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[28])
assert.Equal(t, "deps:stacks/catalog/terraform/test-component-override.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[29])
assert.Equal(t, "deps:stacks/globals/globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[30])
assert.Equal(t, "deps:stacks/globals/tenant1-globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[31])
assert.Equal(t, "deps:stacks/globals/ue2-globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[32])
assert.Equal(t, "deps:stacks/tenant1/ue2/dev.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[33])
assert.Equal(t, "folder:component/test/test-component-override", tenant1Ue2DevTestTestComponentOverrideComponentLabels[34])
assert.Equal(t, "folder:tenant1/ue2/dev", tenant1Ue2DevTestTestComponentOverrideComponentLabels[35])
assert.Equal(t, "deps:stacks/catalog/terraform/test-component-override.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[28])
assert.Equal(t, "deps:stacks/globals/globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[29])
assert.Equal(t, "deps:stacks/globals/tenant1-globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[30])
assert.Equal(t, "deps:stacks/globals/ue2-globals.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[31])
assert.Equal(t, "deps:stacks/tenant1/ue2/dev.yaml", tenant1Ue2DevTestTestComponentOverrideComponentLabels[32])
assert.Equal(t, "folder:component/test/test-component-override", tenant1Ue2DevTestTestComponentOverrideComponentLabels[33])
assert.Equal(t, "test-component-override-workspace-override", tenant1Ue2DevTestTestComponentOverrideTerraformWorkspace)
}
4 changes: 2 additions & 2 deletions test/src/examples_stacks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ func TestExamplesStacks(t *testing.T) {
terraform.InitAndApply(t, terraformOptions)

// Run `terraform output` to get the value of an output variable
var output interface{}
var output any
terraform.OutputStruct(t, terraformOptions, "config", &output)
config := output.([]interface{})
config := output.([]any)

// Verify we're getting back the outputs we expect
assert.Equal(t, 4, len(config))
Expand Down
12 changes: 6 additions & 6 deletions test/src/go.mod
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module github.com/cloudposse/terraform-yaml-stack-config

go 1.17
go 1.19

require (
github.com/gruntwork-io/terratest v0.39.0
github.com/stretchr/testify v1.7.0
github.com/gruntwork-io/terratest v0.41.10
github.com/stretchr/testify v1.8.1
)

require (
Expand All @@ -21,7 +21,7 @@ require (
github.com/googleapis/gax-go/v2 v2.0.5 // indirect
github.com/hashicorp/errwrap v1.0.0 // indirect
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
github.com/hashicorp/go-getter v1.5.11 // indirect
github.com/hashicorp/go-getter v1.6.1 // indirect
github.com/hashicorp/go-multierror v1.1.0 // indirect
github.com/hashicorp/go-safetemp v1.0.0 // indirect
github.com/hashicorp/go-version v1.3.0 // indirect
Expand All @@ -45,7 +45,7 @@ require (
golang.org/x/mod v0.4.2 // indirect
golang.org/x/net v0.0.0-20210614182718-04defd469f4e // indirect
golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c // indirect
golang.org/x/sys v0.0.0-20210603125802-9665404d3644 // indirect
golang.org/x/sys v0.0.0-20220517195934-5e4e11fc645e // indirect
golang.org/x/text v0.3.6 // indirect
golang.org/x/tools v0.1.2 // indirect
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
Expand All @@ -54,5 +54,5 @@ require (
google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c // indirect
google.golang.org/grpc v1.38.0 // indirect
google.golang.org/protobuf v1.26.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Loading