Web user

Hello,

I’m using asterisknow 1.7 with freepbx 2.7. When I make other php page for doing for example a shutdown It doesn`t work. I tried with the command system_exec(‘whoami’) and the user is asterisk. I added in my sudoers.conf :

asterisk ALL=(ALL) NOPASSWD: ALL
%asterisk ALL=(ALL) NOPASSWD: ALL
apache ALL=(ALL) NOPASSWD: ALL

but if I use system_exec(‘sudo halt’) it doesn´t work.

Any suggestions?

Thanks in advance

try using sudo /sbin/halt