diff --git a/services/monitoring/README.md b/services/monitoring/README.md index 775c301..832345a 100644 --- a/services/monitoring/README.md +++ b/services/monitoring/README.md @@ -1,5 +1,5 @@ # monitoring - + ## alloy **promtail Encrypt secrets:** @@ -13,3 +13,5 @@ sops -e deploy/alloy/global/secrets.dec.yaml > deploy/alloy/global/secrets.yaml ``` bash http://localhost:9090/agent ``` + +## prometheus - kube-state-metrics diff --git a/services/monitoring/deploy/alloy/kube-scraper/helm-values.yaml b/services/monitoring/deploy/alloy/kube-scraper/helm-values.yaml index e190f39..1f7211b 100644 --- a/services/monitoring/deploy/alloy/kube-scraper/helm-values.yaml +++ b/services/monitoring/deploy/alloy/kube-scraper/helm-values.yaml @@ -255,20 +255,18 @@ alloy: extraEnv: - - name: NODE_IP - valueFrom: - fieldRef: - fieldPath: status.hostIP - name: CLUSTER_NAME value: casa - name: ZONE value: casa-vlan + - name: LOKI_URL valueFrom: secretKeyRef: name: alloy-global key: loki_url + - name: PROMETHEUS_URL valueFrom: secretKeyRef: diff --git a/services/monitoring/deploy/flux/alloy-app-sync.yaml b/services/monitoring/deploy/flux/flux-kustomization-alloy.yaml similarity index 100% rename from services/monitoring/deploy/flux/alloy-app-sync.yaml rename to services/monitoring/deploy/flux/flux-kustomization-alloy.yaml diff --git a/services/monitoring/deploy/flux/flux-kustomization-prometheus.yaml b/services/monitoring/deploy/flux/flux-kustomization-prometheus.yaml new file mode 100644 index 0000000..23404fc --- /dev/null +++ b/services/monitoring/deploy/flux/flux-kustomization-prometheus.yaml @@ -0,0 +1,16 @@ +apiVersion: kustomize.toolkit.fluxcd.io/v1 +kind: Kustomization +metadata: + name: prometheus-kube-state-metrics +spec: + interval: 1m + sourceRef: + kind: GitRepository + name: casa + namespace: casa-limbosolutions-com + path: services/monitoring/deploy/prometheus + prune: true + decryption: + provider: sops + secretRef: + name: flux-sops-age diff --git a/services/monitoring/deploy/flux/kustomization.yaml b/services/monitoring/deploy/flux/kustomization.yaml index 5154b23..e1f9501 100644 --- a/services/monitoring/deploy/flux/kustomization.yaml +++ b/services/monitoring/deploy/flux/kustomization.yaml @@ -2,7 +2,8 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization namespace: monitoring resources: - - alloy-app-sync.yaml + - flux-kustomization-alloy.yaml + - flux-kustomization-prometheus.yaml secretGenerator: - name: flux-sops-age files: