version: '2.2' networks: monitor-net: driver: bridge volumes: prometheus_data: {} grafana_data: {} # db_data: {} services: prometheus: image: prom/prometheus:v2.22.1 container_name: prometheus volumes: - ./prometheus:/etc/prometheus - prometheus_data:/prometheus command: - '--config.file=/etc/prometheus/prometheus.yml' - '--storage.tsdb.path=/prometheus' - '--web.console.libraries=/etc/prometheus/console_libraries' - '--web.console.templates=/etc/prometheus/consoles' - '--storage.tsdb.retention.time=14d' - '--web.enable-lifecycle' restart: unless-stopped expose: - 9090 networks: - monitor-net labels: org.label-schema.group: "monitoring" alertmanager: image: prom/alertmanager:v0.21.0 container_name: alertmanager volumes: - ./alertmanager:/etc/alertmanager command: - '--config.file=/etc/alertmanager/config.yml' - '--storage.path=/alertmanager' restart: unless-stopped expose: - 9093 networks: - monitor-net labels: org.label-schema.group: "monitoring" nodeexporter: image: prom/node-exporter:v1.0.1 container_name: nodeexporter volumes: - /proc:/host/proc:ro - /sys:/host/sys:ro - /:/rootfs:ro command: - '--path.procfs=/host/proc' - '--path.rootfs=/rootfs' - '--path.sysfs=/host/sys' - '--collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)' restart: unless-stopped expose: - 9100 networks: - monitor-net labels: org.label-schema.group: "monitoring" cadvisor: image: gcr.io/cadvisor/cadvisor:v0.38.0 container_name: cadvisor volumes: - /:/rootfs:ro - /var/run:/var/run:rw - /sys:/sys:ro - /var/lib/docker:/var/lib/docker:ro #- /cgroup:/cgroup:ro #doesn't work on MacOS only for Linux restart: unless-stopped expose: - 8080 networks: - monitor-net labels: org.label-schema.group: "monitoring" grafana: image: grafana/grafana:7.3.1 container_name: grafana volumes: - grafana_data:/var/lib/grafana - ./grafana/provisioning:/etc/grafana/provisioning environment: - GF_SECURITY_ADMIN_USER=${ADMIN_USER:-admin} - GF_SECURITY_ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin} - GF_USERS_ALLOW_SIGN_UP=false - GF_RENDERING_SERVER_URL=http://grafana-image-renderer:8081/render - GF_RENDERING_CALLBACK_URL=http://grafana:3000/ - GF_LOG_FILTERS='rendering:debug' restart: unless-stopped expose: - 3000 networks: - monitor-net labels: org.label-schema.group: "monitoring" pushgateway: image: prom/pushgateway:v1.3.0 container_name: pushgateway restart: unless-stopped expose: - 9091 networks: - monitor-net labels: org.label-schema.group: "monitoring" caddy: image: stefanprodan/caddy container_name: caddy ports: - "3000:3000" - "9090:9090" - "9093:9093" - "9091:9091" volumes: - ./caddy:/etc/caddy environment: - ADMIN_USER=${ADMIN_USER:-admin} - ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin} restart: unless-stopped networks: - monitor-net labels: org.label-schema.group: "monitoring" # alertmanager_notifier: # image: ixdotai/alertmanager-notifier:latest # container_name: alertmanager-notifier # ports: # - "8899:8899" # environment: # - TELEGRAM_TOKEN="1476293190:AAHIHOyZ7Zyf2V-jrEgWELy0XlWHz_7mk48" # - TELEGRAM_CHAT_ID="-1001462755835" # - EXCLUDE_LABELS="yes" # restart: unless-stopped # networks: # - monitor-net # labels: # org.label-schema.group: "monitoring" grafana-image-renderer: image: grafana/grafana-image-renderer:latest container_name: grafana-image-renderer expose: - 8081 environment: - ENABLE_METRICS=true - HTTP_HOST=grafana-image-renderer - LOG_LEVEL=debug restart: unless-stopped networks: - monitor-net labels: org.label-schema.group: "monitoring" db: #image: mysql:5.7 image: mysql:8.0.22 container_name: db cpus: 4.0 cap_add: - SYS_NICE volumes: # - db_data:/var/lib/mysql - /home/ixyd/dev/dockprom/db:/var/lib/mysql - /home/ixyd/dev/wsjtx_dashboards:/wsjtx restart: always environment: MYSQL_ROOT_PASSWORD: verysecret MYSQL_DATABASE: digimode_stats MYSQL_USER: wsjtx MYSQL_PASSWORD: secret networks: - monitor-net labels: org.label-schema.group: "monitoring" mysqld-exporter: image: prom/mysqld-exporter container_name: mysqld-exporter restart: always environment: - DATA_SOURCE_NAME=root:verysecret@(db:3306)/digimode_stats expose: - 9104 networks: - monitor-net labels: org.label-schema.group: "monitoring" wsjtx_exporter: image: localhost:5000/wsjtx_exporter:latest container_name: wsjtx_exporter volumes: - /home/ixyd/.local/share/WSJT-X:/wsjtx expose: - 2112 environment: - PROMETHEUS=true - MYSQL=true - TRACE=true - STATION=DL3SD restart: unless-stopped networks: - monitor-net labels: org.label-schema.group: "monitoring" pskreporter_exporter: image: localhost:5000/pskreporter_exporter:latest container_name: pskreporter_exporter expose: - 2112 environment: - PROMETHEUS=true - MYSQL=true - TRACE=true - STATION=DL3SD restart: unless-stopped networks: - monitor-net labels: org.label-schema.group: "monitoring"