Initial commit - BraceIQMed platform with frontend, API, and brace generator
This commit is contained in:
36
api/Dockerfile
Normal file
36
api/Dockerfile
Normal file
@@ -0,0 +1,36 @@
|
||||
# ============================================
|
||||
# BraceIQMed API - Node.js Express Server
|
||||
# ============================================
|
||||
|
||||
FROM node:20-alpine
|
||||
|
||||
# Install build dependencies for better-sqlite3
|
||||
RUN apk add --no-cache python3 make g++ sqlite
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files
|
||||
COPY package*.json ./
|
||||
|
||||
# Install dependencies
|
||||
RUN npm ci --only=production
|
||||
|
||||
# Copy application code
|
||||
COPY . .
|
||||
|
||||
# Create data directories
|
||||
RUN mkdir -p /app/data/uploads /app/data/outputs
|
||||
|
||||
# Environment variables
|
||||
ENV NODE_ENV=production
|
||||
ENV PORT=3002
|
||||
ENV DATA_DIR=/app/data
|
||||
ENV DB_PATH=/app/data/braceflow.db
|
||||
|
||||
EXPOSE 3002
|
||||
|
||||
# Health check
|
||||
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
|
||||
CMD wget --no-verbose --tries=1 --spider http://localhost:3002/api/health || exit 1
|
||||
|
||||
CMD ["node", "server.js"]
|
||||
Reference in New Issue
Block a user