diff --git a/Dockerfile b/Dockerfile index f55c827..ec57d4a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -24,7 +24,8 @@ RUN pnpm run build FROM node:22 AS production # Set npm registry to Tencent Cloud and install pnpm globally -RUN npm install -g pnpm@latest +RUN pnpm config set registry https://mirrors.cloud.tencent.com/npm/ \ + && npm install -g pnpm@latest # Set the working directory inside the container WORKDIR /usr/src/app @@ -34,8 +35,7 @@ COPY --from=builder /usr/src/app/dist ./dist COPY --from=builder /usr/src/app/package.json /usr/src/app/pnpm-lock.yaml ./ # Install only production dependencies -RUN pnpm config set registry https://mirrors.cloud.tencent.com/npm/ \ - && pnpm install --prod +RUN pnpm install --prod # Expose the application port EXPOSE 3000