Eight specialist agents over a 16-book verified WA law corpus (RAG with citations), per-user document vault, WA court-form PDF auto-fill, comms missions with DV safety guard, no-KYC auth, TTS. Self-hosted: Flask + SQLite + Ollama, stdlib-only RAG. Includes README, LICENSE (MIT + not-legal-advice notice), DEPLOY runbook, .gitignore.
27 lines
1.2 KiB
Markdown
27 lines
1.2 KiB
Markdown
# Deploying / updating Astraea on CT150
|
|
|
|
# The live app is at /opt/astraea on CT150 (10.30.20.160), proxmox host 10.30.20.85.
|
|
# NEVER delete the SQLite db (astraea.db) or uploads/ — that's user data.
|
|
|
|
# --- Deploy new code (from your machine) ---
|
|
# 1. Back up on the CT first:
|
|
ssh root@10.30.20.160 'cd /opt/astraea && tar czf /root/astraea-backup-$(date +%F-%H%M).tar.gz --exclude venv . && ls /root/astraea-backup*'
|
|
# 2. Copy changed files:
|
|
scp app.py agents.py root@10.30.20.160:/opt/astraea/
|
|
# 3. Restart:
|
|
ssh root@10.30.20.160 'systemctl restart astraea && sleep 2 && curl -s localhost:5000/api/health'
|
|
|
|
# --- Full rebuild from scratch (new container) ---
|
|
# See README "Deploy on Proxmox LXC" section.
|
|
|
|
# --- Backup user data (run weekly or before any risky change) ---
|
|
ssh root@10.30.20.160 'cd /opt/astraea && tar czf /root/astraea-USERDATA-$(date +%F).tar.gz astraea.db uploads indexes'
|
|
|
|
# --- Restore user data ---
|
|
# scp the tarball back, extract, chown -R root:root, systemctl restart astraea
|
|
|
|
# --- Note on remote-side editing pitfall ---
|
|
# Files on CT150 are owned by uid 501 (dragged from a macOS copy). If edits
|
|
# from the Mac fail with permission errors: ssh in and chown -R root:root /opt/astraea
|
|
# (do NOT chown the sqlite db while the service is running).
|