(feat)chaos-charts: adding chaosengine yamls (#131)
* (feat)chaos-charts: adding chaosengine yamls Signed-off-by: aditya109 <adikid1996@gmail.com>
This commit is contained in:
30
charts/generic/container-kill/engine.yaml
Normal file
30
charts/generic/container-kill/engine.yaml
Normal file
@@ -0,0 +1,30 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: container-kill
|
||||
spec:
|
||||
components:
|
||||
# specify the name of the container to be killed
|
||||
env:
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
32
charts/generic/disk-fill/engine.yaml
Normal file
32
charts/generic/disk-fill/engine.yaml
Normal file
@@ -0,0 +1,32 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'false'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: disk-fill
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
# specify the fill percentage according to the disk pressure required
|
||||
- name: FILL_PERCENTAGE
|
||||
value: '80'
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
61
charts/generic/disk-loss/engine.yaml
Normal file
61
charts/generic/disk-loss/engine.yaml
Normal file
@@ -0,0 +1,61 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'false'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be retain/delete
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: disk-loss
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
# set chaos duration (in sec) as desired
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '60'
|
||||
# set cloud platform name
|
||||
- name: CLOUD_PLATFORM
|
||||
value: 'GCP'
|
||||
# set app_check to check application state
|
||||
- name: APP_CHECK
|
||||
value: 'true'
|
||||
# This is a chaos namespace into which all infra chaos resources are created
|
||||
- name: CHAOS_NAMESPACE
|
||||
value: 'default'
|
||||
# GCP project ID
|
||||
- name: PROJECT_ID
|
||||
value: 'litmus-demo-123'
|
||||
# Node name of the cluster
|
||||
- name: NODE_NAME
|
||||
value: 'demo-node-123'
|
||||
# Disk Name of the node, it must be an external disk.
|
||||
- name: DISK_NAME
|
||||
value: 'demo-disk-123'
|
||||
# Enter the device name which you wanted to mount only for AWS.
|
||||
- name: DEVICE_NAME
|
||||
value: '/dev/sdb'
|
||||
# Name of Zone in which node is present (GCP)
|
||||
# Use Region Name when running with AWS (ex: us-central1)
|
||||
- name: ZONE_NAME
|
||||
value: 'us-central1-a'
|
||||
# ChaosEngine CR name associated with the experiment instance
|
||||
- name: CHAOSENGINE
|
||||
value: ''
|
||||
# Service account used by the litmus
|
||||
- name: CHAOS_SERVICE_ACCOUNT
|
||||
value: ''
|
39
charts/generic/node-cpu-hog/engine.yaml
Normal file
39
charts/generic/node-cpu-hog/engine.yaml
Normal file
@@ -0,0 +1,39 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'false'
|
||||
auxiliaryAppInfo: 'ns1:name=percona,ns2:run=nginx'
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
# It can be true/false
|
||||
annotationCheck: 'false'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: cpu-hog
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
# set chaos duration (in sec) as desired
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '60'
|
||||
# set chaos platform as desired
|
||||
- name: PLATFORM
|
||||
value: 'GKE'
|
||||
# chaos lib used to inject the chaos
|
||||
- name: LIB
|
||||
value: 'litmus'
|
30
charts/generic/node-drain/engine.yaml
Normal file
30
charts/generic/node-drain/engine.yaml
Normal file
@@ -0,0 +1,30 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'false'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: node-drain
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
# set node name
|
||||
- name: APP_NODE
|
||||
value: 'node-1'
|
37
charts/generic/pod-cpu-hog/engine.yaml
Normal file
37
charts/generic/pod-cpu-hog/engine.yaml
Normal file
@@ -0,0 +1,37 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: pod-cpu-hog
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
||||
#number of cpu cores to be consumed
|
||||
#verify the resources the app has been launched with
|
||||
- name: CPU_CORES
|
||||
value: '1'
|
||||
# in ms
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '60000'
|
||||
|
36
charts/generic/pod-delete/engine.yaml
Normal file
36
charts/generic/pod-delete/engine.yaml
Normal file
@@ -0,0 +1,36 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
chaosServiceAccount: nginx-sa
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
experiments:
|
||||
- name: pod-delete
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
# set chaos duration (in sec) as desired
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '30'
|
||||
# set chaos interval (in sec) as desired
|
||||
- name: CHAOS_INTERVAL
|
||||
value: '10'
|
||||
# pod failures without '--force' & default terminationGracePeriodSeconds
|
||||
- name: FORCE
|
||||
value: 'false'
|
36
charts/generic/pod-network-corruption/engine.yaml
Normal file
36
charts/generic/pod-network-corruption/engine.yaml
Normal file
@@ -0,0 +1,36 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-network-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
# FYI, To see app label, apply kubectl get pods --show-labels
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
experiments:
|
||||
- name: pod-network-corruption
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
- name: ANSIBLE_STDOUT_CALLBACK
|
||||
value: 'default'
|
||||
#Container name where chaos has to be injected
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
||||
#Network interface inside target container
|
||||
- name: NETWORK_INTERFACE
|
||||
value: 'eth0'
|
44
charts/generic/pod-network-latency/engine.yaml
Normal file
44
charts/generic/pod-network-latency/engine.yaml
Normal file
@@ -0,0 +1,44 @@
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-network-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
# FYI, To see app label, apply kubectl get pods --show-labels
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
experiments:
|
||||
- name: pod-network-latency
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
- name: ANSIBLE_STDOUT_CALLBACK
|
||||
value: 'default'
|
||||
#Container name where chaos has to be injected
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
||||
#Network interface inside target container
|
||||
- name: NETWORK_INTERFACE
|
||||
value: 'eth0'
|
||||
- name: LIB_IMAGE
|
||||
value: 'gaiaadm/pumba:0.6.5'
|
||||
- name: NETWORK_LATENCY
|
||||
value: '2000'
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '60000'
|
||||
- name: LIB
|
||||
value: 'pumba'
|
45
charts/generic/pod-network-loss/engine.yaml
Normal file
45
charts/generic/pod-network-loss/engine.yaml
Normal file
@@ -0,0 +1,45 @@
|
||||
# chaosengine.yaml
|
||||
apiVersion: litmuschaos.io/v1alpha1
|
||||
kind: ChaosEngine
|
||||
metadata:
|
||||
name: nginx-network-chaos
|
||||
namespace: default
|
||||
spec:
|
||||
# It can be delete/retain
|
||||
jobCleanUpPolicy: 'delete'
|
||||
# It can be true/false
|
||||
annotationCheck: 'true'
|
||||
#ex. values: ns1:name=percona,ns2:run=nginx
|
||||
auxiliaryAppInfo: ''
|
||||
monitoring: false
|
||||
components:
|
||||
runner:
|
||||
image: 'litmuschaos/chaos-executor:1.0.0'
|
||||
type: 'go'
|
||||
appinfo:
|
||||
appns: 'default'
|
||||
# FYI, To see app label, apply kubectl get pods --show-labels
|
||||
applabel: 'app=nginx'
|
||||
appkind: 'deployment'
|
||||
chaosServiceAccount: nginx-sa
|
||||
experiments:
|
||||
- name: pod-network-loss
|
||||
spec:
|
||||
components:
|
||||
env:
|
||||
- name: ANSIBLE_STDOUT_CALLBACK
|
||||
value: 'default'
|
||||
#Container name where chaos has to be injected
|
||||
- name: TARGET_CONTAINER
|
||||
value: 'nginx'
|
||||
- name: LIB_IMAGE
|
||||
value: 'gaiaadm/pumba:0.6.5'
|
||||
#Network interface inside target container
|
||||
- name: NETWORK_INTERFACE
|
||||
value: 'eth0'
|
||||
- name: NETWORK_PACKET_LOSS_PERCENTAGE
|
||||
value: '100'
|
||||
- name: TOTAL_CHAOS_DURATION
|
||||
value: '60000'
|
||||
- name: LIB
|
||||
value: 'pumba'
|
Reference in New Issue
Block a user