oidc routes need settings to be loaded

This commit is contained in:
Johannes Zellner
2023-03-15 13:38:26 +01:00
parent bb5f8b6452
commit ff697f8d33

View File

@@ -430,11 +430,12 @@ async function start() {
debug(` Cloudron ${constants.VERSION} `);
debug('==========================================');
gHttpServer = await initializeExpressSync();
await database.initialize();
await settings.initCache(); // pre-load very often used settings
await cloudron.initialize();
gHttpServer = await initializeExpressSync();
await util.promisify(gHttpServer.listen.bind(gHttpServer))(constants.PORT, '127.0.0.1');
await safe(eventlog.add(eventlog.ACTION_START, { userId: null, username: 'boot' }, { version: constants.VERSION })); // can fail if db down
}