Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion images/chromium-headful/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ source ../../shared/start-buildkit.sh

# Build the Docker image using the repo root as build context
# so the Dockerfile's first stage can access the server sources
(cd "$SCRIPT_DIR/../.." && docker build -f images/chromium-headful/Dockerfile -t "$IMAGE" .)
(cd "$SCRIPT_DIR/../.." && docker build --platform "$DOCKER_PLATFORM" -f images/chromium-headful/Dockerfile -t "$IMAGE" .)
1 change: 1 addition & 0 deletions images/chromium-headful/run-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ cat "$FLAGS_FILE"
# Build docker run argument list
RUN_ARGS=(
--name "$NAME"
--platform "$DOCKER_PLATFORM"
--privileged
--tmpfs /dev/shm:size=2g
-v "$HOST_RECORDINGS_DIR:/recordings"
Expand Down
2 changes: 1 addition & 1 deletion images/chromium-headless/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ source ../../shared/start-buildkit.sh

# Build the Docker image using the repo root as build context
# so the Dockerfile's first stage can access the server sources
(cd "$SCRIPT_DIR/../.." && docker build -f images/chromium-headless/image/Dockerfile -t "$IMAGE" .)
(cd "$SCRIPT_DIR/../.." && docker build --platform "$DOCKER_PLATFORM" -f images/chromium-headless/image/Dockerfile -t "$IMAGE" .)
1 change: 1 addition & 0 deletions images/chromium-headless/run-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ mkdir -p "$HOST_RECORDINGS_DIR"

RUN_ARGS=(
--name "$NAME"
--platform "$DOCKER_PLATFORM"
--privileged
--tmpfs /dev/shm:size=2g
-p 9222:9222
Expand Down
6 changes: 6 additions & 0 deletions shared/ensure-common-build-run-vars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ NAME="${NAME:-${IMAGE_TYPE}-test}"

UKC_INDEX="${UKC_INDEX:-index.unikraft.io}"

# Chrome-for-Testing only ships linux/amd64 binaries, so both images must be
# built and run for amd64 even on arm64 hosts (Apple Silicon). Docker Desktop
# will emulate via Rosetta. Override with DOCKER_PLATFORM=linux/arm64 only if
# you have a compatible chromium baked into a custom Dockerfile.
DOCKER_PLATFORM="${DOCKER_PLATFORM:-linux/amd64}"

# Only require UKC_TOKEN and UKC_METRO when explicitly requested
# Pass "require-ukc-vars" as second argument to enable this check
REQUIRE_UKC_VARS="${2:-}"
Expand Down
Loading