riscv / riscv-isa-manual

RISC-V Instruction Set Manual
https://riscv.org/
Creative Commons Attribution 4.0 International
3.71k stars 643 forks source link

Run root Docker as the current user #1647

Closed Timmmm closed 2 months ago

Timmmm commented 2 months ago

Reapplication of 3539eff338352aba83dbae9e7b310d6a7d9a7d56 but this time we only add the --user argument for root Docker. Rootless Docker behaves the same as Podman and doesn't need the --user flag; in fact it breaks builds if you add it.

I also added a comment for the :z flag.

Timmmm commented 2 months ago

IMO a better solution than messing around with Docker/Podman is Apptainer, which is explicitly designed for this use case and takes care of exposing mounts etc. for you. Unfortunately people are unlikely to have it installed already so we're probably in an "everyone uses shitty Bash scripts because Bash is already there" sort of situation. :-/

aswaterman commented 2 months ago

FWIW, this version works on my Mac.

wmat commented 2 months ago

This fix allows me to build locally on Fedora again successfully. I'm interested to see if the create release workflow succeeds on GH though. I'm going to merge this now to find out.

wmat commented 2 months ago

The Release new ISA When merging a PR still fails. I recognize why this is happening. We'll try to figure out how to fix this.

Timmmm commented 2 months ago

It won't pass because it's running from my fork.

If you run it manually for master it should work though. I think the configuration needs to be changed a bit, I'm not a GitHub actions pro though....

wmat commented 2 months ago

I fixed up the workflow and it's working as it should now.