2022-03-25 15:26:55 -05:00
|
|
|
import { NestFactory } from '@nestjs/core';
|
|
|
|
|
import { AppModule } from './app.module';
|
2022-03-28 15:21:15 -05:00
|
|
|
import { Logger } from '@nestjs/common';
|
2022-03-25 15:26:55 -05:00
|
|
|
|
|
|
|
|
async function bootstrap() {
|
2022-03-27 14:58:54 -05:00
|
|
|
const app = await NestFactory.create(AppModule);
|
2022-03-25 15:26:55 -05:00
|
|
|
|
2022-07-01 16:20:04 +01:00
|
|
|
await app.listen(3003, () => {
|
2022-03-28 15:21:15 -05:00
|
|
|
if (process.env.NODE_ENV == 'development') {
|
|
|
|
|
Logger.log(
|
2022-06-11 16:12:06 -05:00
|
|
|
'Running Immich Machine Learning in DEVELOPMENT environment',
|
2022-03-28 15:21:15 -05:00
|
|
|
'IMMICH MICROSERVICES',
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (process.env.NODE_ENV == 'production') {
|
|
|
|
|
Logger.log(
|
2022-06-11 16:12:06 -05:00
|
|
|
'Running Immich Machine Learning in PRODUCTION environment',
|
2022-03-28 15:21:15 -05:00
|
|
|
'IMMICH MICROSERVICES',
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
});
|
2022-03-25 15:26:55 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bootstrap();
|