Skip to content

Commit eccbdcf

Browse files
Timna BrownTimna Brown
authored andcommitted
fix: remove hardcoded --platform linux/arm64 causing exec format error in CI
Hardcoding --platform=linux/arm64 in FROM and docker commands breaks CI runners (amd64) with 'exec format error'. Docker picks the correct native platform on each host automatically. The ARCH=$(dpkg --print-architecture) in the glab install step already handles the only place arch matters.
1 parent bf56ea5 commit eccbdcf

3 files changed

Lines changed: 7 additions & 7 deletions

File tree

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM --platform=linux/arm64 rust:1.85-bookworm AS base
1+
FROM rust:1.85-bookworm AS base
22

33
RUN rustup component add clippy rustfmt
44

Makefile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,17 +52,17 @@ auth-status:
5252

5353
## container-build: Build the dev container image
5454
container-build:
55-
docker build --platform linux/arm64 --target dev -t devopster-cli-dev .
55+
docker build --target dev -t devopster-cli-dev .
5656

5757
## container-test: Run tests inside the container
5858
container-test:
59-
docker build --platform linux/arm64 -t devopster-cli-ci .
60-
docker run --rm --platform linux/arm64 devopster-cli-ci cargo test
59+
docker build -t devopster-cli-ci .
60+
docker run --rm devopster-cli-ci cargo test
6161

6262
## container-run: Open a shell inside the container with host credentials mounted
6363
container-run:
64-
docker build --platform linux/arm64 --target dev -t devopster-cli-dev .
65-
docker run --rm -it --platform linux/arm64 \
64+
docker build --target dev -t devopster-cli-dev .
65+
docker run --rm -it \
6666
-v "$(HOME)/.config/devopster:/root/.config/devopster" \
6767
-v "$(PWD):/app" \
6868
-w /app \

scripts/setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ make container-build
4545

4646
echo ""
4747
echo "==> Image ready. Opening container shell..."
48-
docker run --rm -it --platform linux/arm64 \
48+
docker run --rm -it \
4949
-v "$HOME/.config/devopster:/root/.config/devopster" \
5050
-v "$(pwd):/app" \
5151
-w /app \

0 commit comments

Comments
 (0)