activate a command script from emoncms

Hello, is it possible to have emoncms run a script that executes a given command (a .sh file)?

I would like to connect the script for example to a command button.

A thousand thanks

I don’t believe that can be done at present. It is something for @TrystanLea to consider.

Hello @michelino emoncms does this internally for a few actions, such as running post processes, restarting wifi etc but it’s not something that we have plans to introduce as part of an action that could be triggered from a dashboard button due to potential security issues.

Here’s an example of how this is done in the admin module for updating firmware emoncms/admin_controller.php at master · emoncms/emoncms · GitHub

The command is passed to the service-runner redis queue, a service running in the background called service-runner then executes the command…

1 Like

Many thanks