| 1 |
version: '2' |
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
networks: |
| 7 |
monitoring: |
| 8 |
driver: bridge |
| 9 |
ipam: |
| 10 |
config: |
| 11 |
- subnet: 172.90.0.0/24 |
| 12 |
gateway: 172.90.0.1 |
| 13 |
|
| 14 |
services: |
| 15 |
prometheus: |
| 16 |
image: prom/prometheus:v2.40.5 |
| 17 |
restart: always |
| 18 |
|
| 19 |
|
| 20 |
volumes: |
| 21 |
- ./prometheus/:/etc/prometheus/ |
| 22 |
- ./prometheus_data:/prometheus/ |
| 23 |
command: |
| 24 |
- '--config.file=/etc/prometheus/prometheus.yml' |
| 25 |
- '--storage.tsdb.path=/prometheus' |
| 26 |
- '--storage.tsdb.retention.time=1y' |
| 27 |
- '--web.console.libraries=/etc/prometheus/console_libraries' |
| 28 |
- '--web.console.templates=/etc/prometheus/consoles' |
| 29 |
- '--web.enable-lifecycle' |
| 30 |
ports: |
| 31 |
|
| 32 |
|
| 33 |
- 127.0.0.1:9090:9090 |
| 34 |
networks: |
| 35 |
- monitoring |
| 36 |
extra_hosts: |
| 37 |
- "host.docker.internal:host-gateway" |
| 38 |
|
| 39 |
grafana: |
| 40 |
image: grafana/grafana:9.3.1 |
| 41 |
restart: always |
| 42 |
|
| 43 |
|
| 44 |
depends_on: |
| 45 |
- prometheus |
| 46 |
ports: |
| 47 |
- 127.0.0.1:8082:3000 |
| 48 |
volumes: |
| 49 |
- ./grafana_data:/var/lib/grafana |
| 50 |
- ./grafana/provisioning/:/etc/grafana/provisioning/ |
| 51 |
env_file: |
| 52 |
|
| 53 |
- ./grafana/config.monitoring |
| 54 |
networks: |
| 55 |
- monitoring |
| 56 |
|
| 57 |
certstream: |
| 58 |
image: 0rickyy0/certstream-server-go:latest |
| 59 |
restart: always |
| 60 |
|
| 61 |
|
| 62 |
ports: |
| 63 |
- 127.0.0.1:8080:80 |
| 64 |
|
| 65 |
|
| 66 |
volumes: |
| 67 |
- ./certstream/config.yml:/app/config.yml |
| 68 |
networks: |
| 69 |
- monitoring |