chore: Migrate authentication to new tables (#1929)
This work provides a foundation for a more pluggable authentication system such as the one outlined in #1317. closes #1317
This commit is contained in:
@ -8,6 +8,7 @@ import { Document, Collection, View } from "./models";
|
||||
import policy from "./policies";
|
||||
import { client, subscriber } from "./redis";
|
||||
import { getUserForJWT } from "./utils/jwt";
|
||||
import { checkMigrations } from "./utils/startup";
|
||||
|
||||
const server = http.createServer(app.callback());
|
||||
let io;
|
||||
@ -191,7 +192,10 @@ server.on("listening", () => {
|
||||
console.log(`\n> Listening on http://localhost:${address.port}\n`);
|
||||
});
|
||||
|
||||
server.listen(process.env.PORT || "3000");
|
||||
(async () => {
|
||||
await checkMigrations();
|
||||
server.listen(process.env.PORT || "3000");
|
||||
})();
|
||||
|
||||
export const socketio = io;
|
||||
|
||||
|
Reference in New Issue
Block a user