api/server.js aktualisiert
Some checks failed
Publish Docker image / Push Docker image to Docker Hub (push) Has been cancelled
Some checks failed
Publish Docker image / Push Docker image to Docker Hub (push) Has been cancelled
This commit is contained in:
parent
14e2141edf
commit
6ebed49646
@ -1,7 +1,16 @@
|
||||
const httpServer = require("http").createServer();
|
||||
const express = require("express");
|
||||
const app = express();
|
||||
const httpServer = require("http").createServer(app);
|
||||
const path = require('path');
|
||||
|
||||
const io = require("socket.io")(httpServer, {cors: {origin: "*", connectionStateRecovery: {
|
||||
maxDisconnectionDuration: 60000}}});
|
||||
|
||||
|
||||
app.use(express.static(path.join(__dirname, './dist')));
|
||||
|
||||
app.get('*', (req, res) => res.sendFile(path.join(__dirname, './dist', 'index.html')));
|
||||
|
||||
const rooms = {};
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user