builds: fix "Killed" error with make dev (#15003)

Previously, I would sometimes get Killed errors when executing the
binary created by `make dev`. This is because we were using `cp`
and OSX has a bug where it caches the old signature and so doesn't
allow the new binary to run (see https://apple.stackexchange.com/a/428388)
pull/15096/head
Luke Kysow 2 years ago committed by GitHub
parent d1868bbfd0
commit 44c9c9b05d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -149,7 +149,9 @@ dev: dev-build
dev-build:
mkdir -p bin
CGO_ENABLED=0 go install -ldflags "$(GOLDFLAGS)" -tags "$(GOTAGS)"
cp -f ${MAIN_GOPATH}/bin/consul ./bin/consul
# rm needed due to signature caching (https://apple.stackexchange.com/a/428388)
rm -f ./bin/consul
cp ${MAIN_GOPATH}/bin/consul ./bin/consul
dev-docker: linux
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"

Loading…
Cancel
Save