Pandora FMS Community

Custom Commands

wjpounder · 20 may 2016, 18:30 · 2 mensajes · 57 visitas

  1. Inicio del debate

    Hi, Is it possible to create a command that executes a PHP script using the PHP CLI or cURL? If so, what would the syntax be?  Something like "/usr/bin/php [address of page]"? Thanks.

  2. Got the command running using this:

    /usr/bin/php [path to my script]/myscript.php _id_agent_ _modulestatus_
    

    --------------------------------------------------------- within myscript.php:

    $id_agent = $argv[1]
    $module_status = $argv[2]
    

Entra en tu cuenta para publicar.