-
Modify the
DATABASE_URLvar in.envto point to your chosen database -
Turn on the appropriate database feature for your chosen db in
api/Cargo.toml(the"sqlx-mysql",line) -
Execute
cargo runto start the server -
Visit localhost:8000 in browser
Run server with auto-reloading:
cargo install systemfd cargo-watch
systemfd --no-pid -s http::8000 -- cargo watch -x runRun tests:
cd api
cargo testRun migration:
cargo run -p migration -- upRegenerate entity:
sea-orm-cli generate entity --output-dir ./entity/src --lib --entity-format dense --with-serde both