Skip to content

Commit 5e51ab0

Browse files
committed
Update Makefile to reuse image for build Edge versions
Signed-off-by: Viet Nguyen Duc <[email protected]>
1 parent 7b24905 commit 5e51ab0

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

Makefile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ chrome_beta:
177177
chromium: node_base
178178
cd ./NodeChromium && docker buildx build --platform $(PLATFORMS) $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg CHROMIUM_VERSION=$(CHROMIUM_VERSION) -t $(NAME)/node-chromium:$(TAG_VERSION) .
179179

180-
edge: node_base
180+
edge_only:
181181
case "$(PLATFORMS)" in \
182182
*linux/amd64*) \
183183
echo "Microsoft Edge is only supported on linux/amd64" \
@@ -188,6 +188,8 @@ edge: node_base
188188
;; \
189189
esac
190190

191+
edge: node_base edge_only
192+
191193
edge_dev:
192194
cd ./NodeEdge && docker buildx build --platform $(PLATFORMS) $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg EDGE_VERSION=microsoft-edge-dev -t $(NAME)/node-edge:dev .
193195

@@ -244,7 +246,7 @@ standalone_chrome_beta: chrome_beta
244246
standalone_chromium: chromium
245247
cd ./Standalone && docker buildx build --platform $(PLATFORMS) $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg BASE=node-chromium -t $(NAME)/standalone-chromium:$(TAG_VERSION) .
246248

247-
standalone_edge: edge
249+
standalone_edge_only:
248250
case "$(PLATFORMS)" in \
249251
*linux/amd64*) \
250252
echo "Microsoft Edge is only supported on linux/amd64" \
@@ -255,6 +257,8 @@ standalone_edge: edge
255257
;; \
256258
esac
257259

260+
standalone_edge: edge standalone_edge_only
261+
258262
standalone_edge_dev: edge_dev
259263
cd ./Standalone && docker buildx build --platform $(PLATFORMS) $(BUILD_ARGS) --sbom=true --attest type=provenance,mode=max \
260264
--build-arg NAMESPACE=$(NAME) --build-arg VERSION=dev --build-arg BASE=node-edge -t $(NAME)/standalone-edge:dev .

tests/build-backward-compatible/bootstrap.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,11 @@ for CDP_VERSION in "${VERSION_LIST[@]}"; do
3939
if [ "${BROWSER}" = "all" ] || [ "${BROWSER}" = "edge" ] && [ "${SKIP_BUILD}" = "false" ]; then
4040
if [ -n "${EDGE_VERSION}" ]; then
4141
BUILD_ARGS="--build-arg EDGE_VERSION=${EDGE_VERSION}"
42-
BUILD_ARGS="${BUILD_ARGS}" make standalone_edge
42+
if [ "${REUSE_BASE}" = "true" ]; then
43+
BUILD_ARGS="${BUILD_ARGS}" make edge_only standalone_edge_only
44+
else
45+
BUILD_ARGS="${BUILD_ARGS}" make standalone_edge
46+
fi
4347
else
4448
echo "Edge version not found in matrix for input ${CDP_VERSION}"
4549
exit 1

0 commit comments

Comments
 (0)