diff options
author | Anthony Wang | 2022-01-12 14:48:47 -0600 |
---|---|---|
committer | Anthony Wang | 2022-01-12 14:48:47 -0600 |
commit | ab5dd5c12a71e28297e9b0385f0162f75f72853a (patch) | |
tree | 5ad74b9a7db8684c921b7473e386f0074f296b2f | |
parent | 35726b7052d3f82fe01c448ae1911b6ca09baa48 (diff) |
Set socket.io port correctly
-rw-r--r-- | back/src/server.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/back/src/server.ts b/back/src/server.ts index c73162a..ee74aaf 100644 --- a/back/src/server.ts +++ b/back/src/server.ts @@ -3,7 +3,7 @@ import http from 'http'; import https from 'https'; import {Server} from 'socket.io'; -export default new Server({cors: {origin: process.env.ORIGIN, methods: ['GET', 'POST']}}); +export default new Server(Number(process.env.PORT!), {cors: {origin: process.env.ORIGIN, methods: ['GET', 'POST']}}); /*const base = process.env.SSL_KEY && process.env.SSL_CERT && process.env.SSL_CA ? https.createServer({ "key": fs.readFileSync(process.env.SSL_KEY), |