coprocessor/fhevm-engine/tfhe-worker/README.md
docker-composerustsqlx-cli:cargo install sqlx-cli
Start the database
docker compose up -d
Export database url for development
export DATABASE_URL="postgres://postgres:postgres@localhost/coprocessor"
Create the database
sqlx db create
Run the migrations
sqlx migrate run
Exec into postgresql shell
docker exec -u postgres -it fhevm-coprocessor-db-1 psql coprocessor
cargo test
operators_from_events uses the full type matrix by default. To run a lighter local matrix (up to uint64) set TFHE_WORKER_EVENT_TYPE_MATRIX=local before cargo test.
Reload database and apply schemas from scratch
make recreate_db
Run the background FHE worker
cargo run -- --run-bg-worker --worker-polling-interval-ms 1000