port and host in env

This commit is contained in:
Evert Prants 2022-08-22 20:51:37 +03:00
parent 6e90d40db4
commit 473e30e7fe
Signed by: evert
GPG Key ID: 1688DA83D222D0B5

View File

@ -46,6 +46,9 @@ async function bootstrap() {
app.setBaseViewsDir(join(__dirname, '..', 'views')); app.setBaseViewsDir(join(__dirname, '..', 'views'));
app.setViewEngine('pug'); app.setViewEngine('pug');
await app.listen(3000, '0.0.0.0'); await app.listen(
parseInt(process.env.NEST_PORT, 10) || 3000,
process.env.NEST_HOST || '0.0.0.0',
);
} }
bootstrap(); bootstrap();