1
0
mirror of https://github.com/immich-app/immich.git synced 2025-08-09 23:17:29 +02:00

Improve Docker setup and reduce memory usage of production containers (#338)

This commit is contained in:
Fynn Petersen-Frey
2022-07-13 14:42:00 +02:00
committed by GitHub
parent ae7e582ec8
commit bece6253d5
7 changed files with 19 additions and 26 deletions

View File

@@ -46,12 +46,12 @@ async function bootstrap() {
customSiteTitle: 'Immich API Documentation',
});
// Generate API Documentation
const outputPath = path.resolve(process.cwd(), 'immich-openapi-specs.json');
writeFileSync(outputPath, JSON.stringify(apiDocument), { encoding: 'utf8' });
await app.listen(3001, () => {
if (process.env.NODE_ENV == 'development') {
// Generate API Documentation only in development mode
const outputPath = path.resolve(process.cwd(), 'immich-openapi-specs.json');
writeFileSync(outputPath, JSON.stringify(apiDocument), { encoding: 'utf8' });
Logger.log('Running Immich Server in DEVELOPMENT environment', 'ImmichServer');
}