[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Installing Packages as Another User with Sudo

I have been trying and failing to set up the sudoers file so that I can run
apt/dpkg/etc as another user without sudo (root) access. Here is a snippet:

# Restrict the user "packager" to only installing packages on this machine
packager home = NOPASSWD: (root) /usr/bin/apt, (root) /usr/bin/aptitude,
(root) /usr/bin/dpkg

# Allow users to install packages via "packager"
granttrec home = (packager) /usr/bin/apt, (packager) /usr/bin/aptitude

The user packager was created as a system user and belongs to nogroup, I
tried adding thi user to the sudo group but no effect, the command I am
trying to run is:

sudo -u packager sudo aptitude install ...

Also If I enter aptitude, I can become root without a sudo promt.

Any Ideas?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

( ! ) Warning: include(msgfooter.php): failed to open stream: No such file or directory in /var/www/git/ubuntu-users/msg37766.html on line 94
Call Stack
10.0006358280{main}( ).../msg37766.html:0

( ! ) Warning: include(): Failed opening 'msgfooter.php' for inclusion (include_path='.:/var/www/git') in /var/www/git/ubuntu-users/msg37766.html on line 94
Call Stack
10.0006358280{main}( ).../msg37766.html:0