Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
fluxbox - run apps as root dialog [SOLVED]
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
feiticeir0
Apprentice
Apprentice


Joined: 13 Jul 2005
Posts: 288
Location: Castelo Branco, Portugal

PostPosted: Fri Aug 01, 2014 6:26 pm    Post subject: fluxbox - run apps as root dialog [SOLVED] Reply with quote

Hi all !

I recently moved to fluxbox from gnome3 ! And i'm loving it, until now !

With gnome3, every time i had to run an application as root (ie virt-manager), a dialog window would appear asking for the root password and granting my user privileges - this case, to connect to libvirtd.
I think this would be gksu or something like it.

How can i accomplish this with fluxbox ?

I have policykit in my USE flags ! What agent (if any) do i must install or having started at boot so i can have some sort of dialog asking for permissions ?

Best regards

Bruno Santos
_________________
Do It With Rhythm
Back to top
View user's profile Send private message
feiticeir0
Apprentice
Apprentice


Joined: 13 Jul 2005
Posts: 288
Location: Castelo Branco, Portugal

PostPosted: Fri Aug 01, 2014 9:04 pm    Post subject: Reply with quote

Just emerge gnome-extra/polkit-gnome and added to my fluxbox startup
Code:

 /usr/libexec/polkit-gnome-authentication-agent-1 &


Enabled polkit.service and console-kit-daemon.service in systemd

Everything works !

Cheers

Bruno Santos
_________________
Do It With Rhythm
Back to top
View user's profile Send private message
lyallp
Veteran
Veteran


Joined: 15 Jul 2004
Posts: 1558
Location: Adelaide/Australia

PostPosted: Mon Aug 04, 2014 12:15 pm    Post subject: Reply with quote

To run programs as root, or any other user, for that matter, I simply use sudo.

I have a menu item (~/.fluxbox/menu)
Code:
[exec] (Xterm) {xhost +; sudo -i -A -p 'xterm on %h by %u as %U' /usr/bin/xterm -j -cm || xmessage -buttons "Ok" "Failed."}

I have installed
Code:
net-misc/ssh-askpass-fullscreen

_________________
...Lyall
Back to top
View user's profile Send private message
feiticeir0
Apprentice
Apprentice


Joined: 13 Jul 2005
Posts: 288
Location: Castelo Branco, Portugal

PostPosted: Mon Aug 04, 2014 3:51 pm    Post subject: Reply with quote

lyallp wrote:
To run programs as root, or any other user, for that matter, I simply use sudo.

I have a menu item (~/.fluxbox/menu)
Code:
[exec] (Xterm) {xhost +; sudo -i -A -p 'xterm on %h by %u as %U' /usr/bin/xterm -j -cm || xmessage -buttons "Ok" "Failed."}

I have installed
Code:
net-misc/ssh-askpass-fullscreen


Thank you for your reply, but that only works with SSH or does it work also for any other program ?

Best regards

Bruno Santos
_________________
Do It With Rhythm
Back to top
View user's profile Send private message
lyallp
Veteran
Veteran


Joined: 15 Jul 2004
Posts: 1558
Location: Adelaide/Australia

PostPosted: Mon Aug 04, 2014 11:18 pm    Post subject: Reply with quote

ssh-askpass-fullscreen works just fine with sudo, as described.

Either set SUDO_ASKPASS environment variable in /etc/env.d/99ssh_askpass OR set /etc/sudo.conf
Code:
Path askpass /usr/bin/ssh-askpass-fullscreen
. Either way makes it globally available to all users.
_________________
...Lyall
Back to top
View user's profile Send private message
feiticeir0
Apprentice
Apprentice


Joined: 13 Jul 2005
Posts: 288
Location: Castelo Branco, Portugal

PostPosted: Tue Aug 05, 2014 8:44 am    Post subject: Reply with quote

lyallp wrote:
ssh-askpass-fullscreen works just fine with sudo, as described.

Either set SUDO_ASKPASS environment variable in /etc/env.d/99ssh_askpass OR set /etc/sudo.conf
Code:
Path askpass /usr/bin/ssh-askpass-fullscreen
. Either way makes it globally available to all users.


Hi !

Thank you ! I've setup the environment variable, configured SUDO and now I execute virt-manager using sudo -A virt-manager and everything works just fine ! Thank you !

Best regards

Bruno Santos
_________________
Do It With Rhythm
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum