feat: add gmail-hook monorepo with watcher, api, and web

Ship the receipt pipeline (Livin/Grab/BRI), PocketBase spendings, PM2 ecosystem, and a proper .gitignore that excludes secrets, SQLite data, and media dumps.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-13 22:58:47 +07:00
co-authored by Cursor
parent 8fa9f4350e
commit 46a2e2a7b0
67 changed files with 12153 additions and 0 deletions
+28
View File
@@ -0,0 +1,28 @@
/**
* PM2 ecosystem for the Gmail receipt watcher.
*
* Loads secrets from the monorepo root `.env` via dotenv in src/config.js.
* Override port with WATCHER_PORT (default 3001; production on rpi4 uses 8083).
*
* pm2 start ecosystem.config.cjs
* pm2 save
*/
module.exports = {
apps: [
{
name: "gmail-watcher",
cwd: __dirname,
script: "src/index.js",
interpreter: "node",
instances: 1,
exec_mode: "fork",
autorestart: true,
max_restarts: 10,
restart_delay: 2000,
env: {
NODE_ENV: "production",
WATCHER_PORT: "8083",
},
},
],
};