-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
33 lines (22 loc) · 710 Bytes
/
Copy pathDockerfile
File metadata and controls
33 lines (22 loc) · 710 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
31
32
33
# --- Build stage ---
FROM node:20-alpine AS builder
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm install --ignore-scripts
COPY dist/ ./dist/
# Prune devDependencies, keep only production code
RUN npm prune --production
# --- Runtime stage ---
FROM node:20-alpine
LABEL maintainer="shilei"
LABEL description="SHP to 3D Tiles 1.1 converter"
# sharp requires these native libs on Alpine
RUN apk add --no-cache vips
WORKDIR /app
COPY --from=builder /app/dist ./dist
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package.json ./
# Create a directory for input/output data
RUN mkdir -p /data
ENTRYPOINT ["node", "dist/bin/shp-to-3dtiles.js"]
CMD ["--help"]