fix: switch to node:22-slim, install deps from npm, remove vendor
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
FROM node:22-alpine
|
||||
FROM node:22-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
@@ -6,11 +6,10 @@ WORKDIR /app
|
||||
RUN npm install -g pnpm
|
||||
|
||||
# Install build tools for native dependencies (node-crc, @discordjs/opus)
|
||||
# @discordjs/voice is a shared workspace dependency needed even by backend
|
||||
RUN apk add --no-cache python3 make g++
|
||||
RUN apt-get update -qq && apt-get install -y -qq --no-install-recommends python3 make g++ wget && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Create non-root user
|
||||
RUN addgroup -S app && adduser -S -G app app
|
||||
RUN groupadd --system app && useradd --system -g app app
|
||||
|
||||
# Copy dependency definition files first for better caching
|
||||
COPY pnpm-workspace.yaml .
|
||||
|
||||
Reference in New Issue
Block a user