Skip to content

Commit 37f4c67

Browse files
gforiengforien
andauthored
chore: use arm64 hadolint image (#64)
Co-authored-by: gforien <gforien.externe@bedrockstreaming.com>
1 parent fd3ce39 commit 37f4c67

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

dev.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,12 @@ set -eo pipefail
1313
IMAGE_NAME="zenika/terraform-aws-cli"
1414
[[ -n $3 ]] && IMAGE_TAG=$3 || IMAGE_TAG="dev"
1515

16+
# Set platform for Hadolint image
17+
[[ "$(uname -m)" == "arm64" ]] && PLATFORM="linux/arm64" || PLATFORM="linux/amd64"
18+
1619
# Lint Dockerfile
1720
echo "Linting Dockerfile..."
18-
docker run --rm --interactive --volume "${PWD}":/data --workdir /data hadolint/hadolint:2.5.0-alpine /bin/hadolint --config hadolint.yaml Dockerfile
21+
docker run --rm --interactive --volume "${PWD}":/data --workdir /data --platform "${PLATFORM}" hadolint/hadolint:2.12.0-alpine /bin/hadolint --config hadolint.yaml Dockerfile
1922
echo "Lint Successful!"
2023

2124
# Build image

0 commit comments

Comments
 (0)