[Asterisk-Users] Reload Asterisk from php or perl script
Brian West
brian at bkw.org
Fri Oct 8 07:38:58 MST 2004
Just connect to the manager port over a socket and do it.. what you
recommend with sudo is WRONG WRONG WRONG and BAD BAD BAD
bkw
> -----Original Message-----
> From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-
> bounces at lists.digium.com] On Behalf Of Peter Osborne
> Sent: Friday, October 08, 2004 9:38 AM
> To: asterisk-users at lists.digium.com
> Cc: Dee Lowndes
> Subject: Re: [Asterisk-Users] Reload Asterisk from php or perl script
>
> On Friday 08 October 2004 10:14, Dee Lowndes wrote:
> > I am using apache but I would rather avoid this option if possible.
> >
> > Any other ideas?
> >
> > Dee
>
> You could install sudo, then add a line in your /etc/sudoers like this:
>
> www-data ALL= NOPASSWD: /usr/bin/asterisk
>
> (this assumes apache runs under the username www-data)
>
> Then add "sudo" in from of the command you are trying to exec and it will
> be
> executed as root. Obviously there are some security issues with doing
> this,
> but it will do the job. You could write a shell script that runs you
> asterisk
> command and then allow sudo for the script rather than asterisk itself,
> that
> would provide a little more security.
>
> Pete
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
More information about the asterisk-users
mailing list