diff --git a/cmd/provider/accessanalyzer/zz_main.go b/cmd/provider/accessanalyzer/zz_main.go index 02deac5fde..84375f4091 100644 --- a/cmd/provider/accessanalyzer/zz_main.go +++ b/cmd/provider/accessanalyzer/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/account/zz_main.go b/cmd/provider/account/zz_main.go index 3af2dbdee4..bb9f1d39ba 100644 --- a/cmd/provider/account/zz_main.go +++ b/cmd/provider/account/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/acm/zz_main.go b/cmd/provider/acm/zz_main.go index 7a0fd10ce0..e49edf207d 100644 --- a/cmd/provider/acm/zz_main.go +++ b/cmd/provider/acm/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/acmpca/zz_main.go b/cmd/provider/acmpca/zz_main.go index 6962410e68..f80a44db79 100644 --- a/cmd/provider/acmpca/zz_main.go +++ b/cmd/provider/acmpca/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/amp/zz_main.go b/cmd/provider/amp/zz_main.go index ad846bc4c6..16854836c5 100644 --- a/cmd/provider/amp/zz_main.go +++ b/cmd/provider/amp/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/amplify/zz_main.go b/cmd/provider/amplify/zz_main.go index 7d6ce59137..85e4ffe0c5 100644 --- a/cmd/provider/amplify/zz_main.go +++ b/cmd/provider/amplify/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/apigateway/zz_main.go b/cmd/provider/apigateway/zz_main.go index f06a0daa1f..4fa5c69047 100644 --- a/cmd/provider/apigateway/zz_main.go +++ b/cmd/provider/apigateway/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/apigatewayv2/zz_main.go b/cmd/provider/apigatewayv2/zz_main.go index 5e53a78805..ebd11b7e23 100644 --- a/cmd/provider/apigatewayv2/zz_main.go +++ b/cmd/provider/apigatewayv2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appautoscaling/zz_main.go b/cmd/provider/appautoscaling/zz_main.go index 25813b218f..7d91f31c4c 100644 --- a/cmd/provider/appautoscaling/zz_main.go +++ b/cmd/provider/appautoscaling/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appconfig/zz_main.go b/cmd/provider/appconfig/zz_main.go index b470cdfd78..ff0509c69b 100644 --- a/cmd/provider/appconfig/zz_main.go +++ b/cmd/provider/appconfig/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appflow/zz_main.go b/cmd/provider/appflow/zz_main.go index b9adcde4ed..325f6e9c2c 100644 --- a/cmd/provider/appflow/zz_main.go +++ b/cmd/provider/appflow/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appintegrations/zz_main.go b/cmd/provider/appintegrations/zz_main.go index 5cfa3b3f66..78365a0207 100644 --- a/cmd/provider/appintegrations/zz_main.go +++ b/cmd/provider/appintegrations/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/applicationinsights/zz_main.go b/cmd/provider/applicationinsights/zz_main.go index 57c24f98e0..ee73fb23b4 100644 --- a/cmd/provider/applicationinsights/zz_main.go +++ b/cmd/provider/applicationinsights/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appmesh/zz_main.go b/cmd/provider/appmesh/zz_main.go index f3967c8895..fe2e92b628 100644 --- a/cmd/provider/appmesh/zz_main.go +++ b/cmd/provider/appmesh/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/apprunner/zz_main.go b/cmd/provider/apprunner/zz_main.go index 5ac3cb5f46..0192e1abb7 100644 --- a/cmd/provider/apprunner/zz_main.go +++ b/cmd/provider/apprunner/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appstream/zz_main.go b/cmd/provider/appstream/zz_main.go index a4c76a49c0..0ee919bc0e 100644 --- a/cmd/provider/appstream/zz_main.go +++ b/cmd/provider/appstream/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/appsync/zz_main.go b/cmd/provider/appsync/zz_main.go index 2d2890c9ce..90fdb61ebf 100644 --- a/cmd/provider/appsync/zz_main.go +++ b/cmd/provider/appsync/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/athena/zz_main.go b/cmd/provider/athena/zz_main.go index 9f18be33a6..98fd37eab7 100644 --- a/cmd/provider/athena/zz_main.go +++ b/cmd/provider/athena/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/autoscaling/zz_main.go b/cmd/provider/autoscaling/zz_main.go index 9a5f6b1f93..91fa78d32a 100644 --- a/cmd/provider/autoscaling/zz_main.go +++ b/cmd/provider/autoscaling/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/autoscalingplans/zz_main.go b/cmd/provider/autoscalingplans/zz_main.go index dfa6430bb0..6431788546 100644 --- a/cmd/provider/autoscalingplans/zz_main.go +++ b/cmd/provider/autoscalingplans/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/backup/zz_main.go b/cmd/provider/backup/zz_main.go index 1545c3c891..fcb48afa5a 100644 --- a/cmd/provider/backup/zz_main.go +++ b/cmd/provider/backup/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/batch/zz_main.go b/cmd/provider/batch/zz_main.go index cc3c00f65b..1bbeb24c14 100644 --- a/cmd/provider/batch/zz_main.go +++ b/cmd/provider/batch/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/budgets/zz_main.go b/cmd/provider/budgets/zz_main.go index eb73eb1278..f829919310 100644 --- a/cmd/provider/budgets/zz_main.go +++ b/cmd/provider/budgets/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ce/zz_main.go b/cmd/provider/ce/zz_main.go index 42bb29458f..f8bad2395e 100644 --- a/cmd/provider/ce/zz_main.go +++ b/cmd/provider/ce/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/chime/zz_main.go b/cmd/provider/chime/zz_main.go index 3f67d157d6..7b939024ef 100644 --- a/cmd/provider/chime/zz_main.go +++ b/cmd/provider/chime/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloud9/zz_main.go b/cmd/provider/cloud9/zz_main.go index d3260813f2..a4dbb883d3 100644 --- a/cmd/provider/cloud9/zz_main.go +++ b/cmd/provider/cloud9/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudcontrol/zz_main.go b/cmd/provider/cloudcontrol/zz_main.go index 1bd3eae11c..e8ac15e34b 100644 --- a/cmd/provider/cloudcontrol/zz_main.go +++ b/cmd/provider/cloudcontrol/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudformation/zz_main.go b/cmd/provider/cloudformation/zz_main.go index 86400d61fa..968540ba04 100644 --- a/cmd/provider/cloudformation/zz_main.go +++ b/cmd/provider/cloudformation/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudfront/zz_main.go b/cmd/provider/cloudfront/zz_main.go index e349c9b92b..bc33771e49 100644 --- a/cmd/provider/cloudfront/zz_main.go +++ b/cmd/provider/cloudfront/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudsearch/zz_main.go b/cmd/provider/cloudsearch/zz_main.go index b67b088509..4e1823ff43 100644 --- a/cmd/provider/cloudsearch/zz_main.go +++ b/cmd/provider/cloudsearch/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudtrail/zz_main.go b/cmd/provider/cloudtrail/zz_main.go index 250de2bcc0..81f20ea777 100644 --- a/cmd/provider/cloudtrail/zz_main.go +++ b/cmd/provider/cloudtrail/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudwatch/zz_main.go b/cmd/provider/cloudwatch/zz_main.go index 4321d773cf..5f659a0c68 100644 --- a/cmd/provider/cloudwatch/zz_main.go +++ b/cmd/provider/cloudwatch/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudwatchevents/zz_main.go b/cmd/provider/cloudwatchevents/zz_main.go index 072ea73ff3..80e1064099 100644 --- a/cmd/provider/cloudwatchevents/zz_main.go +++ b/cmd/provider/cloudwatchevents/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cloudwatchlogs/zz_main.go b/cmd/provider/cloudwatchlogs/zz_main.go index a832a8c727..f9245dfea8 100644 --- a/cmd/provider/cloudwatchlogs/zz_main.go +++ b/cmd/provider/cloudwatchlogs/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/codecommit/zz_main.go b/cmd/provider/codecommit/zz_main.go index ca44b81de2..06be89143b 100644 --- a/cmd/provider/codecommit/zz_main.go +++ b/cmd/provider/codecommit/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/codepipeline/zz_main.go b/cmd/provider/codepipeline/zz_main.go index 4a63db60d0..26dcf933b1 100644 --- a/cmd/provider/codepipeline/zz_main.go +++ b/cmd/provider/codepipeline/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/codestarconnections/zz_main.go b/cmd/provider/codestarconnections/zz_main.go index 8431b91de2..e27f99d7ea 100644 --- a/cmd/provider/codestarconnections/zz_main.go +++ b/cmd/provider/codestarconnections/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/codestarnotifications/zz_main.go b/cmd/provider/codestarnotifications/zz_main.go index 72ded7222f..736dc9ec46 100644 --- a/cmd/provider/codestarnotifications/zz_main.go +++ b/cmd/provider/codestarnotifications/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cognitoidentity/zz_main.go b/cmd/provider/cognitoidentity/zz_main.go index b62cff1b30..44f49131c9 100644 --- a/cmd/provider/cognitoidentity/zz_main.go +++ b/cmd/provider/cognitoidentity/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cognitoidp/zz_main.go b/cmd/provider/cognitoidp/zz_main.go index 939be52d7f..126528759f 100644 --- a/cmd/provider/cognitoidp/zz_main.go +++ b/cmd/provider/cognitoidp/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/config/zz_main.go b/cmd/provider/config/zz_main.go index c3f26492b3..1465549f30 100644 --- a/cmd/provider/config/zz_main.go +++ b/cmd/provider/config/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/configservice/zz_main.go b/cmd/provider/configservice/zz_main.go index 0fd7d13e08..9cf9502081 100644 --- a/cmd/provider/configservice/zz_main.go +++ b/cmd/provider/configservice/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/connect/zz_main.go b/cmd/provider/connect/zz_main.go index 47d46e2255..bb2aab1401 100644 --- a/cmd/provider/connect/zz_main.go +++ b/cmd/provider/connect/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/cur/zz_main.go b/cmd/provider/cur/zz_main.go index 79bef875be..b5615607fc 100644 --- a/cmd/provider/cur/zz_main.go +++ b/cmd/provider/cur/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/dataexchange/zz_main.go b/cmd/provider/dataexchange/zz_main.go index b26403a979..c8fab3d52b 100644 --- a/cmd/provider/dataexchange/zz_main.go +++ b/cmd/provider/dataexchange/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/datapipeline/zz_main.go b/cmd/provider/datapipeline/zz_main.go index eccc7f474a..3b35b5e393 100644 --- a/cmd/provider/datapipeline/zz_main.go +++ b/cmd/provider/datapipeline/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/datasync/zz_main.go b/cmd/provider/datasync/zz_main.go index 59b5ee283a..29f9cac04b 100644 --- a/cmd/provider/datasync/zz_main.go +++ b/cmd/provider/datasync/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/dax/zz_main.go b/cmd/provider/dax/zz_main.go index f00f7e999e..cc8fc336f5 100644 --- a/cmd/provider/dax/zz_main.go +++ b/cmd/provider/dax/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/deploy/zz_main.go b/cmd/provider/deploy/zz_main.go index 17a7e8468b..b2a00d3a5e 100644 --- a/cmd/provider/deploy/zz_main.go +++ b/cmd/provider/deploy/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/detective/zz_main.go b/cmd/provider/detective/zz_main.go index 1fbe6d60b5..d2c0ff03e4 100644 --- a/cmd/provider/detective/zz_main.go +++ b/cmd/provider/detective/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/devicefarm/zz_main.go b/cmd/provider/devicefarm/zz_main.go index dcdf998394..1792a10bf5 100644 --- a/cmd/provider/devicefarm/zz_main.go +++ b/cmd/provider/devicefarm/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/directconnect/zz_main.go b/cmd/provider/directconnect/zz_main.go index ceec2f7cb3..137ff67a2f 100644 --- a/cmd/provider/directconnect/zz_main.go +++ b/cmd/provider/directconnect/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/dlm/zz_main.go b/cmd/provider/dlm/zz_main.go index 6fd1ad19c5..d1a82a1b60 100644 --- a/cmd/provider/dlm/zz_main.go +++ b/cmd/provider/dlm/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/dms/zz_main.go b/cmd/provider/dms/zz_main.go index c475f61c53..f4ca041a3e 100644 --- a/cmd/provider/dms/zz_main.go +++ b/cmd/provider/dms/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/docdb/zz_main.go b/cmd/provider/docdb/zz_main.go index 9edc2c2823..641251d751 100644 --- a/cmd/provider/docdb/zz_main.go +++ b/cmd/provider/docdb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ds/zz_main.go b/cmd/provider/ds/zz_main.go index 6b5d0a7ec2..6a59beefdf 100644 --- a/cmd/provider/ds/zz_main.go +++ b/cmd/provider/ds/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/dynamodb/zz_main.go b/cmd/provider/dynamodb/zz_main.go index dbf7965d03..32fbed12e3 100644 --- a/cmd/provider/dynamodb/zz_main.go +++ b/cmd/provider/dynamodb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ec2/zz_main.go b/cmd/provider/ec2/zz_main.go index 03d80a253b..c69c532405 100644 --- a/cmd/provider/ec2/zz_main.go +++ b/cmd/provider/ec2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ecr/zz_main.go b/cmd/provider/ecr/zz_main.go index db29c347ae..2c3df889e7 100644 --- a/cmd/provider/ecr/zz_main.go +++ b/cmd/provider/ecr/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ecrpublic/zz_main.go b/cmd/provider/ecrpublic/zz_main.go index 2d5e805523..e198b5800f 100644 --- a/cmd/provider/ecrpublic/zz_main.go +++ b/cmd/provider/ecrpublic/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ecs/zz_main.go b/cmd/provider/ecs/zz_main.go index ead5e8cae8..946d82fef6 100644 --- a/cmd/provider/ecs/zz_main.go +++ b/cmd/provider/ecs/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/efs/zz_main.go b/cmd/provider/efs/zz_main.go index e056d8e7e8..a0e556f3d1 100644 --- a/cmd/provider/efs/zz_main.go +++ b/cmd/provider/efs/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/eks/zz_main.go b/cmd/provider/eks/zz_main.go index b81b6d45c4..1701da4b71 100644 --- a/cmd/provider/eks/zz_main.go +++ b/cmd/provider/eks/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elasticache/zz_main.go b/cmd/provider/elasticache/zz_main.go index bf44138baa..be2b003174 100644 --- a/cmd/provider/elasticache/zz_main.go +++ b/cmd/provider/elasticache/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elasticbeanstalk/zz_main.go b/cmd/provider/elasticbeanstalk/zz_main.go index 56aa8d9758..9db9fdc611 100644 --- a/cmd/provider/elasticbeanstalk/zz_main.go +++ b/cmd/provider/elasticbeanstalk/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elasticsearch/zz_main.go b/cmd/provider/elasticsearch/zz_main.go index c058578b25..c0cb7e148d 100644 --- a/cmd/provider/elasticsearch/zz_main.go +++ b/cmd/provider/elasticsearch/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elastictranscoder/zz_main.go b/cmd/provider/elastictranscoder/zz_main.go index 2f1293fd75..b87b5a50ee 100644 --- a/cmd/provider/elastictranscoder/zz_main.go +++ b/cmd/provider/elastictranscoder/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elb/zz_main.go b/cmd/provider/elb/zz_main.go index 5086501669..d602b7aba9 100644 --- a/cmd/provider/elb/zz_main.go +++ b/cmd/provider/elb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/elbv2/zz_main.go b/cmd/provider/elbv2/zz_main.go index 5fee77b67a..cc70e54f78 100644 --- a/cmd/provider/elbv2/zz_main.go +++ b/cmd/provider/elbv2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/emr/zz_main.go b/cmd/provider/emr/zz_main.go index cc3a0650da..711168ca38 100644 --- a/cmd/provider/emr/zz_main.go +++ b/cmd/provider/emr/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/emrserverless/zz_main.go b/cmd/provider/emrserverless/zz_main.go index 0858b44931..1f6c809e65 100644 --- a/cmd/provider/emrserverless/zz_main.go +++ b/cmd/provider/emrserverless/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/evidently/zz_main.go b/cmd/provider/evidently/zz_main.go index 18369c98c5..84dafbbfd9 100644 --- a/cmd/provider/evidently/zz_main.go +++ b/cmd/provider/evidently/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/firehose/zz_main.go b/cmd/provider/firehose/zz_main.go index d4a9c10f12..8b9d7786a5 100644 --- a/cmd/provider/firehose/zz_main.go +++ b/cmd/provider/firehose/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/fis/zz_main.go b/cmd/provider/fis/zz_main.go index cc399074b2..38ce733303 100644 --- a/cmd/provider/fis/zz_main.go +++ b/cmd/provider/fis/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/fsx/zz_main.go b/cmd/provider/fsx/zz_main.go index 84e0f6741d..714ffdb18d 100644 --- a/cmd/provider/fsx/zz_main.go +++ b/cmd/provider/fsx/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/gamelift/zz_main.go b/cmd/provider/gamelift/zz_main.go index b72152beb7..89acc335d1 100644 --- a/cmd/provider/gamelift/zz_main.go +++ b/cmd/provider/gamelift/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/glacier/zz_main.go b/cmd/provider/glacier/zz_main.go index 3771d989b6..96673ce091 100644 --- a/cmd/provider/glacier/zz_main.go +++ b/cmd/provider/glacier/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/globalaccelerator/zz_main.go b/cmd/provider/globalaccelerator/zz_main.go index 21e6a4c689..faabd638a0 100644 --- a/cmd/provider/globalaccelerator/zz_main.go +++ b/cmd/provider/globalaccelerator/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/glue/zz_main.go b/cmd/provider/glue/zz_main.go index f7073b93a0..2acee022a8 100644 --- a/cmd/provider/glue/zz_main.go +++ b/cmd/provider/glue/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/grafana/zz_main.go b/cmd/provider/grafana/zz_main.go index ce3816eadf..b1ed97c498 100644 --- a/cmd/provider/grafana/zz_main.go +++ b/cmd/provider/grafana/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/guardduty/zz_main.go b/cmd/provider/guardduty/zz_main.go index 571cf8c45e..bd422d7551 100644 --- a/cmd/provider/guardduty/zz_main.go +++ b/cmd/provider/guardduty/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/iam/zz_main.go b/cmd/provider/iam/zz_main.go index fb5d98034c..2168fd490b 100644 --- a/cmd/provider/iam/zz_main.go +++ b/cmd/provider/iam/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/identitystore/zz_main.go b/cmd/provider/identitystore/zz_main.go index d0f2a6e377..6adc65dfd1 100644 --- a/cmd/provider/identitystore/zz_main.go +++ b/cmd/provider/identitystore/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/imagebuilder/zz_main.go b/cmd/provider/imagebuilder/zz_main.go index e49b7f5e08..603435bb14 100644 --- a/cmd/provider/imagebuilder/zz_main.go +++ b/cmd/provider/imagebuilder/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/inspector/zz_main.go b/cmd/provider/inspector/zz_main.go index e9e7844904..4a5660d91f 100644 --- a/cmd/provider/inspector/zz_main.go +++ b/cmd/provider/inspector/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/inspector2/zz_main.go b/cmd/provider/inspector2/zz_main.go index f90335e493..e15ef819cb 100644 --- a/cmd/provider/inspector2/zz_main.go +++ b/cmd/provider/inspector2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/iot/zz_main.go b/cmd/provider/iot/zz_main.go index 5550d7d1f9..5f25ca42cb 100644 --- a/cmd/provider/iot/zz_main.go +++ b/cmd/provider/iot/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ivs/zz_main.go b/cmd/provider/ivs/zz_main.go index be5fa49cec..8c56d55092 100644 --- a/cmd/provider/ivs/zz_main.go +++ b/cmd/provider/ivs/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kafka/zz_main.go b/cmd/provider/kafka/zz_main.go index ef91477f81..daa741d36b 100644 --- a/cmd/provider/kafka/zz_main.go +++ b/cmd/provider/kafka/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kendra/zz_main.go b/cmd/provider/kendra/zz_main.go index ff234ecfe6..9de6e6312f 100644 --- a/cmd/provider/kendra/zz_main.go +++ b/cmd/provider/kendra/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/keyspaces/zz_main.go b/cmd/provider/keyspaces/zz_main.go index 2d874ff915..17dc875026 100644 --- a/cmd/provider/keyspaces/zz_main.go +++ b/cmd/provider/keyspaces/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kinesis/zz_main.go b/cmd/provider/kinesis/zz_main.go index 21e2239887..05a326fd24 100644 --- a/cmd/provider/kinesis/zz_main.go +++ b/cmd/provider/kinesis/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kinesisanalytics/zz_main.go b/cmd/provider/kinesisanalytics/zz_main.go index ff3ea0285c..2634e6feb3 100644 --- a/cmd/provider/kinesisanalytics/zz_main.go +++ b/cmd/provider/kinesisanalytics/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kinesisanalyticsv2/zz_main.go b/cmd/provider/kinesisanalyticsv2/zz_main.go index 9e1c747fa5..faa099bc96 100644 --- a/cmd/provider/kinesisanalyticsv2/zz_main.go +++ b/cmd/provider/kinesisanalyticsv2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kinesisvideo/zz_main.go b/cmd/provider/kinesisvideo/zz_main.go index dab3e51797..e56377891c 100644 --- a/cmd/provider/kinesisvideo/zz_main.go +++ b/cmd/provider/kinesisvideo/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/kms/zz_main.go b/cmd/provider/kms/zz_main.go index 195a79feae..c86061cb0e 100644 --- a/cmd/provider/kms/zz_main.go +++ b/cmd/provider/kms/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/lakeformation/zz_main.go b/cmd/provider/lakeformation/zz_main.go index ef2b01a1f4..607b615b64 100644 --- a/cmd/provider/lakeformation/zz_main.go +++ b/cmd/provider/lakeformation/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/lambda/zz_main.go b/cmd/provider/lambda/zz_main.go index 9ad0a67a2e..518136641e 100644 --- a/cmd/provider/lambda/zz_main.go +++ b/cmd/provider/lambda/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/lexmodels/zz_main.go b/cmd/provider/lexmodels/zz_main.go index 1f171b734e..08bb2345b9 100644 --- a/cmd/provider/lexmodels/zz_main.go +++ b/cmd/provider/lexmodels/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/licensemanager/zz_main.go b/cmd/provider/licensemanager/zz_main.go index da43d51afd..dcf032d483 100644 --- a/cmd/provider/licensemanager/zz_main.go +++ b/cmd/provider/licensemanager/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/lightsail/zz_main.go b/cmd/provider/lightsail/zz_main.go index 53392fc9b0..91b2bb5375 100644 --- a/cmd/provider/lightsail/zz_main.go +++ b/cmd/provider/lightsail/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/location/zz_main.go b/cmd/provider/location/zz_main.go index d046a2d2bf..afc570ebea 100644 --- a/cmd/provider/location/zz_main.go +++ b/cmd/provider/location/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/macie2/zz_main.go b/cmd/provider/macie2/zz_main.go index a87b028a75..92694b9fb6 100644 --- a/cmd/provider/macie2/zz_main.go +++ b/cmd/provider/macie2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/mediaconvert/zz_main.go b/cmd/provider/mediaconvert/zz_main.go index 0e32fd2884..5f1fbafa02 100644 --- a/cmd/provider/mediaconvert/zz_main.go +++ b/cmd/provider/mediaconvert/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/medialive/zz_main.go b/cmd/provider/medialive/zz_main.go index 88e9683439..ff5a7628c1 100644 --- a/cmd/provider/medialive/zz_main.go +++ b/cmd/provider/medialive/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/mediapackage/zz_main.go b/cmd/provider/mediapackage/zz_main.go index 0925d64530..fae72387a4 100644 --- a/cmd/provider/mediapackage/zz_main.go +++ b/cmd/provider/mediapackage/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/mediastore/zz_main.go b/cmd/provider/mediastore/zz_main.go index 1062af0e0d..70817e0203 100644 --- a/cmd/provider/mediastore/zz_main.go +++ b/cmd/provider/mediastore/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/memorydb/zz_main.go b/cmd/provider/memorydb/zz_main.go index ce875f39a1..7189680f1d 100644 --- a/cmd/provider/memorydb/zz_main.go +++ b/cmd/provider/memorydb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/monolith/zz_main.go b/cmd/provider/monolith/zz_main.go index 379b92e6f6..d582d1e3fc 100644 --- a/cmd/provider/monolith/zz_main.go +++ b/cmd/provider/monolith/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -154,7 +153,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/mq/zz_main.go b/cmd/provider/mq/zz_main.go index 1321ff71fc..0650f6053c 100644 --- a/cmd/provider/mq/zz_main.go +++ b/cmd/provider/mq/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/neptune/zz_main.go b/cmd/provider/neptune/zz_main.go index d319e34b84..fb8587956d 100644 --- a/cmd/provider/neptune/zz_main.go +++ b/cmd/provider/neptune/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/networkfirewall/zz_main.go b/cmd/provider/networkfirewall/zz_main.go index 771bd75b5c..0008981f89 100644 --- a/cmd/provider/networkfirewall/zz_main.go +++ b/cmd/provider/networkfirewall/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/networkmanager/zz_main.go b/cmd/provider/networkmanager/zz_main.go index febdfee893..00cc0ba768 100644 --- a/cmd/provider/networkmanager/zz_main.go +++ b/cmd/provider/networkmanager/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/opensearch/zz_main.go b/cmd/provider/opensearch/zz_main.go index f34b54b548..1fc17d82dc 100644 --- a/cmd/provider/opensearch/zz_main.go +++ b/cmd/provider/opensearch/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/opensearchserverless/zz_main.go b/cmd/provider/opensearchserverless/zz_main.go index e6ac3c2ad9..3b5ae62d57 100644 --- a/cmd/provider/opensearchserverless/zz_main.go +++ b/cmd/provider/opensearchserverless/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/opsworks/zz_main.go b/cmd/provider/opsworks/zz_main.go index 304e4d47a1..d0208df62b 100644 --- a/cmd/provider/opsworks/zz_main.go +++ b/cmd/provider/opsworks/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/organizations/zz_main.go b/cmd/provider/organizations/zz_main.go index 05218e1e1c..a2ad532faf 100644 --- a/cmd/provider/organizations/zz_main.go +++ b/cmd/provider/organizations/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/pinpoint/zz_main.go b/cmd/provider/pinpoint/zz_main.go index 5c312530cf..153fca87aa 100644 --- a/cmd/provider/pinpoint/zz_main.go +++ b/cmd/provider/pinpoint/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/qldb/zz_main.go b/cmd/provider/qldb/zz_main.go index a3b0be75d3..2cac58c411 100644 --- a/cmd/provider/qldb/zz_main.go +++ b/cmd/provider/qldb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/quicksight/zz_main.go b/cmd/provider/quicksight/zz_main.go index 03cad45c73..1994c82fb1 100644 --- a/cmd/provider/quicksight/zz_main.go +++ b/cmd/provider/quicksight/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ram/zz_main.go b/cmd/provider/ram/zz_main.go index 14c4357deb..85c03715d4 100644 --- a/cmd/provider/ram/zz_main.go +++ b/cmd/provider/ram/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/rds/zz_main.go b/cmd/provider/rds/zz_main.go index 3b65e9c83f..c97c88f3da 100644 --- a/cmd/provider/rds/zz_main.go +++ b/cmd/provider/rds/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/redshift/zz_main.go b/cmd/provider/redshift/zz_main.go index 2e8aec5e07..2917b70424 100644 --- a/cmd/provider/redshift/zz_main.go +++ b/cmd/provider/redshift/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/redshiftserverless/zz_main.go b/cmd/provider/redshiftserverless/zz_main.go index 0b6b0d981f..18835c3331 100644 --- a/cmd/provider/redshiftserverless/zz_main.go +++ b/cmd/provider/redshiftserverless/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/resourcegroups/zz_main.go b/cmd/provider/resourcegroups/zz_main.go index 24da18af95..88b37ed526 100644 --- a/cmd/provider/resourcegroups/zz_main.go +++ b/cmd/provider/resourcegroups/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/rolesanywhere/zz_main.go b/cmd/provider/rolesanywhere/zz_main.go index 392297ec39..fc62167f4b 100644 --- a/cmd/provider/rolesanywhere/zz_main.go +++ b/cmd/provider/rolesanywhere/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/route53/zz_main.go b/cmd/provider/route53/zz_main.go index b3a2d066a1..9a34291614 100644 --- a/cmd/provider/route53/zz_main.go +++ b/cmd/provider/route53/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/route53recoverycontrolconfig/zz_main.go b/cmd/provider/route53recoverycontrolconfig/zz_main.go index 838f35d7c4..383559305f 100644 --- a/cmd/provider/route53recoverycontrolconfig/zz_main.go +++ b/cmd/provider/route53recoverycontrolconfig/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/route53recoveryreadiness/zz_main.go b/cmd/provider/route53recoveryreadiness/zz_main.go index 9e9adcc5fb..1f3daea841 100644 --- a/cmd/provider/route53recoveryreadiness/zz_main.go +++ b/cmd/provider/route53recoveryreadiness/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/route53resolver/zz_main.go b/cmd/provider/route53resolver/zz_main.go index 34cabf7a75..a4cf41b6d4 100644 --- a/cmd/provider/route53resolver/zz_main.go +++ b/cmd/provider/route53resolver/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/rum/zz_main.go b/cmd/provider/rum/zz_main.go index 3575e89f88..310f8d6426 100644 --- a/cmd/provider/rum/zz_main.go +++ b/cmd/provider/rum/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/s3/zz_main.go b/cmd/provider/s3/zz_main.go index 17193eaac7..d5507d585a 100644 --- a/cmd/provider/s3/zz_main.go +++ b/cmd/provider/s3/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/s3control/zz_main.go b/cmd/provider/s3control/zz_main.go index 51ba97c2ae..0f4109fcfe 100644 --- a/cmd/provider/s3control/zz_main.go +++ b/cmd/provider/s3control/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/sagemaker/zz_main.go b/cmd/provider/sagemaker/zz_main.go index 7d69cf69ae..c7c6148a02 100644 --- a/cmd/provider/sagemaker/zz_main.go +++ b/cmd/provider/sagemaker/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/scheduler/zz_main.go b/cmd/provider/scheduler/zz_main.go index 2535dc9994..707d8dd056 100644 --- a/cmd/provider/scheduler/zz_main.go +++ b/cmd/provider/scheduler/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/schemas/zz_main.go b/cmd/provider/schemas/zz_main.go index 23eb3efa30..5768155556 100644 --- a/cmd/provider/schemas/zz_main.go +++ b/cmd/provider/schemas/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/secretsmanager/zz_main.go b/cmd/provider/secretsmanager/zz_main.go index 92a3aedac7..11c3ffe611 100644 --- a/cmd/provider/secretsmanager/zz_main.go +++ b/cmd/provider/secretsmanager/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/securityhub/zz_main.go b/cmd/provider/securityhub/zz_main.go index 83e3371803..7d855a19dc 100644 --- a/cmd/provider/securityhub/zz_main.go +++ b/cmd/provider/securityhub/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/serverlessrepo/zz_main.go b/cmd/provider/serverlessrepo/zz_main.go index 15e3bec2e6..ca8ad2f030 100644 --- a/cmd/provider/serverlessrepo/zz_main.go +++ b/cmd/provider/serverlessrepo/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/servicecatalog/zz_main.go b/cmd/provider/servicecatalog/zz_main.go index 1e80567d07..7acb4ab7f8 100644 --- a/cmd/provider/servicecatalog/zz_main.go +++ b/cmd/provider/servicecatalog/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/servicediscovery/zz_main.go b/cmd/provider/servicediscovery/zz_main.go index 51bc4a2255..fc90a39eda 100644 --- a/cmd/provider/servicediscovery/zz_main.go +++ b/cmd/provider/servicediscovery/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/servicequotas/zz_main.go b/cmd/provider/servicequotas/zz_main.go index 3184b6610f..21b9f2ed74 100644 --- a/cmd/provider/servicequotas/zz_main.go +++ b/cmd/provider/servicequotas/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ses/zz_main.go b/cmd/provider/ses/zz_main.go index f1a0a67e0d..c57aecbe49 100644 --- a/cmd/provider/ses/zz_main.go +++ b/cmd/provider/ses/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/sesv2/zz_main.go b/cmd/provider/sesv2/zz_main.go index 2e71d7206b..7bb7612ed0 100644 --- a/cmd/provider/sesv2/zz_main.go +++ b/cmd/provider/sesv2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/sfn/zz_main.go b/cmd/provider/sfn/zz_main.go index c42f6885cb..1295eedd55 100644 --- a/cmd/provider/sfn/zz_main.go +++ b/cmd/provider/sfn/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/signer/zz_main.go b/cmd/provider/signer/zz_main.go index ea52aef9a2..1453109bb7 100644 --- a/cmd/provider/signer/zz_main.go +++ b/cmd/provider/signer/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/simpledb/zz_main.go b/cmd/provider/simpledb/zz_main.go index b9ba9b6d5e..2db70a1e63 100644 --- a/cmd/provider/simpledb/zz_main.go +++ b/cmd/provider/simpledb/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/sns/zz_main.go b/cmd/provider/sns/zz_main.go index 557da8718a..199c2f5095 100644 --- a/cmd/provider/sns/zz_main.go +++ b/cmd/provider/sns/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/sqs/zz_main.go b/cmd/provider/sqs/zz_main.go index 60e53635f4..eb7d60e35a 100644 --- a/cmd/provider/sqs/zz_main.go +++ b/cmd/provider/sqs/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ssm/zz_main.go b/cmd/provider/ssm/zz_main.go index 7484ca37a1..ee7c6c7d87 100644 --- a/cmd/provider/ssm/zz_main.go +++ b/cmd/provider/ssm/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/ssoadmin/zz_main.go b/cmd/provider/ssoadmin/zz_main.go index d5f79c943b..2c81594ad6 100644 --- a/cmd/provider/ssoadmin/zz_main.go +++ b/cmd/provider/ssoadmin/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/swf/zz_main.go b/cmd/provider/swf/zz_main.go index d58b923d95..6b168f21e6 100644 --- a/cmd/provider/swf/zz_main.go +++ b/cmd/provider/swf/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/timestreamwrite/zz_main.go b/cmd/provider/timestreamwrite/zz_main.go index 6616cf269e..06f378fab0 100644 --- a/cmd/provider/timestreamwrite/zz_main.go +++ b/cmd/provider/timestreamwrite/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/transcribe/zz_main.go b/cmd/provider/transcribe/zz_main.go index 9a9fa86e87..64319a0088 100644 --- a/cmd/provider/transcribe/zz_main.go +++ b/cmd/provider/transcribe/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/transfer/zz_main.go b/cmd/provider/transfer/zz_main.go index 4cce0b18a6..4502a9c093 100644 --- a/cmd/provider/transfer/zz_main.go +++ b/cmd/provider/transfer/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/vpc/zz_main.go b/cmd/provider/vpc/zz_main.go index 6451f726ff..2021f71c57 100644 --- a/cmd/provider/vpc/zz_main.go +++ b/cmd/provider/vpc/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/waf/zz_main.go b/cmd/provider/waf/zz_main.go index fcc6fdb305..29b0aebf11 100644 --- a/cmd/provider/waf/zz_main.go +++ b/cmd/provider/waf/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/wafregional/zz_main.go b/cmd/provider/wafregional/zz_main.go index 3d79385601..934af6b3c6 100644 --- a/cmd/provider/wafregional/zz_main.go +++ b/cmd/provider/wafregional/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/wafv2/zz_main.go b/cmd/provider/wafv2/zz_main.go index 064da51c04..2e51790e41 100644 --- a/cmd/provider/wafv2/zz_main.go +++ b/cmd/provider/wafv2/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/workspaces/zz_main.go b/cmd/provider/workspaces/zz_main.go index d36dc50b9d..fd41f66911 100644 --- a/cmd/provider/workspaces/zz_main.go +++ b/cmd/provider/workspaces/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/cmd/provider/xray/zz_main.go b/cmd/provider/xray/zz_main.go index e0bc9773ea..e14194a390 100644 --- a/cmd/provider/xray/zz_main.go +++ b/cmd/provider/xray/zz_main.go @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -149,7 +148,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/hack/main.go.tmpl b/hack/main.go.tmpl index 29dc60db6f..1ba49697d9 100644 --- a/hack/main.go.tmpl +++ b/hack/main.go.tmpl @@ -84,7 +84,6 @@ func main() { _ = app.Flag("terraform-native-provider-path", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform native provider path for shared execution.").Envar("TERRAFORM_NATIVE_PROVIDER_PATH").Hidden().Action(deprecationAction("terraform-native-provider-path")).String() _ = app.Flag("terraform-provider-source", "[DEPRECATED: This option is no longer used and it will be removed in a future release.] Terraform provider source.").Envar("TERRAFORM_PROVIDER_SOURCE").Hidden().Action(deprecationAction("terraform-provider-source")).String() ) - setupConfig := &clients.SetupConfig{} kingpin.MustParse(app.Parse(os.Args[1:])) log.Default().SetOutput(io.Discard) ctrl.SetLogger(zap.New(zap.WriteTo(io.Discard))) @@ -154,7 +153,10 @@ func main() { ctx := context.Background() provider, err := config.GetProvider(ctx, false) kingpin.FatalIfError(err, "Cannot initialize the provider configuration") - setupConfig.TerraformProvider = provider.TerraformProvider + setupConfig := &clients.SetupConfig{ + Logger: logr, + TerraformProvider: provider.TerraformProvider, + } o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: logr, diff --git a/internal/clients/aws.go b/internal/clients/aws.go index c8ea8e73eb..26825b443b 100644 --- a/internal/clients/aws.go +++ b/internal/clients/aws.go @@ -10,8 +10,10 @@ import ( "github.com/aws/aws-sdk-go-v2/aws" awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" "github.com/aws/aws-sdk-go-v2/feature/ec2/imds" + "github.com/aws/aws-sdk-go-v2/service/sts" awsrequest "github.com/aws/aws-sdk-go/aws/request" "github.com/aws/smithy-go/middleware" + "github.com/crossplane/crossplane-runtime/pkg/logging" "github.com/crossplane/crossplane-runtime/pkg/resource" "github.com/crossplane/upjet/pkg/metrics" "github.com/crossplane/upjet/pkg/terraform" @@ -26,15 +28,18 @@ import ( ) const ( - keyAccountID = "account_id" - keyRegion = "region" + keyAccountID = "account_id" + keyRegion = "region" + localstackAccountID = "000000000" ) type SetupConfig struct { TerraformProvider *schema.Provider + Logger logging.Logger } func SelectTerraformSetup(config *SetupConfig) terraform.SetupFn { // nolint:gocyclo + credsCache := NewAWSCredentialsProviderCache(WithCacheLogger(config.Logger)) return func(ctx context.Context, c client.Client, mg resource.Managed) (terraform.Setup, error) { pc := &v1beta1.ProviderConfig{} if err := c.Get(ctx, types.NamespacedName{Name: mg.GetProviderConfigReference().Name}, pc); err != nil { @@ -52,20 +57,42 @@ func SelectTerraformSetup(config *SetupConfig) terraform.SetupFn { // nolint:goc } else if awsCfg == nil { return terraform.Setup{}, errors.Wrap(err, "obtained aws config cannot be nil") } - creds, err := awsCfg.Credentials.Retrieve(ctx) + + // only IRSA auth credentials are currently cached, other auth methods + // will skip the cache and call the downstream + // CredentialsProvider.Retrieve(). + credCache, err := credsCache.RetrieveCredentials(ctx, pc, awsCfg.Region, awsCfg.Credentials, func(ctx context.Context) (string, error) { + if pc.Spec.SkipCredsValidation { + // then we do not try to resolve the account ID and instead, + // return a constant value as before. + return localstackAccountID, nil + } + o, err := sts.NewFromConfig(*awsCfg).GetCallerIdentity(ctx, &sts.GetCallerIdentityInput{}) + if err != nil { + return "", errors.Wrap(err, errGetCallerIdentityFailed) + } + return *o.Account, nil + }) if err != nil { - return terraform.Setup{}, errors.Wrap(err, "failed to retrieve aws credentials from aws config") + return terraform.Setup{}, errors.Wrap(err, "cache manager failure") } - account := "000000000" - if !pc.Spec.SkipCredsValidation { - account, err = getAccountId(ctx, awsCfg, creds) + // if we are to retrieve the AWS account ID and if we have not already + // retrieved it via the credential cache, then we will utilize the + // identity cache. + // TODO: Replace the identity cache with the credential cache. + if !pc.Spec.SkipCredsValidation && credCache.accountID == "" { + credCache.accountID, err = getAccountId(ctx, awsCfg, credCache.creds) if err != nil { return terraform.Setup{}, errors.Wrap(err, "cannot get account id") } } + // just in case the localstack implementation relies on this... + if credCache.accountID == "" { + credCache.accountID = localstackAccountID + } ps.ClientMetadata = map[string]string{ - keyAccountID: account, + keyAccountID: credCache.accountID, } // several external name configs depend on the setup.Configuration for templating region ps.Configuration = map[string]any{ @@ -74,7 +101,7 @@ func SelectTerraformSetup(config *SetupConfig) terraform.SetupFn { // nolint:goc if config.TerraformProvider == nil { return terraform.Setup{}, errors.New("terraform provider cannot be nil") } - return ps, errors.Wrap(configureNoForkAWSClient(ctx, &ps, config, awsCfg.Region, creds, pc), "could not configure the no-fork AWS client") + return ps, errors.Wrap(configureNoForkAWSClient(ctx, &ps, config, awsCfg.Region, credCache.creds, pc), "could not configure the no-fork AWS client") } } diff --git a/internal/clients/creds_cache.go b/internal/clients/creds_cache.go new file mode 100644 index 0000000000..c38a3fa42a --- /dev/null +++ b/internal/clients/creds_cache.go @@ -0,0 +1,276 @@ +// SPDX-FileCopyrightText: 2024 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + +package clients + +import ( + "context" + "crypto/sha256" + "fmt" + "io" + "os" + "path/filepath" + "strings" + "sync" + "sync/atomic" + "time" + + "github.com/aws/aws-sdk-go-v2/aws" + "github.com/crossplane/crossplane-runtime/pkg/logging" + "github.com/pkg/errors" + + "github.com/upbound/provider-aws/apis/v1beta1" +) + +const ( + errGetAccountID = "cannot retrieve the AWS account ID" +) + +// AWSCredentialsProviderCacheOption lets you configure +// a *GlobalAWSCredentialsProviderCache. +type AWSCredentialsProviderCacheOption func(cache *AWSCredentialsProviderCache) + +// WithCacheMaxSize lets you override the default MaxSize for +// AWS CredentialsProvider cache. +func WithCacheMaxSize(n int) AWSCredentialsProviderCacheOption { + return func(c *AWSCredentialsProviderCache) { + c.maxSize = n + } +} + +// WithCacheStore lets you bootstrap AWS CredentialsProvider Cache with +// your own cache. +func WithCacheStore(cache map[string]*awsCredentialsProviderCacheEntry) AWSCredentialsProviderCacheOption { + return func(c *AWSCredentialsProviderCache) { + c.cache = cache + } +} + +// WithCacheLogger lets you configure the logger for the cache. +func WithCacheLogger(l logging.Logger) AWSCredentialsProviderCacheOption { + return func(c *AWSCredentialsProviderCache) { + c.logger = l + } +} + +// NewAWSCredentialsProviderCache returns a new empty +// *AWSCredentialsProviderCache with the default GetAWSConfig method. +func NewAWSCredentialsProviderCache(opts ...AWSCredentialsProviderCacheOption) *AWSCredentialsProviderCache { + c := &AWSCredentialsProviderCache{ + cache: map[string]*awsCredentialsProviderCacheEntry{}, + maxSize: 100, + mu: &sync.RWMutex{}, + logger: logging.NewNopLogger(), + } + for _, f := range opts { + f(c) + } + return c +} + +// AWSCredentialsProviderCache holds aws.CredentialsProvider objects in memory +// so that we don't need to make API calls to AWS in every reconciliation of +// +// every resource. It has a maximum size that when it's reached, the entry +// that has the oldest access time will be removed from the cache, +// i.e. FIFO on last access time. +// +// Note that there is no need to invalidate the values in the cache because +// they never change, so we don't need concurrency-safety to prevent access +// to an invalidated entry. +type AWSCredentialsProviderCache struct { + // cache holds the AWS Config with a unique cache key per + // provider configuration. Key content includes the ProviderConfig's UUID + // and ResourceVersion and additional fields depending on the auth method + // (currently only IRSA temporary credential caching is supported). + cache map[string]*awsCredentialsProviderCacheEntry + + // maxSize is the maximum number of elements this cache can ever have. + maxSize int + + // mu is used to make sure the cache map is concurrency-safe. + mu *sync.RWMutex + + // logger is the logger for cache operations. + logger logging.Logger +} + +type awsCredentialsProviderCacheEntry struct { + awsCredCache *aws.CredentialsCache + accessedAt atomic.Value + accountID atomic.Value +} + +// AccountIDFn is a function for retrieving the account ID. +type AccountIDFn func(ctx context.Context) (string, error) + +func accountIDFromCacheEntry(e *awsCredentialsProviderCacheEntry) AccountIDFn { + return func(context.Context) (string, error) { + // return the cached account ID + return e.accountID.Load().(string), nil + } +} + +// Credentials holds the aws.Credentials and the associated AWS account ID for +// these credentials. It's possible that the account ID is not resolved and +// only the aws.Credentials are available in a successful result. +type Credentials struct { + creds aws.Credentials + accountID string +} + +// newCredentials returns the Credentials whose credentials are retrieved +// using the given aws.CredentialsProvider and whose account ID is set using +// the given AccountIDFn. +func newCredentials(ctx context.Context, credsProvider aws.CredentialsProvider, accountIDFn AccountIDFn) (Credentials, error) { + var result Credentials + // try to retrieve the credentials if a retriever has been supplied + if credsProvider != nil { + var err error + if result.creds, err = credsProvider.Retrieve(ctx); err != nil { + return Credentials{}, errors.Wrap(err, "cannot retrieve the AWS credentials") + } + } + // try to get the account ID + if accountIDFn != nil { + var err error + if result.accountID, err = accountIDFn(ctx); err != nil { + return Credentials{}, errors.Wrap(err, errGetAccountID) + } + } + return result, nil +} + +// RetrieveCredentials returns a Credentials either from the credential cache. +// If the authentication scheme is IRSA and the supplied +// aws.CredentialsProvider implementation is an aws.CredentialsCache, then the +// retrieved credentials and the account ID are cached for future requests. +// Otherwise, this function returns the AWS credentials by calling +// the downstream aws.CredentialsProvider.Retrieve, and for now, does *not* +// call the given AccountIDFn because in that case, a separate identity cache +// should be used to retrieve the caller identity. +func (c *AWSCredentialsProviderCache) RetrieveCredentials(ctx context.Context, pc *v1beta1.ProviderConfig, region string, credsProvider aws.CredentialsProvider, accountIDFn AccountIDFn) (Credentials, error) { + // Only IRSA credentials are cached currently and + // only aws.CredentialsCache is supported as the underlying + // credential provider. + awsCredsCache, ok := credsProvider.(*aws.CredentialsCache) + if !ok { + c.logger.Debug("Configured aws.CredentialsProvider is not an aws.CredentialsCache, cannot utilize the provider credential cache...") + } + if pc.Spec.Credentials.Source != authKeyIRSA || !ok { + // if this cache manager is not going to be employed, do not call + // the given accountIDFn because there's a separate identity cache + // implementation. + // TODO: Replace the identity cache with this cache. + return newCredentials(ctx, credsProvider, nil) + } + // cache key calculation tries to capture any parameter that + // could cause changes in the resulting AWS credentials, + // to ensure unique keys. + // + // Parameters that are directly available in the provider config will + // generate unique cache keys through UUID and ResourceVersion of + // the ProviderConfig's k8s object, as they change when the provider + // config is modified. + // + // Any other external parameter that have an effect on the resulting + // credentials and does not appear in the ProviderConfig directly + // (i.e. the same provider config content produces a different config), + // should be included in the cache key. + cacheKeyParams := []string{ + string(pc.UID), + pc.ResourceVersion, + region, + string(pc.Spec.Credentials.Source), + } + tokenHash, err := hashTokenFile(os.Getenv("AWS_WEB_IDENTITY_TOKEN_FILE")) + if err != nil { + return Credentials{}, errors.Wrap(err, "cannot calculate the hash for the credentials file") + } + cacheKeyParams = append(cacheKeyParams, tokenHash, os.Getenv("AWS_WEB_IDENTITY_TOKEN_FILE"), os.Getenv("AWS_ROLE_ARN")) + cacheKey := strings.Join(cacheKeyParams, ":") + c.logger.Debug("Checking cache entry", "cacheKey", cacheKey, "pc", pc.GroupVersionKind().String()) + c.mu.RLock() + cacheEntry, ok := c.cache[cacheKey] + c.mu.RUnlock() + + // TODO: consider implementing a TTL even though the cached entry is valid + // cache hit + if ok { + c.logger.Debug("Cache hit", "cacheKey", cacheKey, "pc", pc.GroupVersionKind().String()) + // since this is a hot-path in the execution, do not always update + // the last access times, it is fine to evict the LRU entry on a less + // granular precision. + if time.Since(cacheEntry.accessedAt.Load().(time.Time)) > 10*time.Minute { + cacheEntry.accessedAt.Store(time.Now()) + } + return newCredentials(ctx, cacheEntry.awsCredCache, accountIDFromCacheEntry(cacheEntry)) + } + + c.mu.Lock() + defer c.mu.Unlock() + // we need to recheck the cache because it might have already been + // populated. + cacheEntry, ok = c.cache[cacheKey] + if !ok { + // cache miss + c.logger.Debug("Cache miss", "cacheKey", cacheKey, "pc", pc.GroupVersionKind().String(), "cacheSize", len(c.cache)) + c.makeRoom() + cacheEntry = &awsCredentialsProviderCacheEntry{ + awsCredCache: awsCredsCache, + } + id, err := accountIDFn(ctx) + if err != nil { + return Credentials{}, errors.Wrap(err, errGetAccountID) + } + cacheEntry.accountID.Store(id) + cacheEntry.accessedAt.Store(time.Now()) + c.cache[cacheKey] = cacheEntry + } + return newCredentials(ctx, cacheEntry.awsCredCache, accountIDFromCacheEntry(cacheEntry)) +} + +// makeRoom ensures that there is at most maxSize-1 elements in the cache map +// so that a new entry can be added. It deletes the object that +// was last accessed before all others. +// This implementation is not thread safe. Callers must properly synchronize. +func (c *AWSCredentialsProviderCache) makeRoom() { + if 1+len(c.cache) <= c.maxSize { + return + } + var dustiest string + for key, val := range c.cache { + if dustiest == "" { + dustiest = key + continue + } + if val.accessedAt.Load().(time.Time).Before(c.cache[dustiest].accessedAt.Load().(time.Time)) { + dustiest = key + } + } + delete(c.cache, dustiest) +} + +// hashTokenFile calculates the sha256 checksum of the token file content at +// the supplied file path +func hashTokenFile(filename string) (string, error) { + if filename == "" { + return "", errors.New("token file name cannot be empty") + } + file, err := os.Open(filepath.Clean(filename)) + if err != nil { + return "", err + } + defer func() { + _ = file.Close() + }() + + hash := sha256.New() + if _, err = io.Copy(hash, file); err != nil { + return "", err + } + + checksum := hash.Sum(nil) + return fmt.Sprintf("%x", checksum), nil +}