refactor: slim down the backend containers (#4233)
* refactor: slim down the backend containers * refactor: make containers run as non-root user in container * chore: correct casing for the build stage definitions * chore: remove docker compose version field as its obsolete * chore: optimise chown and chmod into the COPY command itself * chore: add package overrides for packages with reported vulns * chore: add pnpm to containers + set workdir dir to the backend project * fix: permission issues with the fe containers * chore: define env variables on AIO
This commit is contained in:
@@ -51,7 +51,7 @@ fs.rmSync("build.env")
|
||||
|
||||
const caddyFileName = process.env.ENABLE_SUBPATH_BASED_ACCESS === 'true' ? 'aio-subpath-access.Caddyfile' : 'aio-multiport-setup.Caddyfile'
|
||||
const caddyProcess = runChildProcessWithPrefix("caddy", ["run", "--config", `/etc/caddy/${caddyFileName}`, "--adapter", "caddyfile"], "App/Admin Dashboard Caddy")
|
||||
const backendProcess = runChildProcessWithPrefix("pnpm", ["run", "start:prod"], "Backend Server")
|
||||
const backendProcess = runChildProcessWithPrefix("node", ["/dist/backend/dist/main.js"], "Backend Server")
|
||||
|
||||
caddyProcess.on("exit", (code) => {
|
||||
console.log(`Exiting process because Caddy Server exited with code ${code}`)
|
||||
|
||||
Reference in New Issue
Block a user