From c52500da73ee83d1908f8975f7dedfb7fa1b60f3 Mon Sep 17 00:00:00 2001 From: Kenneth Jenkins <51246568+kenjenkins@users.noreply.github.com> Date: Fri, 20 Sep 2024 10:54:07 -0700 Subject: [PATCH] Makefile: unset GOOS for get-envoy target (#5300) The build-dev-docker.sh script will run env GOOS=linux make build to build Pomerium for Linux (before copying this binary into a minimal Docker image). However, now that the get-envoy target is implemented using a Go command, it too will be affected by GOOS. As a result running this step on macOS will result in an error when trying to execute a Linux get-envoy binary. Instead, let's unset GOOS when running the get-envoy command, so that it defaults to building for the host OS. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 54a8d06d8..7fdcf8c66 100644 --- a/Makefile +++ b/Makefile @@ -40,7 +40,7 @@ all: clean build-deps test lint build ## Runs a clean, build, fmt, lint, test, a .PHONY: get-envoy get-envoy: ## Fetch envoy binaries @echo "==> $@" - @cd pkg/envoy/files && go run ../get-envoy + @cd pkg/envoy/files && env -u GOOS go run ../get-envoy .PHONY: deps-build deps-build: get-envoy ## Install build dependencies