orhanbalci / rocket-template

Rocket Rest api project template

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rocket-Template

This is a REST API project template that uses Rocket framework with Diesel ORM backed up with Postgresql database. You can generate project skeleton using porteurbars.

  • In order to create project you need to install porteurbars first.
  • Run porteurbars orhanbalci/rocket-template your_project_directory
  • You need nightly version of Rust for Rocket. rustup default nightly
  • Install diesel_cli.
       apt get install libsqlite3-dev
       apt get install libmysqlclient-dev
       apt get install libpq-dev
       cargo install diesel_cli
    
  • Run database migration from your project directory. First make sure you have a working database url in your .env file. disel migration run
  • Ignite your diesel powered rocket api cargo run
  • Skeleton code is taken from mgattozi

About

Rocket Rest api project template

License:MIT License


Languages

Language:Rust 100.0%