File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -83,7 +83,8 @@ python generate_index.py # Auto-detects CUDA/GPU
8383# ## Phase 5: Memory Optimization & Deployment (Local/Toolforge)
8484Before deploying, convert the production metadata to SQLite to stay within 6GiB RAM limits:
8585` ` ` bash
86- python backend/migrate_to_sqlite.py
86+ cd backend
87+ python migrate_to_sqlite.py
8788` ` `
8889
8990Once the index and database are ready, start the FastAPI backend from the root directory:
@@ -118,7 +119,6 @@ Log into Toolforge and set the necessary permissions:
118119
119120` ` ` bash
120121ssh supnabla@login.toolforge.org
121- become code2codesearch
122122
123123chmod -R a+r /data/project/code2codesearch/mediawiki-code2code-search/models/
124124chmod a+x /data/project/code2codesearch/backend/functions.db
@@ -129,6 +129,9 @@ chmod a+x /data/project/code2codesearch/backend/mediawiki.index
129129Now you are ready to deploy the webservice:
130130
131131` ` ` bash
132+ # Switch to the code2codesearch project
133+ become code2codesearch
134+
132135# Stop and clean existing build
133136toolforge webservice buildservice stop --mount=all
134137toolforge build clean -y
You can’t perform that action at this time.
0 commit comments