mirror of
https://github.com/9technologygroup/patchmon.net.git
synced 2025-10-23 07:42:05 +00:00
Docker package-lock.json generation for each backend and frontend folder.
This commit is contained in:
2436
backend/package-lock.json
generated
Normal file
2436
backend/package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -4,13 +4,19 @@ RUN apk add --no-cache openssl
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY --chown=node:node package*.json /app/
|
||||
COPY --chown=node:node backend/ /app/backend/
|
||||
# Copy backend package files
|
||||
COPY --chown=node:node backend/package*.json /app/backend/
|
||||
|
||||
WORKDIR /app/backend
|
||||
|
||||
RUN npm ci --ignore-scripts &&\
|
||||
npx prisma generate &&\
|
||||
# Install backend dependencies (now has its own package-lock.json)
|
||||
RUN npm ci --ignore-scripts
|
||||
|
||||
# Copy backend source after dependencies are installed
|
||||
COPY --chown=node:node backend/ /app/backend/
|
||||
|
||||
# Generate Prisma client and clean up
|
||||
RUN npx prisma generate &&\
|
||||
npm prune --omit=dev &&\
|
||||
npm cache clean --force
|
||||
|
||||
|
@@ -2,14 +2,19 @@ FROM node:lts-alpine AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json ./
|
||||
# Copy frontend package files
|
||||
COPY frontend/package*.json ./frontend/
|
||||
|
||||
WORKDIR /app/frontend
|
||||
|
||||
# Install frontend dependencies (now has its own package-lock.json)
|
||||
RUN npm ci --ignore-scripts
|
||||
|
||||
COPY frontend/ ./frontend/
|
||||
# Copy frontend source after dependencies are installed
|
||||
COPY frontend/ ./
|
||||
|
||||
RUN npm run build:frontend
|
||||
# Build the frontend
|
||||
RUN npm run build
|
||||
|
||||
FROM nginxinc/nginx-unprivileged:alpine
|
||||
|
||||
|
2166
frontend/package-lock.json
generated
2166
frontend/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
9921
package-lock.json
generated
9921
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user