From 488637f8bddcf76ef41f6680bc7ddfabee800a45 Mon Sep 17 00:00:00 2001 From: panic Date: Mon, 4 Sep 2023 12:08:46 +0300 Subject: [PATCH] Replace unix-specific /tmp path with os.TempDir Signed-off-by: panic --- pkg/provider/provider.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkg/provider/provider.go b/pkg/provider/provider.go index eff19b1..2ff9bd6 100644 --- a/pkg/provider/provider.go +++ b/pkg/provider/provider.go @@ -1,6 +1,9 @@ package provider import ( + "os" + "path/filepath" + "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/terraform" "github.com/vmware-tanzu/terraform-provider-carvel/pkg/kapp" @@ -11,7 +14,7 @@ import ( ) func Provider() terraform.ResourceProvider { - logger := logger.MustNewFileRoot("/tmp/terraform-provider-carvel.log") + logger := logger.MustNewFileRoot(filepath.Join(os.TempDir(), "terraform-provider-carvel.log")) yttLogger := logger.WithLabel("ytt") kbldLogger := logger.WithLabel("kbld")