Skip to content

Conversation

@dionhaefner
Copy link
Contributor

Relevant issue or PR

Fixes #425

Description of changes

  • Add addmeplease executable to every container that adds the current user + group to /etc/passwd and a few other system files.
  • This ensures user code can now rely on the fact that the executing OS user always has a proper uid, gid, home directory, and shell.

We achieve this by compiling a simple C binary that we can run as root with setuid even from non-privileged accounts.

Testing done

Tested on reproducer from #425, and added new e2e test on CI.

@codecov
Copy link

codecov bot commented Dec 18, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.76%. Comparing base (5284bb6) to head (90823bb).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #427      +/-   ##
==========================================
+ Coverage   66.91%   76.76%   +9.84%     
==========================================
  Files          29       29              
  Lines        3431     3434       +3     
  Branches      535      536       +1     
==========================================
+ Hits         2296     2636     +340     
+ Misses        945      569     -376     
- Partials      190      229      +39     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

)


#
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete all commented stuff?

description: ""

build_config:
# Base image to use for the container, must be Ubuntu or Debian-based
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and this file?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Somewhere, maybe here in the description, it would be nice to have an explanation of what this example demonstrates

Copy link
Contributor

@apaleyes apaleyes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After thinking about this for a while and reading docker/linux docs, I am happy to approve it. Still can't claim full understanding though! But at least the general idea now makes sense.

Of course it would be nice to have @xalelax see this too, as he was involved in all earlier bugs/complications with setting users inside tesseracts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

torch.onnx.export not supported with default dynamo param

3 participants