forked from gommzystudio/device-activity-tracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
30 lines (21 loc) · 612 Bytes
/
Dockerfile
File metadata and controls
30 lines (21 loc) · 612 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Backend Dockerfile
FROM node:20-alpine
WORKDIR /app
# Install git and build dependencies
RUN apk add --no-cache git python3 make g++
# Copy package files
COPY package*.json ./
COPY tsconfig.json ./
# Install dependencies (ignore postinstall script that tries to install client deps)
RUN npm install --ignore-scripts
# Copy source code
COPY src ./src
# Build TypeScript
RUN npm run build
# Expose port (can be overridden by environment variable)
ARG PORT=3001
ENV PORT=${PORT}
EXPOSE ${PORT}
# Create directory for WhatsApp auth state
RUN mkdir -p /app/baileys_auth_info
CMD ["node", "dist/server.js"]