feat: run sqlx migrations automatically on startup
This commit is contained in:
@@ -35,6 +35,8 @@ async fn main() {
|
||||
}
|
||||
};
|
||||
|
||||
sqlx::migrate!().run(&pool).await.expect("Failed to run migrations");
|
||||
|
||||
let jwt_secret = std::env::var("JWT_SECRET").expect("JWT_SECRET must be set!");
|
||||
let ip_addr: String = std::env::var("API_URL").expect("API_URL must be set!");
|
||||
let port: String = std::env::var("API_PORT").expect("API_PORT must be set!");
|
||||
|
||||
Reference in New Issue
Block a user