port-4000-env
This commit is contained in:
parent
07eff63836
commit
bebfd46958
|
@ -1,5 +1,5 @@
|
||||||
FROM node:alpine
|
FROM node:alpine
|
||||||
EXPOSE 4242
|
EXPOSE 4000
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN npm install
|
RUN npm install
|
||||||
CMD npm start
|
CMD npm start
|
||||||
|
|
|
@ -9,7 +9,7 @@ const authorizer = new Authorizer({
|
||||||
|
|
||||||
const startServer = async () => {
|
const startServer = async () => {
|
||||||
const server = await Server.configure({
|
const server = await Server.configure({
|
||||||
port: 4242,
|
port: process.env.PORT || 4000,
|
||||||
async onConnect({ connection }) {
|
async onConnect({ connection }) {
|
||||||
connection.requiresAuthentication = true;
|
connection.requiresAuthentication = true;
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue
Block a user