My-Weekly-ToDo-List/Dockerfile
mARTin d92a8c7210 feat: add task actions (notes/delete) and refine animation logic
- Added 'onDelete' and 'onNotes' support to TaskItem.
- Implemented hover actions (Delete and Notes icons) for tasks.
- Added Notes Modal for editing task markdown content.
- Simplified navigation animation to remove blank flash (single-phase slide-in).
- Fixed syntax error in updateTask function.
- Updated styles for modal and task actions.
2026-02-01 12:25:53 +01:00

35 lines
754 B
Docker

# Use the official Node.js 18 slim image as base
FROM node:18-slim
# Set working directory
WORKDIR /app
# Create necessary directories with proper permissions
RUN mkdir -p /app/.next /app/logs /app/node_modules
RUN chmod 777 /app/.next /app/logs
# Copy package files
COPY package*.json ./
# Install all dependencies
RUN npm install
# Copy application code
COPY . .
# Expose port
EXPOSE 3000
# Create non-root user for security
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 nextjs
RUN chown -R nextjs:nodejs /app
USER nextjs
# Health check
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
CMD curl -f http://localhost:3000/health || exit 1
# Run the development server
CMD ["npm", "run", "dev"]