This codebase was created to demonstrate a fully fledged fullstack application built with Rocket including CRUD operations, authentication, routing, pagination, and more.
We've gone to great lengths to adhere to the Rocket community styleguides & best practices.
For more information on how to this works with other frontends/backends, head over to the RealWorld repo.
Main branch is based on async version of Rocket (v0.5.0-rc.1).
There is also a branch based on non-async (v0.4) version of Rocket.
Please see the CHANGELOG for a release history.
# install rustup
curl https://sh.rustup.rs -sSf | sh
rustup install nightly
# start postgresql and seed the database
psql -f init.sql
cargo install diesel_cli --no-default-features --features "postgres"
diesel migration run
You can also check postman/newman. See
diesel cli uses
Rocket sets database configuration from
Checkout Rocket's amazing guide
By default random suffixes feature is enabled, so one could easily create multiple articles with the same title. To disable it:
cargo run --no-default-features
- Bettter error handling