NestJS crashing in run time
tahadk
PROOP

2 years ago

NestJS crashing in run time and restart without clean error

Project: 694a1186-3c22-49fe-a25d-eacbfc6592d8

Service: e3448011-a9df-48d9-a14e-d6146ce9e49f

Custom docker:

FROM node:16.20.2 As installation

WORKDIR /src

COPY package.json yarn.lock tsconfig.build.json ./

RUN yarn install --frozen-lockfile

FROM node:16.20.2 As build

WORKDIR /src

COPY --from=installation /src/node_modules ./node_modules

ENV NODE_ENV production

COPY . .

RUN yarn api-admin:build &&

yarn cache clean --force &&

curl -sf https://gobinaries.com/tj/node-prune | bash &&

node-prune /src/node_modules

FROM node:16.20.2 As production

WORKDIR /src

COPY --from=build /src/node_modules ./node_modules

COPY --from=installation /src/node_modules/adminjs/lib/frontend/assets ./node_modules/adminjs/lib/frontend/assets

COPY --from=build /src/dist ./dist

COPY ./assets ./assets

RUN mkdir -p ./apps/api-admin/src/uploads/

CMD ["node", "dist/apps/api-admin/apps/api-admin/src/main.js"]

EXPOSE 5000

View Deploy details

ⓘ Deployment information is only viewable by project members and Railway employees.

1 Replies

2 years ago

You are likely running out of memory, please upgrade to the Hobby plan for across to 8GB of memory and then redeploy.


Welcome!

Sign in to your Railway account to join the conversation.

Loading...