Restructuration of the project folders

This commit is contained in:
Sebastien Riviere
2026-02-13 16:06:50 +01:00
parent 5f16500634
commit c1f1688794
188 changed files with 265 additions and 301 deletions

View File

@@ -0,0 +1,30 @@
import { createServer } from "http";
import express from "express";
import { Server } from "socket.io";
import { config } from "dotenv";
import { initAdminSocketHandler } from "./admin_socket.js";
import { initTeamSocket } from "./team_socket.js";
import { initPhotoUpload } from "./photo.js";
config();
const HOST = process.env.HOST;
const PORT = process.env.PORT;
export const app = express();
const httpServer = createServer({}, app);
httpServer.listen(PORT, HOST, () => {
console.log("Server running on http://" + HOST + ":" + PORT);
});
export const io = new Server(httpServer, {
cors: {
origin: "*",
methods: ["GET", "POST"]
}
});
initAdminSocketHandler();
initTeamSocket();
initPhotoUpload();