-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile
35 lines (25 loc) · 883 Bytes
/
Dockerfile
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
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
# Use a Node.js image with the appropriate version
FROM node:16-alpine AS builder
# Set working directory
WORKDIR /app
# Copy package.json and package-lock.json for dependency installation
COPY package.json package.json
# Install dependencies
RUN npm install --ignore-scripts
# Copy the rest of the application source code
COPY . .
# Build the TypeScript project
RUN npm run build
# Prepare the runtime environment
FROM node:16-alpine AS release
# Set working directory
WORKDIR /app
# Copy built files and necessary configuration
COPY --from=builder /app/build /app/build
COPY --from=builder /app/package.json /app/package.json
# Set environment variables
ENV OPENCTI_URL=https://your-opencti-url
ENV OPENCTI_TOKEN=your-opencti-token
# Run the server
ENTRYPOINT ["node", "build/index.js"]