Skip to content

Commit

Permalink
Add qemu emulation
Browse files Browse the repository at this point in the history
  • Loading branch information
sarahchen6 committed Sep 18, 2024
1 parent 9a1f5e2 commit d31b589
Showing 1 changed file with 4 additions and 36 deletions.
40 changes: 4 additions & 36 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,39 +56,7 @@ jobs:
docker run --platform linux/x86_64 --rm ${{ steps.vars.outputs.IMAGE }}:${{ steps.vars.outputs.TAG }} bundle --version
docker run --platform linux/x86_64 --rm -v "${PWD}":"${PWD}" -w "${PWD}" ${{ steps.vars.outputs.IMAGE }}:${{ steps.vars.outputs.TAG }} /bin/sh -c 'bundle install && bundle exec rake test'
# attempt for just one image
# - runs-on: ubuntu-latest
# - name: checkout
# uses: actions/checkout@v4
# - name: set up docker container engine
# run: docker buildx create --name=container --driver=docker-container --use --bootstrap
# - name: build single-arch image (x86_64)
# run: docker buildx build ghcr.io/datadog/images-rb/engines/ruby:3.4 --builder=container --cache-from=type=registry,ref=ghrc.io/datadog/catadog:catadog --output=type=image,push=false --platform linux/x86_64 -f ./Dockerfile
# - name: tag single-arch image (x86_64)
# run: docker buildx build ghcr.io/datadog/images-rb/engines/ruby:3.4 --builder=container --cache-from=type=registry,ref=ghrc.io/datadog/catadog:catadog --load --platform linux/x86_64 -f ./Dockerfile --tag ghrc.io/datadog/catadog:catadog
# - name: test single-arch image (x86_64)
# run: |
# docker run --platform linux/x86_64 --rm ghrc.io/datadog/catadog:catadog /bin/sh -c 'true'
# docker run --platform linux/x86_64 --rm ghrc.io/datadog/catadog:catadog ruby -e 'puts RUBY_DESCRIPTION'
# docker run --platform linux/x86_64 --rm ghrc.io/datadog/catadog:catadog gem --version
# docker run --platform linux/x86_64 --rm ghrc.io/datadog/catadog:catadog bundle --version
# docker run --platform linux/x86_64 --rm -v "${PWD}":"${PWD}" -w "${PWD}" ghrc.io/datadog/catadog:catadog /bin/sh -c 'bundle install && bundle exec rake test'






# - runs-on: ubuntu-latest
# - name: checkout
# uses: actions/checkout@v4
# - name: build image
# run: docker buildx build -t catadog .
# - name: test image by starting up a container
# run: docker run --rm -d --name catadog catadog
# - name: kill container
# run: docker container kill catadog
# now build image for aarch64-linux, emulated under qemu
- name: enable aarch64 emulation (x86_64)
run: |
docker run --privileged --rm tonistiigi/binfmt --install arm64

0 comments on commit d31b589

Please sign in to comment.