Self-Hosting: Local Development
Run FaraCore locally using SQLite for development and testing.
SQLite (Default)
FaraCore uses SQLite by default, which requires no additional setup. SQLite is perfect for:
- Local development
- Testing and prototyping
- Single-user deployments
- Low-traffic scenarios
Installation
Install FaraCore:
cd fara-core
pip install -e ".[test]"Initialize Database
Initialize the SQLite database:
faracore migrateThis creates the database file (default: data/actions.db) and sets up the schema.
Start Server
Start the FaraCore server:
faracore serveThe server will start on http://127.0.0.1:8000
Custom SQLite Path
Specify a custom SQLite database path:
export FARA_SQLITE_PATH=/path/to/your/actions.db
faracore serveOptional: Set Auth Token
For local development, you can optionally set an auth token:
export FARA_AUTH_TOKEN=dev-token
faracore serveAccess Points
- Web UI:
http://127.0.0.1:8000 - API:
http://127.0.0.1:8000/v1/actions - API Docs:
http://127.0.0.1:8000/docs - Metrics:
http://127.0.0.1:8000/metrics - Health:
http://127.0.0.1:8000/health
Database Location
By default, SQLite stores data in:
data/actions.db(relative to where you run the command)- Or the path specified in
FARA_SQLITE_PATH
Backup
To backup your SQLite database:
cp data/actions.db data/actions.db.backup