Skip to content

ilkka/rust-backend-starter

Repository files navigation

Rust backend starter

Rust backend starter with

  • OpenAPI spec & swagger with rocket_okapi
  • Postgres with diesel
  • dotenv for config (for development)

Why? Because I happened to work through this and all the bits weren't immediately obvious.

How to start developing

  1. Install diesel CLI with

    cargo install diesel_cli --no-default-features --features postgres
  2. Run the dev database with

    docker-compose up -d
  3. Run migrations with

    diesel migration run
  4. Install watchexec with

    cargo install watchexec-cli
  5. Start in dev mode with

    watchexec --restart cargo run
  6. Open up Swagger UI at http://localhost:8000/swagger

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •