mirror of
https://github.com/kmitresse/Compo-Service-Log-Project.git
synced 2026-07-09 12:07:45 +00:00
feat: Launch Server and database async
This commit is contained in:
+2
-7
@@ -5,14 +5,9 @@ import { TypeOrmDataSource } from "./TypeOrmDataSource";
|
||||
|
||||
dotenv.config();
|
||||
|
||||
// 1. initialize database connexions
|
||||
|
||||
// 2. Load all datasets
|
||||
|
||||
// 3. Start the server
|
||||
|
||||
TypeOrmDataSource.initialize()
|
||||
.then(() => DatasetCollection.loadAll())
|
||||
.then(() => console.log("All datasets are loaded"))
|
||||
.then(() => new Server().start())
|
||||
.catch(console.error);
|
||||
|
||||
new Server().start();
|
||||
|
||||
Reference in New Issue
Block a user