sandbox-notebookllamalm-nextjs/scripts
Vadym Samoilenko 096885c87f Fix LlamaIndex model patch: also patch base.py direct reference
base.py imports anthropic_modelname_to_contextsize directly, so patching
utils module attribute alone doesn't affect calls inside base.py.
Now patches both utils and base modules for Anthropic and Gemini.

Also: show docker build output in deploy.sh (was suppressed, hid errors).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 14:42:47 +01:00
..
deploy.sh Fix LlamaIndex model patch: also patch base.py direct reference 2026-04-24 14:42:47 +01:00
README.md Fix model IDs, hangs, deploy script, Docker healthchecks 2026-04-24 14:25:30 +01:00
rollback.sh Fix Claude model ID and deploy.sh sudo SSH issue 2026-04-24 14:32:20 +01:00

scripts/

Script Purpose Run frequency
deploy.sh Rolling redeploy: git pull → build → migrate DB → up -d → health check Every push to prod
rollback.sh <sha> Revert to a previous commit and rebuild Emergency only

Deploy

# SSH into optical-web-1 and run:
ssh michael_clervi@optical-web-1
cd /opt/sandbox-notebookllamalm-nextjs
sudo bash scripts/deploy.sh

# Flags:
#   --no-build       restart containers without rebuilding (for env-only changes)
#   --backend-only   rebuild + restart backend only
#   --frontend-only  rebuild + restart frontend only
#   --branch feat/x  deploy a specific branch

Rollback

# Find the SHA you want:
git log --oneline -10

# Roll back:
sudo bash scripts/rollback.sh abc1234

Historical scripts (do not run)

Old one-shot systemd→Docker migration scripts are in Old Readmes/migration-2026-03/. Old pre-Docker systemd scripts are in Old Readmes/pre-docker-systemd/.