Skip to content
This repository has been archived by the owner on Oct 2, 2024. It is now read-only.

running commands that use ch-run as root fails with non-obvious seccomp error #1926

Open
scothalverson opened this issue Sep 20, 2024 · 1 comment

Comments

@scothalverson
Copy link

I built Charliecloud with fakeroot support via seccomp, and unintentionally ran a ch-image build command on a Dockerfile with apt-get commands. This failed with the following error:

error: ch-run was not built with seccomp(2) support

Thinking I had built Charliecloud incorrectly, I rebuilt verifying seccomp support, but got the same error. After a quick debug with @reidpr he pointed out that running as root was the problem. This makes sense in hindsight, and was definitely a bad practice on my part. Nonetheless, an error message that conveyed that I should not run this command as root rather than one that suggested I did not have seccomp support would be helpful in case anyone else does this in the future.

@reidpr
Copy link
Collaborator

reidpr commented Sep 20, 2024

ch-run directly was also unhelpful, per debug session:

# ch-run --feature=seccomp
ch-run[3563719]: error: please report this bug (ch-run.c:635)

I believe this was under sudo(8).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants