diff options
Diffstat (limited to 'backend/src/main.rs')
-rw-r--r-- | backend/src/main.rs | 34 |
1 files changed, 3 insertions, 31 deletions
diff --git a/backend/src/main.rs b/backend/src/main.rs index 6ee54ec..65be48d 100644 --- a/backend/src/main.rs +++ b/backend/src/main.rs @@ -1,36 +1,8 @@ -#![feature(proc_macro_hygiene, decl_macro)] - -use rocket::{Build, Rocket}; -use rocket_sync_db_pools::database; - #[macro_use] extern crate rocket; -#[macro_use] -extern crate diesel; - -mod db; -mod routes; -mod schema; - -#[database("postgresql_database")] -pub struct DbConn(diesel::PgConnection); - -#[get("/")] -fn index() -> &'static str { - "Hello, world!" -} +extern crate mozaic4_backend; #[launch] -fn rocket() -> Rocket<Build> { - rocket::build() - .mount( - "/", - routes![ - index, - routes::users::register, - routes::users::login, - routes::users::current_user, - ], - ) - .attach(DbConn::fairing()) +fn launch() -> _ { + mozaic4_backend::rocket() } |