Skip to content

Commit

Permalink
build: Fix docker run command on OSX M1
Browse files Browse the repository at this point in the history
  • Loading branch information
theofidry committed Oct 6, 2023
1 parent fc2c209 commit 46cf071
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Makefile.e2e
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules

DOCKER_RUN = docker run --interactive --platform=linux/amd64 --rm --workdir=/opt/box
DOCKER_RUN_NO_PULL = docker run --interactive --platform=linux/amd64 --rm --pull=never
# Matches the minimum PHP version supported by Box.
DOCKER_MIN_BOX_VERSION_IMAGE_TAG = ghcr.io/box-project/box_php81
DOCKER_MIN_BOX_XDEBUG_PHP_VERSION_IMAGE_TAG = ghcr.io/box-project/box_php81_xdebug
Expand Down Expand Up @@ -366,7 +367,7 @@ _e2e_dockerfile: $(SCOPED_BOX_BIN)
@mkdir -p $(E2E_DOCKERFILE_OUTPUT_DIR)

docker buildx build $(shell dirname $(E2E_DOCKERFILE_DOCKERFILE)) --platform=linux/amd64 --tag=$(E2E_DOCKERFILE_IMAGE_TAG)
docker run --interactive --pull=never --rm $(E2E_DOCKERFILE_IMAGE_TAG) \
$(DOCKER_RUN_NO_PULL) $(E2E_DOCKERFILE_IMAGE_TAG) \
1>$(E2E_DOCKERFILE_ACTUAL_STDOUT) \
2>$(E2E_DOCKERFILE_ACTUAL_STDERR)

Expand All @@ -383,7 +384,7 @@ _e2e_dockerfile_no_extension: $(SCOPED_BOX_BIN)
@mkdir -p $(E2E_DOCKERFILE_NO_EXT_OUTPUT_DIR)

docker buildx build $(shell dirname $(E2E_DOCKERFILE_NO_EXT_DOCKERFILE)) --platform=linux/amd64 --tag=$(E2E_DOCKERFILE_NOT_EXT_IMAGE_TAG)
docker run --interactive --pull=never --rm $(E2E_DOCKERFILE_NOT_EXT_IMAGE_TAG) \
$(DOCKER_RUN_NO_PULL) $(E2E_DOCKERFILE_NOT_EXT_IMAGE_TAG) \
1>$(E2E_DOCKERFILE_NO_EXT_ACTUAL_STDOUT) \
2>$(E2E_DOCKERFILE_NO_EXT_ACTUAL_STDERR)

Expand Down

0 comments on commit 46cf071

Please sign in to comment.