Botanique/Dockerfile

24 lines
505 B
Text
Raw Normal View History

# syntax=docker/dockerfile:1
2023-11-25 17:59:58 +01:00
FROM node:21.2.0-bookworm-slim
ENV DOCKERIZED=1
RUN mkdir /config ;\
chown node:node /config ;\
2023-11-25 17:59:58 +01:00
apt-get update ;\
apt-get install -y dumb-init ffmpeg ;\
rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY --chown=node:node . .
ENV NODE_ENV=production
RUN npm ci --omit=dev ;\
2023-11-25 17:59:58 +01:00
npx tsc ;\
rm -r src/ tsconfig.json ;\
2023-11-25 17:59:58 +01:00
npm uninstall typescript @types/sqlite3 ;\
npm cache clean --force
ENV DP_FORCE_YTDL_MOD=youtube-ext
CMD ["dumb-init", "node", "./dist/index.js"]