mirror of
https://github.com/brendan-ch/project-inter-server.git
synced 2026-04-17 07:50:31 +00:00
read environment variable port with fallback to 4000
This commit is contained in:
@@ -26,7 +26,7 @@ async function main() {
|
|||||||
|
|
||||||
const { url } = await startStandaloneServer(server, {
|
const { url } = await startStandaloneServer(server, {
|
||||||
listen: {
|
listen: {
|
||||||
port: 4000,
|
port: process.env.PORT ? parseInt(process.env.PORT) : 4000,
|
||||||
},
|
},
|
||||||
context: async ({ req, res }) => {
|
context: async ({ req, res }) => {
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user