From b0728c96d3399e4e8acf214cb1f8bdc60ef2bc7f Mon Sep 17 00:00:00 2001 From: Kohei Tokunaga Date: Wed, 1 Mar 2023 15:49:07 +0900 Subject: [PATCH] controller: use os.Executable() for getting the exceutable path Signed-off-by: Kohei Tokunaga --- controller/remote/controller.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controller/remote/controller.go b/controller/remote/controller.go index 97508992..81e69820 100644 --- a/controller/remote/controller.go +++ b/controller/remote/controller.go @@ -297,7 +297,7 @@ func (c *buildxController) Kill(ctx context.Context) error { func launch(ctx context.Context, logFile string, args ...string) (func() error, error) { // set absolute path of binary, since we set the working directory to the root - pathname, err := filepath.Abs(os.Args[0]) + pathname, err := os.Executable() if err != nil { return nil, err }