1
0
mirror of https://github.com/spacebarchat/server.git synced 2024-09-19 01:02:27 +02:00

start listening before starting components in bundle

This commit is contained in:
Madeline 2023-04-24 23:42:25 +10:00
parent 1d19db52eb
commit eb62028103
No known key found for this signature in database
GPG Key ID: 1958E017C36F2E47

View File

@ -51,7 +51,9 @@ async function main() {
await Config.init();
await Sentry.init(app);
server.listen(port);
await new Promise((resolve) =>
server.listen({ port }, () => resolve(undefined)),
);
await Promise.all([api.start(), cdn.start(), gateway.start()]);
Sentry.errorHandler(app);