docs: add 6h cron auto-sync job details

2026-05-21 19:42:56 -04:00
parent fe59b0df93
commit 458724f7d9
+12
@@ -41,6 +41,18 @@ Staged import pipeline for Cantaloupe machine data:
**Tests:** 10 unit tests (test_cantaloupe_sync.py) + 23 integration tests (test_sync_api.py). All 33 pass.
### Cron Job — 6h Auto-Sync (since e9d18cb)
Hermes cron job `5ababff9c6e9` runs every 6 hours, executing `~/.hermes/scripts/cantaloupe-sync.sh`:
1. Exports from mycantaloupe.com: `cd ~/projects/cantaloupe-downloader && python -m cantaloupe export --scheduled --output ~/cantaloupe-exports/`
2. Triggers the sync API: `curl -X POST http://127.0.0.1:8090/api/admin/cantaloupe/sync` (with admin Bearer token)
3. Reports results as cron delivery
**Source:** `scripts/cantaloupe-sync.sh` in the repo.
**Credentials:** `~/.cantaloupe.env` — needs real mycantaloupe.com account (currently dummy, see issue #7).
**Fix (e9d18cb):** Export subprocess cwd corrected to `~/projects/cantaloupe-downloader/`.
## Related
- Main app repo: [[https://gitea.ourpad.casa/shawn/canteen-asset-tracker|shawn/canteen-asset-tracker]]