mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-01-31 08:25:36 +00:00
Carry in the no_proxy env var in as well. critical to exclude internal
servers which do not need proxy server to access.
This commit is contained in:
parent
e5513c0635
commit
572b43a696
8
Makefile
8
Makefile
@ -6,9 +6,14 @@ ifdef https_proxy
|
||||
DOCKER_HTTPS_PROXY=--build-arg https_proxy=$(https_proxy)
|
||||
endif
|
||||
|
||||
ifdef no_proxy
|
||||
DOCKER_HTTPS_PROXY=--build-arg no_proxy=$(no_proxy)
|
||||
endif
|
||||
|
||||
ifdef use_proxy_at_runtime
|
||||
rt_http_proxy=$(http_proxy)
|
||||
rt_https_proxy=$(https_proxy)
|
||||
rt_no_proxy=$(no_proxy)
|
||||
endif
|
||||
|
||||
DISABLE_CACHE= 'false'
|
||||
@ -97,6 +102,9 @@ endif
|
||||
ifdef rt_http_proxy
|
||||
echo "ENV HTTP_PROXY $(rt_http_proxy)" >> Dockerfile
|
||||
echo "ENV http_proxy $(rt_http_proxy)" >> Dockerfile
|
||||
endif
|
||||
ifdef rt_no_proxy
|
||||
echo "ENV no_proxy $(rt_no_proxy)" >> Dockerfile
|
||||
endif
|
||||
docker build $(DOCKER_HTTP_PROXY) $(DOCKER_HTTPS_PROXY) --no-cache=$(DISABLE_CACHE) -t $(IMAGE) .
|
||||
-rm Dockerfile
|
||||
|
Loading…
x
Reference in New Issue
Block a user