Compare commits

...

2 Commits

8 changed files with 72 additions and 40532 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1,3 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: monitoring
resources:
- bundle.yaml
- https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.69.1/bundle.yaml
- servicemonitor.yaml

View File

@ -0,0 +1,13 @@
apiVersion: monitoring.coreos.com/v1
kind: Alertmanager
metadata:
name: core
namespace: monitoring
spec:
replicas: 1
alertmanagerConfigSelector:
matchLabels:
alertmanagerConfig: core
alertmanagerConfigMatcherStrategy:
type: None
logLevel: debug

View File

@ -0,0 +1,22 @@
apiVersion: monitoring.coreos.com/v1alpha1
kind: AlertmanagerConfig
metadata:
name: alertmanager-core-config
namespace: monitoring
labels:
alertmanagerConfig: core
spec:
route:
groupBy: ['alertname']
groupWait: 30s
groupInterval: 5m
repeatInterval: 1h
receiver: discord
continue: true
receivers:
- name: discord
discordConfigs:
- apiURL:
name: discord-webhook
key: url
sendResolved: true

View File

@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- alertmanager.yaml
- config.yaml
- service.yaml

View File

@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: alertmanager-svc
namespace: monitoring
spec:
ports:
- name: web
port: 9093
protocol: TCP
targetPort: web
selector:
alertmanager: discord

View File

@ -1,3 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- serviceaccount.yaml
- clusterrole.yaml
@ -6,3 +9,4 @@ resources:
- ingress.yaml
- servicemonitor.yaml
- prometheus.yaml
- alertmanager

View File

@ -7,9 +7,7 @@ spec:
serviceAccountName: prometheus
serviceMonitorNamespaceSelector: {}
serviceMonitorSelector: {}
podMonitorSelector:
matchLabels:
team: core
podMonitorSelector: {}
resources:
requests:
memory: 300Mi
@ -24,3 +22,10 @@ spec:
runAsNonRoot: true
fsGroup: 2000
runAsUser: 1000
alerting:
alertmanagers:
- namespace: monitoring
name: alertmanager-svc
port: web
ruleSelector: {}
ruleNamespaceSelector: {}