This is true. And while I haven’t looked into harbour-compatability a lot, it’s probably possible to generate e.g. a systemd user service from the app, i.e. after installation rather than shipping anything.
This is very interesting (related or even not to ‘find lost device’ thema) and would deserve an own thread.
I even have a question ready for this thread
probably that’s doable a bit overkill imho instead of just ship the systemd service config but yeah.
Still you need some binary that will fork itself etc so it’s running as a real deamon or you think about just using it normally and use systemd functionalities for that?
so we just need this to be exposed to be available from the outside.
So on the phone, there must be a service running in the background that will take:
host
login
password
and authenticate to the service and provide data.
Actually this is probably related to MDM as the phone should just join to MDM server and that server should control that.
Now, do we have some OpenSource MDM server with nice GUI api?
Hm, I wonder if a reverse ssh tunnel (and autossh) could replace that function? Autostart that with a passwordless ssh key, and establish a reverse tunnel to some server you own.
Forward some device ports if needed to that home server via the tunnel.
Jeeez, what you guys are saying is over my head!
My abilities are more limited to tinkering scripts and tolerating using sudo to achieve some tasks.
But what you elaborate smell more useful to all and usable by any user in the future, after some elaboration.
Anyway,
I git-cloned following the second link you gave, @nephros.
Trying to then run the script, I hit my nose on a:
defaultuser@XperiaXA2-DualSIM ~% python3 ./Downloads/slowcyclist/gps/gps.py
Traceback (most recent call last):
File “./Downloads/slowcyclist/gps/gps.py”, line 3, in
from gi.repository import GLib
ModuleNotFoundError: No module named ‘gi’
I did some short searches but … thought wou would know on instant.
Does this ring a bell to you?
If not, don’t loose time, I’ll continue searching deeper.
could be, depends what you need. Imho for avg Joe it’s easier to just enter these details. For others ssh may be better option.
Edit: maybe adding option to paste ssh password less key? Or even key with pw stored in sfos secret store would be ok? But then tbh there’s a lot of problems to setup revers ssh and to maintain it. Personally I’d prefer the option to provide the data as above.
We can’t also forget about some Nextcloud functionality that we could glue together. Someone mentioned that, do you have any ideas how does it work/what’s needed to get it working?
pkcon install python3-gobject. Careful, the script tries to sudo and change location.conf. This is safe (it’ll just fail) it you’re not root and have not configured sudo.
If you have sudo enabled, this may do things you do not want… check the script.
Thank you @nephros for the package info + warning.
Indeed, sudoers is now set to allow the user to modify location.conf. But this file only. So it’s not so a big problem, I believe.
The script is now running but not able to enable location.
Even by changing location.conf, the gps seems not to be ON.
In contrary, if I enable it with the GUI Button, then, it is working.
Something in GPS triggering perhaps has changed since the script was made?
As I was saying there, we now have /etc/location/location.conf and /var/lib/location/location.conf which are identical… strange…