From bb32ef83f7a044a1528cd21730b0a69587f8e95f Mon Sep 17 00:00:00 2001 From: Markus Lehtonen Date: Fri, 2 Feb 2018 11:31:07 +0200 Subject: [PATCH] Export proxy env vars inside docker build Without correct proxy settings propagated to docker build it is not possible to build node-feature-discovery from behind a proxy server, e.g. in corporate networks. This patch fixes the issue by exporting all http(s) proxy related environment variables as build-time variables. --- Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Makefile b/Makefile index aa2618ad7..1ce316179 100644 --- a/Makefile +++ b/Makefile @@ -12,4 +12,10 @@ all: docker # QUAY_REGISTRY_USER= make docker -e. docker: docker build --build-arg NFD_VERSION=$(VERSION) \ + --build-arg http_proxy=$(http_proxy) \ + --build-arg HTTP_PROXY=$(HTTP_PROXY) \ + --build-arg https_proxy=$(https_proxy) \ + --build-arg HTTPS_PROXY=$(HTTPS_PROXY) \ + --build-arg no_proxy=$(no_proxy) \ + --build-arg NO_PROXY=$(NO_PROXY) \ -t $(QUAY_DOMAIN_NAME)/$(QUAY_REGISTRY_USER)/$(DOCKER_IMAGE_NAME):$(VERSION) ./