# 21_Prometheus

## prometheus

<table id="bkmrk-imageprom%2Fprometheus"><tbody><tr><th>Image</th><td>`prom/prometheus:latest`</td></tr><tr><th>Etat</th><td><span style="color:#008000;">Up 9 hours</span></td></tr><tr><th>Compose project</th><td>gemini\_grafana</td></tr><tr><th>Reseau</th><td>gemini\_grafana\_monitor\_net</td></tr><tr><th>Source</th><td>[https://github.com/prometheus/prometheus](https://github.com/prometheus/prometheus)</td></tr></tbody></table>

### Ports

<table id="bkmrk-hotecontainerip90909"><thead><tr><th>Hote</th><th>Container</th><th>IP</th></tr></thead><tbody><tr><td>9090</td><td>9090/tcp</td><td>0.0.0.0</td></tr><tr><td>9090</td><td>9090/tcp</td><td>::</td></tr></tbody></table>

### Volumes

<table id="bkmrk-source-%28hote%29destina"><thead><tr><th>Source (hote)</th><th>Destination</th><th>Type</th><th>Mode</th></tr></thead><tbody><tr><td>`/opt/monitoring/prometheus.yml`</td><td>`/etc/prometheus/prometheus.yml`</td><td>bind</td><td>ro</td></tr><tr><td>`/opt/monitoring/prometheus_data`</td><td>`/prometheus`</td><td>bind</td><td>rw</td></tr></tbody></table>

---

## Integration Claude Code — API directe

<table id="bkmrk-statut-mcppas-de-mcp"><tbody><tr><th>Statut MCP</th><td><span style="color:orange">Pas de MCP — API directe possible</span></td></tr><tr><th>Note technique</th><td>API REST Prometheus sur /api/v1. Requêtes PromQL via /api/v1/query et /api/v1/query\_range. Pas de MCP configuré — appels directs via PowerShell/Python.</td></tr></tbody></table>

### Ce que nous pouvons faire ensemble

- Requêtes PromQL pour métriques CPU, RAM, réseau, containers
- Interroger l'historique d'un container ou du système sur une période
- Détecter des anomalies ou pics de consommation
- Lister les targets et leurs états (up/down)