build(docker): add Dockerfile, Docker Compose config, and update README

This commit is contained in:
2025-04-23 21:55:40 +08:00
parent 47de3823f3
commit 6daf1993d1
3 changed files with 93 additions and 34 deletions

23
Dockerfile Normal file
View File

@@ -0,0 +1,23 @@
# Use official Node.js LTS image
FROM node:18-alpine
# Create app directory
WORKDIR /app
# Install build dependencies and copy manifest
RUN apk add --no-cache python3 make g++
COPY package.json pnpm-lock.yaml ./
# Install dependencies
RUN npm ci
# Copy source code
COPY . .
# Expose no ports (Discord bot)
# Define default environment variables (optional)
ENV NODE_ENV=production
# Start the bot
CMD ["node", "src/index.js"]