Update Dockerfile
This commit is contained in:
parent
4d264630f3
commit
b9aed1ddf4
1 changed files with 11 additions and 12 deletions
23
Dockerfile
23
Dockerfile
|
|
@ -6,15 +6,15 @@ WORKDIR /app
|
|||
ENV NODE_ENV="production"
|
||||
|
||||
RUN apt-get update -qq && \
|
||||
apt-get install --no-install-recommends -y \
|
||||
build-essential \
|
||||
node-gyp \
|
||||
pkg-config \
|
||||
python-is-python3 \
|
||||
curl \
|
||||
ca-certificates \
|
||||
unzip && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
apt-get install --no-install-recommends -y \
|
||||
build-essential \
|
||||
node-gyp \
|
||||
pkg-config \
|
||||
python-is-python3 \
|
||||
curl \
|
||||
ca-certificates \
|
||||
unzip && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
FROM base-node AS build-main
|
||||
|
||||
|
|
@ -40,12 +40,11 @@ RUN bun install
|
|||
|
||||
COPY website/websocket/src ./src/
|
||||
|
||||
# Build websocket
|
||||
RUN bun build src/main.ts --outdir dist --target bun
|
||||
|
||||
FROM base-node AS production-main
|
||||
|
||||
COPY --from=build-main --chown=node:node /app/.svelte-kit/output ./build
|
||||
COPY --from=build-main --chown=node:node /app/build ./build
|
||||
COPY --from=build-main --chown=node:node /app/node_modules ./node_modules
|
||||
COPY --from=build-main --chown=node:node /app/package.json ./package.json
|
||||
|
||||
|
|
@ -54,7 +53,7 @@ RUN npm install -g pm2
|
|||
RUN echo 'module.exports = {\
|
||||
apps: [{\
|
||||
name: "rugplay-app",\
|
||||
script: "./build/server/index.js",\
|
||||
script: "./build/index.js",\
|
||||
instances: "max",\
|
||||
exec_mode: "cluster",\
|
||||
env: {\
|
||||
|
|
|
|||
Reference in a new issue