https://github.com/slaveofcode/rust-example-restful
Rust Implementation of Restful API using Actix Web
https://github.com/slaveofcode/rust-example-restful
actix-web diesel-rs restful-api rust rust-lang
Last synced: 8 months ago
JSON representation
Rust Implementation of Restful API using Actix Web
- Host: GitHub
- URL: https://github.com/slaveofcode/rust-example-restful
- Owner: slaveofcode
- License: mit
- Created: 2022-12-29T20:09:14.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-12-31T11:06:10.000Z (almost 3 years ago)
- Last Synced: 2025-01-20T15:23:33.734Z (10 months ago)
- Topics: actix-web, diesel-rs, restful-api, rust, rust-lang
- Language: Rust
- Homepage:
- Size: 23.4 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Rust Example Restful API using Actix Web
This is an example implementation of restful api built using Rust language and Actix-Web framework.
## Spec
- Postgresql
- Diesel (ORM)
- Actix Web (Framework)
## Setup
### Install Dependencies
cargo update
### Prepare Environment
Copy the example configuration at `.env.example` to `.env` and adjust it into your local config values
## Migrations
The migration tools is using `diesel_cli`, so you'll need to install it first by
cargo install diesel_cli
### View Help
diesel migration
### Create new Migration
diesel migration generate
### Run Migration
diesel migration run
### Redo Migration
diesel migration redo