Merge "Unifying proxy variables for tox and docker build"
This commit is contained in:
commit
4b6a947577
9
Makefile
9
Makefile
|
@ -19,6 +19,7 @@ IMAGE_NAME ?= armada
|
||||||
IMAGE_TAG ?= latest
|
IMAGE_TAG ?= latest
|
||||||
HELM ?= helm
|
HELM ?= helm
|
||||||
PROXY ?= http://proxy.foo.com:8000
|
PROXY ?= http://proxy.foo.com:8000
|
||||||
|
NO_PROXY ?= localhost,127.0.0.1,.svc.cluster.local
|
||||||
USE_PROXY ?= false
|
USE_PROXY ?= false
|
||||||
PUSH_IMAGE ?= false
|
PUSH_IMAGE ?= false
|
||||||
LABEL ?= commit-id
|
LABEL ?= commit-id
|
||||||
|
@ -102,7 +103,13 @@ build_docs:
|
||||||
.PHONY: build_armada
|
.PHONY: build_armada
|
||||||
build_armada:
|
build_armada:
|
||||||
ifeq ($(USE_PROXY), true)
|
ifeq ($(USE_PROXY), true)
|
||||||
docker build --network host -t $(IMAGE) --label $(LABEL) -f ./Dockerfile . --build-arg http_proxy=$(PROXY) --build-arg https_proxy=$(PROXY)
|
docker build --network host -t $(IMAGE) --label $(LABEL) -f ./Dockerfile \
|
||||||
|
--build-arg http_proxy=$(PROXY) \
|
||||||
|
--build-arg https_proxy=$(PROXY) \
|
||||||
|
--build-arg HTTP_PROXY=$(PROXY) \
|
||||||
|
--build-arg HTTPS_PROXY=$(PROXY) \
|
||||||
|
--build-arg no_proxy=$(NO_PROXY) \
|
||||||
|
--build-arg NO_PROXY=$(NO_PROXY) .
|
||||||
else
|
else
|
||||||
docker build --network host -t $(IMAGE) --label $(LABEL) -f ./Dockerfile .
|
docker build --network host -t $(IMAGE) --label $(LABEL) -f ./Dockerfile .
|
||||||
endif
|
endif
|
||||||
|
|
Loading…
Reference in New Issue