Well it worked perfectly fine by just writing sudo python program.py

Thanks for all your help. I didn't realise of this before and this was a
big problem for my project.

Regards

2014-10-08 3:37 GMT-05:00 <[email protected]>:

> Jesus Rincon <[email protected]> wrote:
> > 2014-10-07 18:21 GMT-05:00 Robert Nelson <[email protected]>:
> > > On Tue, Oct 7, 2014 at 6:20 PM, Jesus Rincon <[email protected]>
> > wrote:
> > > > Yes, I access as root user.
> > >
> > > Well as "desktop" user you are "debian"...
> > >
> >
> > oh.. I see. I'm not very good in using linux. Is there anyway to access
> as
> > root in desktop
> >
> It's not particularly easy, I've been moaning about this for a while,
> it should be possible to to basic stuff like this as a non-root user.
>
> I've have a (rather kludgy) workaround.
>
> 1 - Edit the sudoers file so that the user you want to be able to run
> the Python script that uses the Adafruit IO libraries can 'sudo
> /usr/bin/python' without entering a password.
>
> 2 - Change the shebang on your Python script to '#!/usr/bin/sudo
> /usr/bin/python'.
>
> The user will then switch to root privilege to run the Python
> interpreter which runs the script.
>
> It's a nasty kludge and introduces security holes galore but it does
> make it possible to pretend that everythng can be done in ordinary
> user mode.
>
> (If you need more detail on how to do this I'm happy to provide it but
> the sudo/sudoers man page should get you on your way)
>
> --
> Chris Green
> ยท
>
> --
> For more options, visit http://beagleboard.org/discuss
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "BeagleBoard" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/beagleboard/48fVl45Wxuw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to