2019-07-09 13:24:52 +00:00
|
|
|
.PHONY: all
|
2019-02-22 14:03:42 +00:00
|
|
|
all: container
|
|
|
|
|
2020-01-04 23:29:49 +00:00
|
|
|
DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
|
|
|
|
|
2020-01-09 03:58:16 +00:00
|
|
|
# Use docker to run makefile tasks
|
|
|
|
USE_DOCKER ?= true
|
|
|
|
|
|
|
|
# Disable run docker tasks if running in prow.
|
|
|
|
# only checks the existence of the variable, not the value.
|
|
|
|
ifdef DIND_TASKS
|
|
|
|
USE_DOCKER=false
|
|
|
|
endif
|
|
|
|
|
2019-07-09 13:24:52 +00:00
|
|
|
.PHONY: container
|
2019-02-22 14:03:42 +00:00
|
|
|
container:
|
2020-01-09 03:58:16 +00:00
|
|
|
ifeq ($(USE_DOCKER), true)
|
2020-02-25 12:35:44 +00:00
|
|
|
@$(DIR)/../../build/run-in-docker.sh make e2e-test-binary
|
2020-01-09 03:58:16 +00:00
|
|
|
else
|
2020-02-25 12:35:44 +00:00
|
|
|
@make -C $(DIR)/../../ e2e-test-binary
|
2020-01-09 03:58:16 +00:00
|
|
|
endif
|
2019-02-22 14:03:42 +00:00
|
|
|
|
2020-02-25 12:35:44 +00:00
|
|
|
cp $(DIR)/../e2e/e2e.test .
|
|
|
|
cp $(DIR)/../e2e/wait-for-nginx.sh .
|
|
|
|
cp -R $(DIR)/../../charts .
|
2019-02-22 14:03:42 +00:00
|
|
|
|
2020-04-17 02:34:12 +00:00
|
|
|
# TODO: avoid manual copy
|
|
|
|
cp -R $(DIR)/../../test/e2e/settings/ocsp/* .
|
|
|
|
|
2020-01-27 00:48:35 +00:00
|
|
|
docker buildx build \
|
|
|
|
--load \
|
|
|
|
--progress plain \
|
|
|
|
--tag nginx-ingress-controller:e2e .
|
2019-02-22 14:03:42 +00:00
|
|
|
|
2019-07-09 13:24:52 +00:00
|
|
|
.PHONY: clean
|
2019-02-22 14:03:42 +00:00
|
|
|
clean:
|
|
|
|
rm -rf _cache e2e.test kubectl cluster ginkgo
|
2019-07-09 13:24:52 +00:00
|
|
|
docker rmi -f nginx-ingress-controller:e2e || true
|