Bug#205969: /usr/bin/apt-get: enable non-root use of --download-only and --simulate
Package: apt
Version: 0.5.9
Severity: wishlist
File: /usr/bin/apt-get
There seems no point of not allowing non root users to be able to use
--download-only or --simulate.
At most warn if it is found that root is also using it at the moment
if found so, and/or warn that we are in Read-only mode and root might
change things while we are running.
E: Could not open lock file /var/lib/dpkg/lock - open (13 Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
Could it be that dpkg's --no-act is not given to dpkg upon --simulate, if
indeed proper?
Indeed with the proper PATH, a non-root user can successfully use dpkg:
PATH=/usr/local/sbin:/usr/sbin:/usr/bin:/sbin:/bin dpkg --no-act -P netbase
dpkg: dependency problems prevent removal of netbase:
lftp depends on netbase...
Remember to put --no-act as the first dpkg option...
In fact one would now have an extra layer of protection with
--simulate: as non-root one is doubly confident of not messing up the
system.
Indeed, perhaps do an audit to see if there's any more functions that
can be opened up to non-root users. At present many are already open,
but more could be.
Reply to: