Skip to content

Commit

Permalink
Merge pull request #235 from OT-CONTAINER-KIT/tapan_k8s_events
Browse files Browse the repository at this point in the history
Collect Kubernetes events
  • Loading branch information
ashwani-opstree authored Aug 28, 2024
2 parents f10d5f5 + 5d419a5 commit 9d60b6f
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 2 deletions.
8 changes: 8 additions & 0 deletions charts/pga/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,11 @@ dependencies:
- thanos
alias: thanos
condition: thanos.enabled

- name: kubernetes-event-exporter
version: 3.2.10
repository: https://charts.bitnami.com/bitnami
alias: k8s-events
tags:
- monitoring
condition: k8s-events.enabled
46 changes: 44 additions & 2 deletions charts/pga/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ app:
service:
name: app-prometheus


kube:
enabled: true
fullnameOverride: kube
Expand Down Expand Up @@ -265,7 +266,6 @@ kube:
prometheus: kube
service:
name: kube-prometheus

pushgateway:
enabled: false
serviceMonitor:
Expand Down Expand Up @@ -313,5 +313,47 @@ blackbox:
adapter:
enabled: false

k8s-events:
enabled: true
serviceAccount:
create: false
metrics:
enabled: true
serviceMonitor:
enabled: true
labels:
prometheus: kube
release: monitoring
config:
logLevel: debug
logFormat: json
receivers:
- name: "loki"
loki:
url: http://logging-loki-gateway.logging.svc.cluster.local/loki/api/v1/push
layout:
message: "{{ .msg }}"
reason: "{{ .Reason }}"
type: "{{ .Type }}"
count: "{{ .Count }}"
kind: "{{ .InvolvedObject.Kind }}"
name: "{{ .InvolvedObject.Name }}"
namespace: "{{ .Namespace }}"
component: "{{ .Source.Component }}"
host: "{{ .Source.Host }}"
route:
routes:
- match:
- receiver: "loki"

rbac:
rules:
- apiGroups: [metrics.k8s.io]
resources: [pods, nodes]
verbs: [get, list, watch]
- apiGroups: ["*"]
resources: ["*"]
verbs: ["get", "watch", "list"]

thanos:
enabled: false
enabled: false

0 comments on commit 9d60b6f

Please sign in to comment.