serve compiled js files instead of compile on demand, because it no need more than 2 minutes

This commit is contained in:
einhornimmond 2024-12-20 18:33:31 +01:00
parent 722e7128a3
commit d4ce7539e2
2 changed files with 8 additions and 3 deletions

View File

@ -76,7 +76,7 @@ FROM build as test
RUN apk add --no-cache bash jq
# Run command
CMD /bin/sh -c "yarn run dev"
CMD /bin/sh -c "yarn run start"
##################################################################################
# PRODUCTION (Does contain only "binary"- and static-files to reduce image size) #

View File

@ -1,10 +1,15 @@
// Imports
const dotenv = require('dotenv')
const express = require('express')
const path = require('path')
dotenv.config() // load env vars from .env
const CONFIG = require('../src/config')
// Host & Port
const hostname = '127.0.0.1'
const port = process.env.PORT || 3000
const hostname = CONFIG.FRONTEND_MODULE_HOST
const port = CONFIG.FRONTEND_MODULE_PORT
// Express Server
const app = express()