-
Notifications
You must be signed in to change notification settings - Fork 164
A hook for mounting an extra-patches directory into the jail #928
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
Open
dlangille
wants to merge
10
commits into
freebsd:master
Choose a base branch
from
dlangille:jail-hook
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
f4b2972
A hook for mounting an extra-patches directory into the jail
dlangille f83c52e
Use mkdir -p which removes the need for the test
dlangille c5a5f0b
Restore check if the directory exists before creating it.
dlangille e2f2653
Fix va_args error on non-amd64
bdrewery a78fcf1
enter_interactive: Don't pkg-update.
bdrewery 8d56885
CCACHE_NON_ROOT: Fix access to /root
bdrewery eedf4ea
Remove surounding if and add -p to the mkdir
dlangille 9a9e7df
Revert "Fix va_args error on non-amd64"
dlangille 7bd0393
Revert "enter_interactive: Don't pkg-update."
dlangille 21a6e08
Revert "CCACHE_NON_ROOT: Fix access to /root"
dlangille File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/bin/sh | ||
# /usr/local/etc/poudriere.d/hooks/jail.sh | ||
|
||
status="$1" | ||
|
||
# NOTE: mount is invoked before start: re https://github.com/freebsd/poudriere/wiki/hooks | ||
if [ "$status" = "mount" ] && [ -d /usr/local/etc/poudriere.d/local-patches ]; then | ||
mntpath="$2" | ||
|
||
# The local-patches directory is created only if it does not already exist. | ||
# If it does not already exist, it means we are doing this on the master jail | ||
if [ ! -d "${mntpath}/local-patches" ]; then | ||
/bin/mkdir "${mntpath}/local-patches" | ||
fi | ||
|
||
# mount our patches to that location | ||
/sbin/mount -t nullfs -o ro /usr/local/etc/poudriere.d/local-patches "${mntpath}/local-patches" | ||
dlangille marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
fi | ||
|
||
exit 0 |
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.
Uh oh!
There was an error while loading. Please reload this page.