fix: Run codejail with app user; more docs#124
Merged
Conversation
- Use `app` user by default; may need to switch back to `root` at some point for ease of development, but for now let's try to keep it as similar as possible to stage and prod so that we can find issues sooner. - Document the situation, and note how to enter as root (same as for any container, but may be helpful in this uncommon situation). - Correct comment for `FSIZE` - Copy `NPROC` and `PROXY` defaults into settings for reference This depends on edx/edx-arch-experiments#983, otherwise the service will start failing.
8 tasks
robrap
approved these changes
Mar 19, 2025
docs/codejail.rst
Outdated
|
|
||
| If you need to debug the confinement, either because it is restricting too much or too little, a good strategy is to run ``tail -F /var/log/kern.log | grep codejail`` and watch for ``DENIED`` lines. You should expect to see several appear during service startup, as the service is designed to probe the confinement as part of its initial healthcheck. | ||
|
|
||
| Unlike other devstack services, this one runs as the ``app`` user rather than as ``root``. In order to enter the container as root, you can use ``docker compose exec -it --user root codejail bash`` rather than ``make codejail-shell``. |
Contributor
There was a problem hiding this comment.
Maybe add something like the following from your PR description:
Although this isn't strictly needed to develop, it better matches our production environment.
robrap
approved these changes
Mar 19, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
appuser by default; may need to switch back torootat some point for ease of development, but for now let's try to keep it as similar as possible to stage and prod so that we can find issues sooner.FSIZENPROCandPROXYdefaults into settings for referenceThis depends on edx/edx-arch-experiments#983, otherwise the service will start failing.
I've completed each of the following or determined they are not applicable: