Save location data from Overland GPS Tracker app to sqlite and a very simple website.
Find a file
2025-07-22 16:55:30 +00:00
.vscode Use my weather API and not the async version. 2022-09-24 21:46:30 -07:00
deploy update for running prod on la.zie.fi 2025-07-22 16:55:30 +00:00
static user water.css 2022-09-25 17:33:41 +00:00
views user water.css 2022-09-25 17:33:41 +00:00
.gitignore add now page, lots of cleanups 2022-05-02 03:51:12 +00:00
atos.py updates 2022-07-06 03:09:07 +00:00
authlib.py update for running prod on la.zie.fi 2025-07-22 16:55:30 +00:00
bottle_sqlite.py cleanup formatting. 2022-04-30 22:05:09 +00:00
capurl.py updates 2022-09-24 23:33:36 +00:00
LICENSE LICENSE 2022-04-30 17:30:30 +00:00
main.py update for running prod on la.zie.fi 2025-07-22 16:55:30 +00:00
mypy.ini updates 2022-07-06 03:09:07 +00:00
pyproject.toml update to run on ovh 2024-10-21 20:43:12 +00:00
README.md update for running prod on la.zie.fi 2025-07-22 16:55:30 +00:00
shell.nix cleanup prod 2022-09-25 17:09:10 +00:00
uv.lock update to run on ovh 2024-10-21 20:43:12 +00:00
weatherapi.py cleanup prod 2022-09-25 17:09:10 +00:00
weatherapi_test.py Use my weather API and not the async version. 2022-09-24 21:46:30 -07:00

pyoverlander

Collect location data from the "Overland GPS Tracker" app and put it in a sqlite file. Requires python3, no other dependencies(uses bottle, included).

https://github.com/aaronpk/Overland-iOS

Run the app: main.py takes 2 inputs:

  • STDIN: The very first line will be the TOKEN, all other stdin is ignored
  • 1 argument: location of the db file

While running, it will always listen on localhost on port 8080 (submit a PR if you don't like it) (I'd recommend a config table in the DB and pull the listen information from that table)

DB setup

Create the necessary tables:

./main.py newdb mydata.db
sqlite3 mydata.db 
tokens            "email": "TEXT NOT NULL UNIQUE",
            "perms": "JSON",
            "used": "INTEGER",
            "valid": "BOOL",
            "device_id": "TEXT",
            "extra": "JSON",
            "note": "TEXT", P
insert into capabilities (token,email,valid,device_id,extra,note) VALUES ('mytoken','me@example.com',1,'myphone','{}','token for my iphone');
.quit

A decent way to generate a token:

# generate a ~ 64 character token, the arguably sane max
python3 -c 'import secrets;print(secrets.token_urlsafe(48))'

Run the application:

python3 main.py mydata.db

This code requires bottle.py, you can just shove the file in the same dir or you can install it via pip or whatever.

you also probably want to proxy the HTTP via a HTTPS proxy, I do it via nginx in /etc/nixos/configuration.nix like this:

        virtualHosts."example.com" = {
                addSSL = true;
                useACMEHost = "example.com";
                root = "/var/www/www.example.com";
                locations."/overland/" = {
                        proxyPass = "http://localhost:8080";
                };
        };

or for non nix, passing through a proxy is your problem :) Though I accept pull requests to add more.

NOTE: right now it's hardcoded to /overland/, so be sure to include that in the requests. (PR's accepted)

url: https://example.com/overland/

URL for overland app: https://example.com/overland/submit?token=happy

or for auto setup(should work):
overland://setup?url=https%3A%2F%2Fexample.come%2Foverland%2Fsubmit&token=happy&device_id=myphone

Interesting Queries: select timestamp,lat,long,json_extract(properties,"$.battery_level") from locations;

Docs/urls