mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-26 18:42:49 +00:00
fix:(freight:auth): finished integrating the freight api with the freight portal
This commit is contained in:
@@ -14,6 +14,9 @@ JWT_SECRET=
|
||||
JWT_ACCESS_TOKEN_SECRET=
|
||||
JWT_REFRESH_TOKEN_SECRET=
|
||||
JWT_EXPIRES_IN=3600
|
||||
# JWT expiry for @tria-plc/api-common token utils (jsonwebtoken timespan format)
|
||||
JWT_ACCESS_TOKEN_EXPIRES=1h
|
||||
JWT_REFRESH_TOKEN_EXPIRES=7d
|
||||
|
||||
# IAM seed defaults (used by @tria-plc/iamapi-common on first boot)
|
||||
SUPER_ADMIN_EMAIL=superadmin@tria.com
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Module } from "@nestjs/common";
|
||||
import { Module, OnApplicationBootstrap } from "@nestjs/common";
|
||||
import { ConfigModule, ConfigService } from "@nestjs/config";
|
||||
import { TypeOrmModule, TypeOrmModuleOptions } from "@nestjs/typeorm";
|
||||
import { IamModule } from "@tria-plc/iamapi-common";
|
||||
import { IamModule, DataSeeder } from "@tria-plc/iamapi-common";
|
||||
import { SharedAuthModule } from "@tria-plc/api-common/modules/auth/shared-auth.module";
|
||||
|
||||
import appConfig from "./config/app.config";
|
||||
@@ -27,7 +27,7 @@ import { NotificationsModule } from "./modules/notifications/notifications.modul
|
||||
config.get<TypeOrmModuleOptions>("database")!,
|
||||
}),
|
||||
SharedAuthModule,
|
||||
IamModule,
|
||||
IamModule.forRoot(),
|
||||
BookingsModule,
|
||||
ConsignmentsModule,
|
||||
TrainsModule,
|
||||
@@ -37,4 +37,10 @@ import { NotificationsModule } from "./modules/notifications/notifications.modul
|
||||
NotificationsModule,
|
||||
],
|
||||
})
|
||||
export class AppModule {}
|
||||
export class AppModule implements OnApplicationBootstrap {
|
||||
constructor(private readonly seeder: DataSeeder) {}
|
||||
|
||||
async onApplicationBootstrap() {
|
||||
await this.seeder.run();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user