summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2014-11-25 22:15:04 -0500
committerLuke Shumaker <lukeshu@sbcglobal.net>2014-11-25 22:15:04 -0500
commitb9e047bf0e31236be69388a91422686c55bd702b (patch)
treee1c85ead71079391cef9568a385f2fab3cd51cdb /src
parentf1f07ff1a3191ef6e753215f10575200a9697685 (diff)
chroot-tools: no longer involve 'nobody'
Diffstat (limited to 'src')
-rw-r--r--src/chroot-tools/hooks-chcleanup.sh2
-rwxr-xr-xsrc/chroot-tools/libremakepkg24
2 files changed, 1 insertions, 25 deletions
diff --git a/src/chroot-tools/hooks-chcleanup.sh b/src/chroot-tools/hooks-chcleanup.sh
index 0fd0f72..7afb13d 100644
--- a/src/chroot-tools/hooks-chcleanup.sh
+++ b/src/chroot-tools/hooks-chcleanup.sh
@@ -25,7 +25,7 @@ clean_chroot() (
local copydir=$1
if $INCHROOT; then
cd /startdir
- sudo -u nobody "$(librelib chroot/chcleanup)"
+ "$(librelib chroot/chcleanup)"
else
librechroot "${librechroot_flags[@]}" clean-pkgs
fi
diff --git a/src/chroot-tools/libremakepkg b/src/chroot-tools/libremakepkg
index 1512282..8d74dc3 100755
--- a/src/chroot-tools/libremakepkg
+++ b/src/chroot-tools/libremakepkg
@@ -57,21 +57,6 @@ indent() {
"$_indent" ' | '
}
-# Usage: _check_perms_dir $directory
-# Make sure that $directory is readable and executable (searchable) by 'nobody'
-check_directory_permissions() (
- local dir=$1
- # `cd` to the directory, then test `.`; that way if parent
- # directories aren't readable, we aren't testing for that. We
- # only need the last element in `$dir`.
- cd "$dir"
- if ! sudo -u nobody test -r . -a -x .; then
- error "Directory '%s' must be readable by user 'nobody'" "$dir"
- return 1
- fi
- return 0
-)
-
# Usage: exit_copy $copydir $src_owner
# End immediately, but copy log files out
exit_copy() {
@@ -255,15 +240,6 @@ main() {
# Make sure that the various *DEST directories exist
mkdir -p -- "$PKGDEST" "$SRCDEST" "$SRCPKGDEST" "$LOGDEST"
- # Check the permissions for $startdir and $SRCDEST
- (
- declare -i ret=0
- check_directory_permissions "$PWD" || ret=1
- if ! [[ "$PWD" -ef "$SRCDEST" ]]; then
- check_directory_permissions "$SRCDEST" || ret=1
- fi
- exit $ret
- )
# OK, we are starting now ##############################################