I'm trying to execute some graphic tools from my turbogears app. I've changed my 'sudoers' file to allow user 'www-data' to execute all kind of commands (i know, is insecure, but i'm trying and i'll fix this when i find the solution). I have my turbogears app running in apache and this is what i make in my code:
[...] Popen(['sudo', '-u', 'user', '-k', 'gedit']) [...] I've also tried 'gksudo' but this message appear in the apache log: (gedit:2843): Gtk-WARNING **: cannot open display: The user i've used in the command is the same that is using the desktop. I'm using debian and i've copied the user skeleton in the home directory of user 'www-data' but nothing changed. A command like this works perfectly: Popen(['sudo', touch', '/pepe']) When i execute 'sudo -u www-data gedit' appears the same error, but i make, as root: # xhost +local: And then the 'gedit' appears perfectly. Any idea? I know that is not a turbogears problem but i wonder if anybody has tried the same as me and got the solutions. Thanks in advance. -- You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/turbogears?hl=en.

