Thanks for your quick response, now it works fine
J
Posts made by jesgomp
-
RE: Null computer when running background task
-
Null computer when running background task
Hi, I am running on OSMC with a raspberry pi 3b+, and if I execute fom the terminal triggercmdagent, it all works properly as expected. It connects with a computer.
The output is the following.Run installdaemon.sh to install the triggercmdagent daemon so it runs during boot Daemon install: false Logging in with saved token. Checking if the 845412155412 computer exists. This computer exists in your account. Tokenfile: /home/osmc/.TRIGGERcmdData/token.tkn ComputerIDfile: /home/osmc/.TRIGGERcmdData/computerid.cfg Logging in with saved token to run foreground tasks. Write backup completed. |> Now connected to https://www.triggercmd.com. \___/ For help, see: http://bit.ly/2q0QDpf (using sails.io.js node SDK @v1.1.13) Connected at: Sat Oct 31 2020 19:51:34 GMT+0100 (Central European Standard Time) Initiated command removals Initiated command adds { message: 'Subscribed to dsgf9gsrherhreb1d52!' } { message: 'Subscribed to dsgf9gsrherhreb1d52!' }
But when I try to install the triggercmdagent daemon so it runs during boot with
sudo /usr/share/triggercmdagent/app/src/installdaemon.sh
the output is the next
osmc@salon:/usr$ sudo /usr/share/triggercmdagent/app/src/installdaemon.sh Daemon install: true Logging in with saved token. Checking if the null computer exists. This computer was deleted from your account. Login to recreate it. * triggercmdagent.service - TRIGGERcmd Agent Loaded: loaded (/etc/systemd/system/triggercmdagent.service; enabled; vendor preset: enable Active: active (running) since Sat 2020-10-31 19:57:36 CET; 655ms ago Main PID: 1371 (node) Memory: 2.6M CGroup: /system.slice/triggercmdagent.service `-1371 node /usr/share/triggercmdagent/app/src/daemon.js --run /root/.TRIGGERcmdDat Oct 31 19:57:36 salon systemd[1]: Started TRIGGERcmd Agent.
The json file is the next:
[ {"trigger":"Reboot","command":"shutdown -r","ground":"background","voice":"reboot","allowParams": "false"}, {"trigger":"Gnome Editor","command":"gedit","ground":"foreground","voice":"edit","allowParams": "false"}, {"trigger":"apagar","command":"shutdown -h now","ground":"background","voice":"apagar","allowParams": "false"}, {"trigger":"apagardos","command":"shutdown -h now","ground":"foreground","voice":"apagardos","allowParams": "false"}, {"trigger":"yum update","command":"yum -y update","ground":"background","voice":"yum update","allowParams": "false"}, {"trigger":"apt update","command":"apt-get -y update","ground":"background","voice":"update","allowParams": "false"} ]
I do not understand why it does not get the computer, from the same file ComputerIDfile: /home/osmc/.TRIGGERcmdData/computerid.cfg, and how to fix it.
I would really appreciate some help,