feat(docker): add Docker support and enhance dashboard data
- Add Dockerfile and docker-compose.yml for containerized deployment - Update server to listen on all network interfaces for Docker compatibility - Add .dockerignore to exclude unnecessary files from build context - Enhance dashboard controller with additional user data, trends, and suggestions - Update package.json scripts for proper Docker build workflow
This commit is contained in:
21
Dockerfile
Normal file
21
Dockerfile
Normal file
@@ -0,0 +1,21 @@
|
||||
FROM node:18-alpine
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Install build dependencies for native modules (sqlite3)
|
||||
RUN apk add --no-cache python3 make g++
|
||||
|
||||
COPY package*.json ./
|
||||
|
||||
RUN npm install
|
||||
|
||||
COPY . .
|
||||
|
||||
# Ensure data directory exists
|
||||
RUN mkdir -p data
|
||||
|
||||
RUN npm run build
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
CMD ["npm", "start"]
|
||||
Reference in New Issue
Block a user