Skip to content

Commit

Permalink
Feat: add diesel-rs
Browse files Browse the repository at this point in the history
- Remove sqlx
- Install diesel-rs and deadpool-diesel
- Re-write migration files
- Add mods `schema` and `models`

## Test Plan

- Install postgresql and edit `DATABASE_URL` in `.env`
- Run the server
- Send **POST** http://localhost:8080/test/create_configs
- GET http://localhost:8080/test/get_configs
  • Loading branch information
JedBeom committed Feb 1, 2025
1 parent d08994e commit 7fe6e20
Show file tree
Hide file tree
Showing 16 changed files with 483 additions and 1,029 deletions.
4 changes: 2 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# see https://docs.rs/sqlx/latest/sqlx/mysql/struct.MySqlConnectOptions.html
DATABASE_URL=mysql://username:password@localhost/rune?socket=/tmp/mysql.sock
# https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNSTRING
DATABASE_URL=postgres://username:password@localhost/rune
SERVE_DIR=frontend/dist

This file was deleted.

Loading

0 comments on commit 7fe6e20

Please sign in to comment.