Skip to content

Commit

Permalink
Update node exporter in line with documentation (#107)
Browse files Browse the repository at this point in the history
* node-exporter: stop generating config with helm

* node-exporter: update config in line with prom docs

* https://github.com/prometheus/node_exporter/tree/v0.18.1#using-docker

Fixes #106
  • Loading branch information
errm committed May 13, 2020
1 parent 5aba969 commit 9d4f011
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 29 deletions.
1 change: 0 additions & 1 deletion hack/generate_addons.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ helm_template() {
helm_template eks aws-node-termination-handler 0.7.3
helm_template stable cluster-autoscaler 7.2.0
helm_template stable metrics-server 2.10.1
helm_template stable prometheus-node-exporter 1.9.1
7 changes: 0 additions & 7 deletions modules/cluster/addons/helm/prometheus-node-exporter.yaml

This file was deleted.

30 changes: 9 additions & 21 deletions modules/cluster/addons/prometheus-node-exporter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ metadata:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
spec:
privileged: false
# Required to prevent escalations to root.
Expand Down Expand Up @@ -60,7 +59,6 @@ metadata:
namespace: kube-system
labels:
app: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
release: "prometheus-node-exporter"
imagePullSecrets:
[]
Expand All @@ -73,7 +71,6 @@ metadata:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
rules:
- apiGroups: ['extensions']
resources: ['podsecuritypolicies']
Expand All @@ -89,7 +86,6 @@ metadata:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
Expand All @@ -110,7 +106,6 @@ metadata:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
spec:
type: ClusterIP
ports:
Expand All @@ -131,7 +126,6 @@ metadata:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
spec:
selector:
matchLabels:
Expand All @@ -146,7 +140,6 @@ spec:
labels:
app: prometheus-node-exporter
release: prometheus-node-exporter
chart: prometheus-node-exporter-1.9.1
spec:
serviceAccountName: prometheus-node-exporter
securityContext:
Expand All @@ -157,8 +150,8 @@ spec:
image: "prom/node-exporter:v0.18.1"
imagePullPolicy: IfNotPresent
args:
- --path.procfs=/host/proc
- --path.sysfs=/host/sys
- --collector.filesystem.ignored-mount-points=^/(dev|var/lib/docker|proc|sys|var/lib/kubelet)($|/)
- --path.rootfs=/host
- --web.listen-address=$(HOST_IP):9100
env:
- name: HOST_IP
Expand All @@ -170,32 +163,27 @@ spec:
livenessProbe:
httpGet:
path: /
port: 9100
port: metrics
readinessProbe:
httpGet:
path: /
port: 9100
port: metrics
resources:
limits:
memory: 64Mi
requests:
cpu: 32m
volumeMounts:
- name: proc
mountPath: /host/proc
- name: host
mountPath: /host
readOnly: true
- name: sys
mountPath: /host/sys
readOnly: true
mountPropagation: HostToContainer
hostNetwork: true
hostPID: true
tolerations:
- effect: NoSchedule
operator: Exists
volumes:
- name: proc
- name: host
hostPath:
path: /proc
- name: sys
hostPath:
path: /sys
path: /

0 comments on commit 9d4f011

Please sign in to comment.