Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Various fixes to codejail setup instructions (copies, user) #164

Merged
merged 2 commits into from
Dec 5, 2023

Conversation

timmc-edx
Copy link
Contributor

This still doesn't work as described, as codejail's confinement still denies it the ability to create a temp directory, but it's closer.

  • Specify the use of --copies when setting up the sandbox virtualenv
  • Include the user argument to work around TMPDIR bug (Codejail cannot run without a user set #162) and link to the issue from a code comment
  • Use an unambiguous test for safe/usafe configuration (return the value using jailed globals, and bypass some issues with output streams)
  • Ensure that reading codejail checkout is permitted by apparmor

Also:

  • Use the venv module rather than the virtualenv command, for better compatibility with varying system configurations
  • Don't bother activating virtualenv, just call its pip directly
  • Note the ordinarily-unsafe presence of find in the sudoers example
  • Use correct inline code syntax for rst

This still doesn't work as described, as codejail's confinement still
denies it the ability to create a temp directory, but it's closer.

- Specify the use of `--copies` when setting up the sandbox virtualenv
- Include the `user` argument to work around TMPDIR bug
  (#162) and link to the issue
  from a code comment
- Use an unambiguous test for safe/usafe configuration (return the value
  using jailed globals, and bypass some issues with output streams)
- Ensure that reading codejail checkout is permitted by apparmor

Also:

- Use the venv module rather than the virtualenv command, for better
  compatibility with varying system configurations
- Don't bother activating virtualenv, just call its pip directly
- Note the ordinarily-unsafe presence of find in the sudoers example
- Use correct inline code syntax for rst
Copy link
Contributor

@nedbat nedbat left a comment

Choose a reason for hiding this comment

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

One small question

README.rst Outdated Show resolved Hide resolved
@timmc-edx timmc-edx merged commit 96abed1 into master Dec 5, 2023
3 checks passed
@timmc-edx timmc-edx deleted the timmc/fix-setup-partial branch December 5, 2023 17:44
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.

2 participants