uraimo / run-on-arch-action

A Github Action that executes jobs/commands on non-x86 cpu architectures (ARMv6, ARMv7, aarch64, s390x, ppc64le, riscv64) via QEMU
BSD 3-Clause "New" or "Revised" License
677 stars 149 forks source link

Add several architectures and their debian images #58

Open radimkohout opened 2 years ago

radimkohout commented 2 years ago

This pull request adds buster and bullseye Debian for riscv64, mips64le, i386, and amd64(I know, that i386 and amd64 you can use without this, but with this action, it is much easier to build several platforms. Edit: after I've found, that the riscv64 has no stable and oldstable build's, I've changed riscv64 to experimental and unstable, I'll probably add more images soon.

uraimo commented 2 years ago

Hi, thanks, can you also add at least one new arch pair here for the new architectures to be sure that the emulation works? Thx.

radimkohout commented 2 years ago

Hi, it's done, you can see the result's here: https://github.com/GarnetOS/run-on-arch-action/actions/runs/1441155688 , only running the riscv64/unstable seems to crash on git, but I can't find why. Edit: Amd64 and i386 fails on the thing, that "x86_64" != "amd64", and the asseratation fails on that.

uraimo commented 2 years ago

Unstable likely fails because git was not installed here, adding unstable to the options should fix it. No idea about the other two, amd64 should not even use qemu-static to create the container, while that x86_64 is the name of static driver qemu has.

radimkohout commented 2 years ago

I'll try to address this issues in next few days, stay tuned for update 😃

radimkohout commented 2 years ago

Ok, all issues solved, things done to solve the issues: 1) Added ENTRYPOINT ["linux32", "--"] to i386 Dockerfiles (see https://github.com/ioft/dockerhub/issues/1 ), also added note to the README "Contributing" part 2) Added override to amd64(actually it's x86_64) and i386(actually i686). 3) Added unstable override to "Assert container uses distro" for riscv64.

radimkohout commented 2 years ago

Update: Added alpine_latest for i386 from https://github.com/uraimo/run-on-arch-action/pull/59

uraimo commented 2 years ago

After a few other PRs are merged, we'll merge this too, sorry for the delay, thanks again.

radimkohout commented 2 years ago

Ok, thanks. I've already made a version for my private use, so don't worry. But I'll migrate here as soon as there will be a new version.

megglos commented 2 years ago

After a few other PRs are merged, we'll merge this too, sorry for the delay, thanks again.

@uraimo Just wondered what the state of this PR is, it seems it was ready to merge but got stale? Is there anything still to resolve I could try to help with?

martin-g commented 2 years ago

I also wanted to create an issue asking for adding x86_64/amd64 to the available architectures. It would be much easier to use the GHA matrix feature to test on both "native" arch (i.e. amd64) and non-native (emulated) ones. I see other people already had this idea! Looking forward this PR to get some love soon and be merged!

lalten commented 1 year ago

@uraimo what's the plan here? Anything still blocking this?

uraimo commented 1 year ago

Just an update on this, support for riscv64 has been added and a base_image parameter for completely custom images (any arch any distro) has been included in 2.5.0 that I've just tagged.

Since I was also planning to refactor the Dockerfile mechanism (too many files) in the next major release, that I would ideally complete next week, this PR will be reworked to become part of the new default images configuration, thanks to @radimkohout and all those that participated.