-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile.node
More file actions
39 lines (28 loc) · 1.15 KB
/
Copy pathDockerfile.node
File metadata and controls
39 lines (28 loc) · 1.15 KB
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
31
32
33
34
35
36
37
38
39
FROM node:22-alpine
# Install git, sudo, Docker tooling, script(1) for browser agent-login PTYs,
# curl, jq, and build tools for native modules (better-sqlite3)
# curl and jq are required for deploy-pr.sh script execution
# docker-cli-compose provides 'docker compose' (v2) command
RUN apk add --no-cache git sudo docker-cli docker-cli-compose curl jq util-linux-misc python3 make g++
WORKDIR /usr/src/app
# Copy package files (including workspace packages)
COPY package*.json ./
COPY packages/shared/package*.json ./packages/shared/
COPY packages/core/package*.json ./packages/core/
COPY packages/api/package*.json ./packages/api/
# Install all dependencies (including dev for TypeScript compilation)
RUN npm install
# Copy application code
COPY . .
# Build shared package first (required for @propr/core imports)
RUN cd packages/shared && npm run build
# Build core package (required for @propr/core imports)
RUN cd packages/core && npm run build
# Build TypeScript (main app)
RUN npm run build
# Create necessary directories
RUN mkdir -p /tmp/git-processor
# Set environment
ENV NODE_ENV=production
# The command will be specified in docker-compose.yml
CMD ["node"]