# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
# Stage 1: Build the TypeScript code
FROM node:18-alpine AS builder
# Set the working directory
WORKDIR /app
# Copy the package.json and package-lock.json files
COPY package.json tsconfig.json ./
# Install dependencies
RUN npm install
# Copy the source code
COPY src ./src
# Build the TypeScript code
RUN npm run build
# Stage 2: Create the production image
FROM node:18-alpine AS production
# Set the working directory
WORKDIR /app
# Copy the build artifacts and dependencies
COPY --from=builder /app/build ./build
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package.json ./
# Environment variables for MCP
ENV TENANT_ID=your-tenant-id
ENV CLIENT_ID=your-client-id
ENV CLIENT_SECRET=your-client-secret
# Run the application
CMD ["node", "build/index.js"]