daemonset stress

This commit is contained in:
ducoterra
2021-02-11 12:57:15 -05:00
parent 7553034e1a
commit 5e0ec06802
4 changed files with 29 additions and 15 deletions

View File

@@ -60,8 +60,7 @@ dd if=/dev/zero of=/tmp/data bs=10M count=1024; dd if=/tmp/data of=$DISK/output;
```bash
kubectl exec -it $(kubectl get pod --selector=app=monitor --output=jsonpath={.items..metadata.name}) -c disk -- bash
export DISK=/tmp/hdd/
export DISK=/tmp/nvme/
export DISK=/mnt/test/
```
### Mainframe

View File

@@ -0,0 +1,25 @@
{{ if .Values.stress }}
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: stress-{{ .Release.Name }}
spec:
selector:
matchLabels:
app: stress-{{ .Release.Name }}
template:
metadata:
labels:
app: stress-{{ .Release.Name }}
spec:
containers:
- name: stress
image: hub.ducoterra.net/ducoterra/stress:latest
resources:
requests:
memory: 1Mi
cpu: 1m
limits:
memory: {{ .Values.stress_mem | quote }}
cpu: {{ .Values.stress_cpu | quote }}
{{ end }}

View File

@@ -56,17 +56,6 @@ spec:
- mountPath: /mnt/test
name: {{ .Release.Name }}
{{ end }}
{{ if .Values.stress }}
- name: stress
image: hub.ducoterra.net/ducoterra/stress:latest
resources:
requests:
memory: 128Mi
cpu: 1m
limits:
memory: 512Mi
cpu: {{ .Values.stress_cpu | quote }}
{{ end }}
{{ if .Values.exporter }}
- name: exporter
image: hub.ducoterra.net/ducoterra/glances:latest

View File

@@ -2,6 +2,7 @@ image: hub.ducoterra.net/ducoterra/temp:0.0.10
glances: true
iperf: true
disk: true
stress: false
stress_cpu: "6"
stress: true
stress_cpu: "16"
stress_mem: "16Gi"
exporter: true