maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   SailfishOS (https://talk.maemo.org/forumdisplay.php?f=52)
-   -   [WIP] Prey - antitheft system (https://talk.maemo.org/showthread.php?t=92829)

localhost 2015-04-30 18:37

Re: [WIP] Prey - antitheft system
 
Quote:

Originally Posted by nieldk (Post 1463350)
A bit more to do.
Here is a more complete guide.

Please not last sentence in this. There is no systemd service at the moment. So, prey will need to be running in terminal until I have worked a bit more.

[CODE]$ sudo npm -g install prey
$ sudo prey config hooks post_install

I'm trying to set up prey on my Jolla, but something is failing at the last step above.
Code:

...
Setting permissions on /var/log/prey.log
chowning /var/log/prey.log to uid 996 and gid 991
Running "config activate" as prey
Error! Command failed: /bin/sh -c /usr/bin/node /usr/lib/node_modules/prey/node_modules/ocelot/runner.js prey /usr/lib/node_modules/prey/bin/prey config activate
child_process.js:1162
    throw errnoException(err, 'spawn');
          ^
Error: spawn EACCES
    at exports._errnoException (util.js:746:11)
    at ChildProcess.spawn (child_process.js:1162:11)
    at exports.spawn (child_process.js:995:9)
    at run_command (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:60:15)
    at Object.<anonymous> (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:95:1)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Function.Module.runMain (module.js:501:10)

Anyone an idea what I'm doing wrong?

localhost 2015-04-30 19:13

Re: [WIP] Prey - antitheft system
 
Got past the issue. Went for:
$ devel-su
$ prey config hooks post_install

Now it's working. Not sure why, but it works ;-)

freehub 2015-07-08 12:54

Re: [WIP] Prey - antitheft system
 
Quote:

Originally Posted by localhost (Post 1469018)
Got past the issue. Went for:
$ devel-su
$ prey config hooks post_install

Now it's working. Not sure why, but it works ;-)

Thank you! Also thanks to nieldk! It works.

The systemd service was running right away. No further action required. Not sure if this was from finishing the post_install command error-free by the method quoted above instead of means by sudo. Or if for instance my previous attempts to get Prey to work with nodejs from the Warehouse repository were responsible.

This time one of nieldk's builds of nodejs from the Mer repository was used: https://build.merproject.org/package...latest_armv7hl

There seems to be an issue with Prey 1.3.9 reporting locations: https://github.com/prey/prey-node-client/issues/95

Installing Prey 1.3.6 worked however:

Code:

$ sudo npm -g install prey@1.3.6
Additional feedback on Prey versions 1.3.7 and 1.3.8 would be most welcome. If someone could test a fresh install from Prey version 1.3.6 upwards and report on its behaviour related to the systemd service it would also be great.

nieldk 2015-07-08 17:04

Re: [WIP] Prey - antitheft system
 
Part of why it works better now, is that the Prey guys made changes so that the Linux version reported by our device is no longer responded to as 'unknown'.
FYI: I know that Jolla guys have also been in touch with the prey guys, so perhaps something is coming along the side that will be more complete.
Will look into the new version of Prey and what the problem is.

Eminem 2015-09-07 18:09

Re: [WIP] Prey - antitheft system
 
Can we / I get a updated and new guide and maybe posted on the first page? :)

nieldk 2015-09-07 19:54

Re: [WIP] Prey - antitheft system
 
Quote:

Originally Posted by Eminem (Post 1481452)
Can we / I get a updated and new guide and maybe posted on the first page? :)

Unfortunately not for this thread, as I no longer 'own' it. But, I suppose a new thread is in place actually...

nieldk 2015-09-09 06:47

Re: [WIP] Prey - antitheft system
 
Created new thread for nodejs based version http://talk.maemo.org/showthread.php?p=1481712


All times are GMT. The time now is 03:06.

vBulletin® Version 3.8.8