From add71232779c173e167a60b8f0b2bccd673d73bd Mon Sep 17 00:00:00 2001 From: Denis Bilenko Date: Fri, 24 Jan 2025 19:29:26 +0100 Subject: [PATCH] sort keys in debug output in terraform mutator --- bundle/deploy/terraform/init.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bundle/deploy/terraform/init.go b/bundle/deploy/terraform/init.go index 5957611a4..8432c8017 100644 --- a/bundle/deploy/terraform/init.go +++ b/bundle/deploy/terraform/init.go @@ -9,6 +9,7 @@ import ( "os/exec" "path/filepath" "runtime" + "sort" "strings" "time" @@ -301,7 +302,9 @@ func (m *initialize) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnosti } // Configure environment variables for auth for Terraform to use. - log.Debugf(ctx, "Environment variables for Terraform: %s", strings.Join(maps.Keys(environ), ", ")) + keys := maps.Keys(environ) + sort.Strings(keys) + log.Debugf(ctx, "Environment variables for Terraform: %s", strings.Join(keys, ", ")) err = tf.SetEnv(environ) if err != nil { return diag.FromErr(err)