A link shortener written in Rust using Rocket
- Clone the repository
- Create a
.env
file at the root directory and add yourJWT_SECRET
(String, used to generate user tokens) to it.
JWT_SECRET = "my_secret"
- Run the server using
cargo run
or build a binary usingcargo b
If getting a Linker error for sqlite3.lib
, add the deps
dir as an env variable
$Env:SQLITE3_LIB_DIR = "<path-to-repo>\deps"
Note: When building a binary, you also need to copy the static directory and put it in the same directory as the binary.