Browse Source

Use UBUNTU_BASE_IMAGE instead of BASE_IMAGE

Offering better alignment with some downstream build jobs.

Change-Id: I90332926b4e5dd04b00b6008d06d36624086e313
changes/52/635352/1
Bryan Strassner 3 months ago
parent
commit
919868e16c
1 changed files with 5 additions and 34 deletions
  1. 5
    34
      Makefile

+ 5
- 34
Makefile View File

@@ -31,7 +31,7 @@ PROXY                      ?= http://proxy.foo.com:8000
31 31
 NO_PROXY                   ?= localhost,127.0.0.1,.svc.cluster.local
32 32
 USE_PROXY                  ?= false
33 33
 
34
-BASE_IMAGE                 ?=
34
+UBUNTU_BASE_IMAGE          ?=
35 35
 
36 36
 IMAGE:=${DOCKER_REGISTRY}/${IMAGE_PREFIX}/$(IMAGE_NAME):${IMAGE_TAG}
37 37
 IMAGE_DIR:=images/$(IMAGE_NAME)
@@ -45,7 +45,7 @@ images: $(IMAGE_NAME)
45 45
 $(IMAGE_NAME):
46 46
 	@echo
47 47
 	@echo "===== Processing [$@] image ====="
48
-	@make build_$@ IMAGE=${DOCKER_REGISTRY}/${IMAGE_PREFIX}/$@:${IMAGE_TAG} IMAGE_DIR=images/$@ IMAGE_NAME=$@
48
+	@make build IMAGE=${DOCKER_REGISTRY}/${IMAGE_PREFIX}/$@:${IMAGE_TAG} IMAGE_DIR=images/$@ IMAGE_NAME=$@
49 49
 	@make run IMAGE=${DOCKER_REGISTRY}/${IMAGE_PREFIX}/$@:${IMAGE_TAG} SCRIPT=./tools/$@_image_run.sh
50 50
 
51 51
 # Build all docker images for this project
@@ -81,39 +81,10 @@ tests:
81 81
 run:
82 82
 	USE_PROXY=$(USE_PROXY) PROXY=$(PROXY) $(SCRIPT) $(IMAGE)
83 83
 
84
-_BASE_IMAGE_ARG := $(if $(BASE_IMAGE),--build-arg FROM="${BASE_IMAGE}" ,)
84
+_BASE_IMAGE_ARG := $(if $(UBUNTU_BASE_IMAGE),--build-arg FROM="${UBUNTU_BASE_IMAGE}" ,)
85 85
 
86
-.PHONY: build_airflow
87
-build_airflow:
88
-ifeq ($(USE_PROXY), true)
89
-	docker build --network host -t $(IMAGE) --label $(LABEL) \
90
-		--label "org.opencontainers.image.revision=$(COMMIT)" \
91
-		--label "org.opencontainers.image.created=$(shell date --rfc-3339=seconds --utc)" \
92
-		--label "org.opencontainers.image.title=$(IMAGE_NAME)" \
93
-		-f $(IMAGE_DIR)/Dockerfile \
94
-		$(_BASE_IMAGE_ARG) \
95
-		--build-arg http_proxy=$(PROXY) \
96
-		--build-arg https_proxy=$(PROXY) \
97
-		--build-arg HTTP_PROXY=$(PROXY) \
98
-		--build-arg HTTPS_PROXY=$(PROXY) \
99
-		--build-arg no_proxy=$(NO_PROXY) \
100
-		--build-arg NO_PROXY=$(NO_PROXY) \
101
-		--build-arg ctx_base=$(BUILD_CTX) .
102
-else
103
-	docker build --network host -t $(IMAGE) --label $(LABEL) \
104
-		--label "org.opencontainers.image.revision=$(COMMIT)" \
105
-		--label "org.opencontainers.image.created=$(shell date --rfc-3339=seconds --utc)" \
106
-		--label "org.opencontainers.image.title=$(IMAGE_NAME)" \
107
-		-f $(IMAGE_DIR)/Dockerfile \
108
-		$(_BASE_IMAGE_ARG) \
109
-		--build-arg ctx_base=$(BUILD_CTX) .
110
-endif
111
-ifeq ($(PUSH_IMAGE), true)
112
-	docker push $(IMAGE)
113
-endif
114
-
115
-.PHONY: build_shipyard
116
-build_shipyard:
86
+.PHONY: build
87
+build:
117 88
 ifeq ($(USE_PROXY), true)
118 89
 	docker build --network host -t $(IMAGE) --label $(LABEL) \
119 90
 		--label "org.opencontainers.image.revision=$(COMMIT)" \

Loading…
Cancel
Save