Fix passing custom APT_MIRROR on building Docker
| ... | ... |
@@ -59,6 +59,7 @@ DOCKER_DOCS_IMAGE := docker-docs$(if $(GIT_BRANCH_CLEAN),:$(GIT_BRANCH_CLEAN)) |
| 59 | 59 |
DOCKER_PORT_FORWARD := $(if $(DOCKER_PORT),-p "$(DOCKER_PORT)",) |
| 60 | 60 |
|
| 61 | 61 |
DOCKER_FLAGS := docker run --rm -i --privileged $(DOCKER_ENVS) $(DOCKER_MOUNT) $(DOCKER_PORT_FORWARD) |
| 62 |
+BUILD_APT_MIRROR := $(if $(DOCKER_BUILD_APT_MIRROR),--build-arg APT_MIRROR=$(DOCKER_BUILD_APT_MIRROR)) |
|
| 62 | 63 |
|
| 63 | 64 |
# if this session isn't interactive, then we don't want to allocate a |
| 64 | 65 |
# TTY, which would fail, but if it is interactive, we do want to attach |
| ... | ... |
@@ -79,7 +80,7 @@ binary: build ## build the linux binaries |
| 79 | 79 |
$(DOCKER_RUN_DOCKER) hack/make.sh binary |
| 80 | 80 |
|
| 81 | 81 |
build: bundles init-go-pkg-cache |
| 82 |
- docker build ${DOCKER_BUILD_ARGS} -t "$(DOCKER_IMAGE)" -f "$(DOCKERFILE)" .
|
|
| 82 |
+ docker build ${BUILD_APT_MIRROR} ${DOCKER_BUILD_ARGS} -t "$(DOCKER_IMAGE)" -f "$(DOCKERFILE)" .
|
|
| 83 | 83 |
|
| 84 | 84 |
bundles: |
| 85 | 85 |
mkdir bundles |