diff --git a/.github/workflows/tests.yml b/.github/workflows/tests-amd64.yml similarity index 100% rename from .github/workflows/tests.yml rename to .github/workflows/tests-amd64.yml diff --git a/.github/workflows/tests-arm64.yml b/.github/workflows/tests-arm64.yml index 85ff313..d41fd7b 100644 --- a/.github/workflows/tests-arm64.yml +++ b/.github/workflows/tests-arm64.yml @@ -10,33 +10,23 @@ on: jobs: simulate-arm-linux: - runs-on: macos-13 + runs-on: ubuntu-latest steps: - name: Checkout code uses: actions/checkout@v4 - - name: Install Docker - run: | - brew install --cask docker - open --background -a /Applications/Docker.app + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 - - name: Pull ARM64 Docker image - run: | - docker pull --platform linux/arm64 ubuntu:20.04 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 - - name: Run ARM64 Docker container - run: | - docker run --privileged --rm --platform linux/arm64 -v $(pwd):/workspace -w /workspace ubuntu:20.04 /bin/bash -c " - apt-get update && - apt-get install -y qemu-user-static binfmt-support && - # Your ARM-specific commands go here - echo 'Running on ARM architecture' - " + - name: Create Docker Buildx Builder + run: docker buildx create --name mybuilder - - name: Run your tasks in the ARM container - run: | - docker run --privileged --rm --platform linux/arm64 -v $(pwd):/workspace -w /workspace ubuntu:20.04 /bin/bash -c " - # Execute your test commands or build scripts here - ./your-script.sh - " + - name: Build Empty ARM64 Image + run: docker buildx build --platform linux/arm64 -t empty-arm64 --load . + + - name: Run command in ARM64 container + run: docker run --rm empty-arm64 ls -l