I was wondering how to install Bleachbit with a standard user account (no sudo rights) but with sudo-rights enabled just for this application, without altering the account type globally?
Hi @Kweenie67,
Look at the sudoers configuration. I think, specifically, providing a custom configuration in /etc/sudoers.d
I suspect there is an option with polkit, but I know nothing about that.
Hope this helps!
Edit:
Youâd have to install it as root, but then using the configuration you can set sudoers not to as for a password if you run the executable with sudo.
Thx for the tip!
This sudoers.d map is marked with a black cross through it. It can only be opened as root.
Should this be the recommended way to change it?
Isnât that a risky move?
I mean, superuser privileges are required in order to modify system files. And considering BleachBit can be quite damaging if used incorrectly â talking from experience â iâd be personally even less inclined to allow a user to run it as a superuser if they arenât even allowed to install/update/remove packagesâŚ
That being said, as a user you can download any Linux application, put it in a personal folder, and run it from there, with or without superuser rights. It wonât be âinstalledâ per se â you only need to delete the installation folder to âuninstallâ it â but it doesnât need superuser privileges to do so.
Is your suggestion similar with the âexecute as instant appâ, as used in Adroid?
The non-installed app runs from the cloud, but only with the absolutely necessary parts, which are deleted when closed/ended?
The main reason why I would prefer a installed system application in stead of an âinstant appâ is mainly the matter of control. I take some risks normally for granted.
But, when your Manjaro system works from the cloud, your suggestion is far way desirable.
I am not familiar with Android instant apps, but what i mentioned is not that at all.
I talk about an application in the most basic sense.
An application is merely an executable file, most often with (many) resources files and libraries. When you install an application on your system, you put those files at a defined place on your drive. Then you can run that application from the executable file.
When you use an installer â or a package manager on Linux â the place where it will be installed to is pre-defined, and some information is added to the system in order to allow you to run that application without needing to look for the executable file. That is how you can launch an application from an application menu, a launcher on your desktop, or from a single command in the terminal.
In Linux, the package manager commonly install an application in a folder owned by root, not the user. This is why you need superuser privileges to install and update anything through the package manager. But that is merely the âstandardâ way to do things. You can still âinstallâ an application manually (see above), without needing superuser privileges, but also without the benefits of the package manager.
In all those cases, the application is fully on your drive. Thus not in the cloud.
login as rootâŚ
# EDITOR=nano visudo
go to the bottom of the fileâŚ
add the following commandâŚ(substitute your {user $} for username below )
username ALL=/usr/bin/pamac,/usr/bin/pacman,/usr/bin/pacman-mirrors
hit Ctrl+o to save /etc/sudoers.tmp
hit Ctrl+x to exit nano
exit from root prompt
thenâŚ
[user] $ sudo pamac install app-name
or
[user] $ sudo pacman -S app-name
This is exactly what I was looking for. Thanks for sharing.
Alternativ:
look for the bleachbit.desktop file
(/usr/share/applications/org.bleachbit.BleachBit.desktop)
âŚ
(kdesu must be installed):
change the line with âexec = [command]â ==> exec = kdesu [command]
This will open a requester asking for passwordâŚ
(and start the app with sudo rights)
.
Last: write down what you have done to a cheat-sheet
Hi, I was wondering and I must absolutely be sureâŚ
Are we (still) talking about the file the file âsudoers.dâ (/etc/sudoers.d) ?
Thank you for this simple but effective solution.
/etc/sudoers.tmp
This resource should only be used for things like pacman-mirrors and veracrypt but not for anything that would install software, or modify permissions.
Thatâs what I already thought. Thx for the confirmation.
But definitely a creative solution for my (yet fixed) problem.
This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.