Skip to content

Commit

Permalink
chore: bump sumologic terraform provider to v2.11.5 (#2062) (#2066)
Browse files Browse the repository at this point in the history
* chore: bump sumologic terraform provider

* Update deploy/helm/sumologic/conf/cleanup/cleanup.sh

Co-authored-by: Dominik Rosiek <58699848+sumo-drosiek@users.noreply.github.com>

* chore: bump sumologic terraform provider

Co-authored-by: Dominik Rosiek <58699848+sumo-drosiek@users.noreply.github.com>

Co-authored-by: Patryk Małek <pmalek@sumologic.com>
Co-authored-by: Dominik Rosiek <58699848+sumo-drosiek@users.noreply.github.com>
  • Loading branch information
3 people committed Feb 1, 2022
1 parent 7d449eb commit 626b7e2
Show file tree
Hide file tree
Showing 13 changed files with 54 additions and 20 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed

- chore: update the Telegraf image to 1.21.2 [#2036][#2036]
- [Backport release-v2.4] chore: bump sumologic terraform provider to v2.11.5 [#2066][#2066]

### Fixed

[Unreleased]: https://github.com/SumoLogic/sumologic-kubernetes-collection/compare/v2.4.0...main
[#2036]: https://github.com/SumoLogic/sumologic-kubernetes-collection/pull/2036
[#2066]: https://github.com/SumoLogic/sumologic-kubernetes-collection/pull/2066

## [v2.4.0][v2_4_0]

Expand Down
4 changes: 3 additions & 1 deletion deploy/helm/sumologic/conf/cleanup/cleanup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ export NO_PROXY=${NO_PROXY:=""}
cp /etc/terraform/*.tf /terraform/
cd /terraform || exit 1

terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade

# shellcheck disable=SC1083
terraform import sumologic_collector.collector {{ template "terraform.collector.name" . }}
Expand Down
2 changes: 1 addition & 1 deletion deploy/helm/sumologic/conf/setup/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ terraform {
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down
4 changes: 3 additions & 1 deletion deploy/helm/sumologic/conf/setup/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,9 @@ function should_create_fields() {
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1

terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade

# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/all_fields.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -343,7 +343,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/collector_fields.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -298,7 +298,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/conditional_sources.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -225,7 +225,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/custom.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -225,7 +225,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/default.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -296,7 +296,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -289,7 +289,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/strip_extrapolation.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -297,7 +297,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
6 changes: 4 additions & 2 deletions tests/helm/terraform/static/traces.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ data:
required_providers {
sumologic = {
source = "sumologic/sumologic"
version = "~> 2.8.0"
version = "~> 2.11"
}
kubernetes = {
source = "hashicorp/kubernetes"
Expand Down Expand Up @@ -233,7 +233,9 @@ data:
cp /etc/terraform/{locals,main,providers,resources,variables,fields}.tf /terraform/
cd /terraform || exit 1
terraform init
# Fall back to init -upgrade to prevent:
# Error: Inconsistent dependency lock file
terraform init -input=false -get=false || terraform init -input=false -upgrade
# Sumo Logic fields
if should_create_fields ; then
Expand Down
14 changes: 13 additions & 1 deletion tests/integration/internal/stepfuncs/helm.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@ package stepfuncs

import (
"context"
"fmt"
"os"
"path"
"testing"

"github.com/gruntwork-io/terratest/modules/helm"
"github.com/gruntwork-io/terratest/modules/k8s"
"github.com/stretchr/testify/require"
"sigs.k8s.io/e2e-framework/pkg/envconf"
"sigs.k8s.io/e2e-framework/pkg/features"
Expand Down Expand Up @@ -51,7 +53,17 @@ func HelmDependencyUpdateOpt(path string) features.Func {
func HelmInstallOpt(path string, releaseName string) features.Func {
return func(ctx context.Context, t *testing.T, envConf *envconf.Config) context.Context {
ctx = ctxopts.WithHelmRelease(ctx, releaseName)
helm.Install(t, ctxopts.HelmOptions(ctx), path, releaseName)

err := helm.InstallE(t, ctxopts.HelmOptions(ctx), path, releaseName)
if err != nil {
// Print setup job logs if installation failed.
k8s.RunKubectl(t, ctxopts.KubectlOptions(ctx),
"logs", fmt.Sprintf("-ljob-name=%s-sumologic-setup", releaseName),
)

require.NoError(t, err)
}

return ctx
}
}
Expand Down

0 comments on commit 626b7e2

Please sign in to comment.