Add resource (CPU, memory, disk) monitoring and alerting for all Docker containers (frontend, backend, MongoDB, nginx) to proactively detect performance, resource exhaustion, and security issues.
Tech stack:
- Docker Compose (orchestrates Next.js frontend, Node.js backend, MongoDB, nginx)
- Deployed on DigitalOcean (with available Monitoring & Alerts, plus support for Prometheus/Grafana stack)
Action Items:
- Integrate
docker stats and container healthchecks for basic local resource visibility
- Set up a monitoring stack:
- Configure dashboards and email/Slack alerts for high CPU (>80%), memory usage, restarts, or service unavailability
- Optional: Add log forwarding to Loki, Sentry, or a cloud logging provider
Docker Compose Example:
services:
prometheus:
image: prom/prometheus
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- "9090:9090"
grafana:
image: grafana/grafana
ports:
- "3001:3000"
Acceptance Criteria:
- Grafana dashboard shows live resource usage for each service
- Alerts trigger on high resource conditions or container restarts
- Monitoring and alert setup documented in
backend/docs/ and/or frontend/docs/
Add resource (CPU, memory, disk) monitoring and alerting for all Docker containers (frontend, backend, MongoDB, nginx) to proactively detect performance, resource exhaustion, and security issues.
Tech stack:
Action Items:
docker statsand container healthchecks for basic local resource visibilityDocker Compose Example:
Acceptance Criteria:
backend/docs/and/orfrontend/docs/