Signed-off-by: shubhamchaudhary <shubham@chaosnative.com> Co-authored-by: Udit Gaurav <35391335+uditgaurav@users.noreply.github.com>
82 lines
1.7 KiB
YAML
82 lines
1.7 KiB
YAML
---
|
|
apiVersion: litmuschaos.io/v1alpha1
|
|
description:
|
|
message: |
|
|
Drain the node where application pod is scheduled
|
|
kind: ChaosExperiment
|
|
metadata:
|
|
name: node-drain
|
|
labels:
|
|
name: node-drain
|
|
app.kubernetes.io/part-of: litmus
|
|
app.kubernetes.io/component: chaosexperiment
|
|
app.kubernetes.io/version: latest
|
|
spec:
|
|
definition:
|
|
scope: Cluster
|
|
permissions:
|
|
- apiGroups:
|
|
- ""
|
|
- "batch"
|
|
- "litmuschaos.io"
|
|
- "apps"
|
|
resources:
|
|
- "jobs"
|
|
- "pods"
|
|
- "events"
|
|
- "pods/log"
|
|
- "pods/exec"
|
|
- "daemonsets"
|
|
- "pods/eviction"
|
|
- "chaosengines"
|
|
- "chaosexperiments"
|
|
- "chaosresults"
|
|
verbs:
|
|
- "create"
|
|
- "list"
|
|
- "get"
|
|
- "patch"
|
|
- "update"
|
|
- "delete"
|
|
- "deletecollection"
|
|
- apiGroups:
|
|
- ""
|
|
resources:
|
|
- "nodes"
|
|
verbs:
|
|
- "get"
|
|
- "list"
|
|
- "patch"
|
|
image: "litmuschaos/go-runner:latest"
|
|
imagePullPolicy: Always
|
|
args:
|
|
- -c
|
|
- ./experiments -name node-drain
|
|
command:
|
|
- /bin/bash
|
|
env:
|
|
|
|
- name: TARGET_NODE
|
|
value: ''
|
|
|
|
- name: NODE_LABEL
|
|
value: ''
|
|
|
|
- name: TOTAL_CHAOS_DURATION
|
|
value: '60'
|
|
|
|
# Provide the LIB here
|
|
# Only litmus supported
|
|
- name: LIB
|
|
value: 'litmus'
|
|
|
|
# Period to wait before and after injection of chaos in sec
|
|
- name: RAMP_TIME
|
|
value: ''
|
|
|
|
labels:
|
|
name: node-drain
|
|
app.kubernetes.io/part-of: litmus
|
|
app.kubernetes.io/component: experiment-job
|
|
app.kubernetes.io/version: latest
|