feat: add nestjs api and worker skeletons
This commit is contained in:
13
backend/apps/api/src/main.ts
Normal file
13
backend/apps/api/src/main.ts
Normal file
@@ -0,0 +1,13 @@
|
||||
import { NestFactory } from '@nestjs/core';
|
||||
import { ApiModule } from './api.module';
|
||||
|
||||
export async function bootstrapApi(): Promise<void> {
|
||||
const app = await NestFactory.create(ApiModule);
|
||||
app.enableShutdownHooks();
|
||||
app.setGlobalPrefix('api/v1');
|
||||
await app.listen(3000, '0.0.0.0');
|
||||
}
|
||||
|
||||
if (require.main === module) {
|
||||
void bootstrapApi();
|
||||
}
|
||||
Reference in New Issue
Block a user