add node exporter
This commit is contained in:
parent
7ff3f82d99
commit
1390b48039
4 changed files with 83 additions and 0 deletions
|
@ -6,6 +6,7 @@ resources:
|
||||||
# Pre Flux-Kustomizations
|
# Pre Flux-Kustomizations
|
||||||
- ./namespace.yaml
|
- ./namespace.yaml
|
||||||
# Flux-Kustomizations
|
# Flux-Kustomizations
|
||||||
|
- ./node-exporter/ks.yaml
|
||||||
- ./gatus/ks.yaml
|
- ./gatus/ks.yaml
|
||||||
# - ./smartctl-exporter/ks.yaml
|
# - ./smartctl-exporter/ks.yaml
|
||||||
# - ./victoria-metrics/ks.yaml
|
# - ./victoria-metrics/ks.yaml
|
||||||
|
|
|
@ -0,0 +1,57 @@
|
||||||
|
---
|
||||||
|
# yaml-language-server: $schema=https://ks.hsn.dev/helm.toolkit.fluxcd.io/helmrelease_v2.json
|
||||||
|
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||||
|
kind: HelmRelease
|
||||||
|
metadata:
|
||||||
|
name: node-exporter
|
||||||
|
spec:
|
||||||
|
interval: 30m
|
||||||
|
chart:
|
||||||
|
spec:
|
||||||
|
chart: prometheus-node-exporter
|
||||||
|
version: 4.38.0
|
||||||
|
sourceRef:
|
||||||
|
kind: HelmRepository
|
||||||
|
name: prometheus-community
|
||||||
|
namespace: flux-system
|
||||||
|
interval: 30m
|
||||||
|
values:
|
||||||
|
fullnameOverride: node-exporter
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: quay.io
|
||||||
|
repository: prometheus/node-exporter
|
||||||
|
|
||||||
|
prometheus:
|
||||||
|
monitor:
|
||||||
|
enabled: true
|
||||||
|
jobLabel: app.kubernetes.io/instance
|
||||||
|
|
||||||
|
relabelings:
|
||||||
|
- action: replace
|
||||||
|
regex: (.*)
|
||||||
|
replacement: $1
|
||||||
|
sourceLabels:
|
||||||
|
- __meta_kubernetes_pod_node_name
|
||||||
|
targetLabel: kubernetes_node
|
||||||
|
- action: replace
|
||||||
|
regex: (.*)
|
||||||
|
replacement: $1
|
||||||
|
sourceLabels:
|
||||||
|
- __meta_kubernetes_pod_node_name
|
||||||
|
targetLabel: nodename
|
||||||
|
- action: replace
|
||||||
|
regex: (.*)
|
||||||
|
replacement: $1.bjw-s.internal:9100
|
||||||
|
sourceLabels:
|
||||||
|
- kubernetes_node
|
||||||
|
targetLabel: instance
|
||||||
|
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 23m
|
||||||
|
memory: 64M
|
||||||
|
limits:
|
||||||
|
memory: 64M
|
||||||
|
|
||||||
|
hostNetwork: false
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
|
||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- ./helmrelease.yaml
|
19
kubernetes/apps/observability/node-exporter/ks.yaml
Normal file
19
kubernetes/apps/observability/node-exporter/ks.yaml
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
---
|
||||||
|
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/kustomization-kustomize-v1.json
|
||||||
|
apiVersion: kustomize.toolkit.fluxcd.io/v1
|
||||||
|
kind: Kustomization
|
||||||
|
metadata:
|
||||||
|
name: &app node-exporter
|
||||||
|
namespace: flux-system
|
||||||
|
spec:
|
||||||
|
targetNamespace: observability
|
||||||
|
commonMetadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: *app
|
||||||
|
interval: 10m
|
||||||
|
path: "./kubernetes/apps/observability/node-exporter/app"
|
||||||
|
prune: true
|
||||||
|
sourceRef:
|
||||||
|
kind: GitRepository
|
||||||
|
name: homelab
|
||||||
|
wait: false
|
Loading…
Reference in a new issue