Skip to content

Commit

Permalink
monitoring services start but config issues exist
Browse files Browse the repository at this point in the history
  • Loading branch information
GilHoggarth committed Nov 14, 2023
1 parent d5da420 commit 8104691
Show file tree
Hide file tree
Showing 12 changed files with 2,185 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,10 @@ monitor/grafana/provisioning/datasources/domain_crawl.yaml
monitor/prometheus/prometheus.yml

monitor/grafana/provisioning/dashboards/wa_status.json

# aws generated content
monitor/aws/alertmanager/config.yml
monitor/aws/grafana/datasources/frequent_crawl.yaml
monitor/aws/grafana/datasources/prometheus.yaml
monitor/aws/grafana/grafana.ini
monitor/aws/prometheus/prometheus.yml
16 changes: 16 additions & 0 deletions monitor/aws/alertmanager/config.yml-template
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
global:

# The directory from which notification templates are read.
templates:
- '/etc/alertmanager/template/*.tmpl'

# The root route on which each incoming alert enters.
route:
group_by: ['alertname', 'job']
group_wait: 30s
group_interval: 5m
repeat_interval: 12h
receiver: 'aws'

receivers:
- name: 'aws'
59 changes: 59 additions & 0 deletions monitor/aws/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
version: '3.2'
# prometheus monitoring service

services:
alertmanager:
image: prom/alertmanager
ports:
- "${ALERTMANAGER_PORT}:9093"
volumes:
- ./alertmanager:/etc/alertmanager
- "${ALERTMANAGER_DATA}:/alertmanager"
command:
- '--config.file=/etc/alertmanager/config.yml'
- '--storage.path=/alertmanager'
- '--web.external-url=http://${ALERTMANAGER_SERVICE_NAME}/'

pushgateway:
image: prom/pushgateway:v1.4.2
ports:
- 9091:9091

prometheus:
image: prom/prometheus:v2.30.3
ports:
- "${PROMETHEUS_PORT}:9090"
depends_on:
- alertmanager:alertmanager
- pushgateway:pushgateway
user: root
volumes:
- ./prometheus:/etc/prometheus
- "${PROMETHEUS_DATA}:/prometheus"
extra_hosts:
- 'fc:172.31.43.254'
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--storage.tsdb.retention.time=365d'
- '--web.console.libraries=/usr/share/prometheus/console_libraries'
- '--web.console.templates=/usr/share/prometheus/consoles'
- '--web.external-url=http://${PROMETHEUS_SERVICE_NAME}/'
- '--web.enable-admin-api'
- '--web.enable-lifecycle'

grafana:
image: grafana/grafana:7.5.7
ports:
- "${GRAFANA_PORT}:3000"
depends_on:
- prometheus
user: "1000"
environment:
- "GF_AUTH_ANONYMOUS_ENABLED=true"
- GF_AUTH_ANONYMOUS_ORG_NAME=${GRAFANA_ORG_NAME}
- "GF_AUTH_ANONYMOUS_ORG_ROLE=Viewer"
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_ADMIN_PASSWORD}
volumes:
- ./grafana:/etc/grafana
- "${GRAFANA_DATA}:/var/lib/grafana"
9 changes: 9 additions & 0 deletions monitor/aws/grafana/dashboards/blukwa.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: 1

providers:
- name: 'BLUKWA'
orgId: 1
folder: ''
type: file
options:
path: /etc/grafana/dashboards
Loading

0 comments on commit 8104691

Please sign in to comment.