chore(env): Adding required env inside chaosengine (#479)

Signed-off-by: shubhamchaudhary <shubham@chaosnative.com>
This commit is contained in:
Shubham Chaudhary
2021-07-13 15:56:12 +05:30
committed by GitHub
parent b170f84c4d
commit a5af71f24a
51 changed files with 300 additions and 154 deletions

View File

@@ -16,14 +16,14 @@ spec:
spec:
components:
env:
# provide the chaos interval
- name: CHAOS_INTERVAL
value: '10'
# provide the total chaos duration
- name: TOTAL_CHAOS_DURATION
value: '20'
# provide the chaos interval
- name: CHAOS_INTERVAL
value: '10'
# provide the name of container runtime
# for litmus LIB, it supports docker, containerd, crio
# for pumba LIB, it supports docker only
@@ -33,4 +33,10 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'
- name: PODS_AFFECTED_PERC
value: ''
- name: TARGET_CONTAINER
value: ''

View File

@@ -20,28 +20,27 @@ spec:
spec:
components:
env:
# specify the name of the container to be killed
- name: TARGET_CONTAINER
value: 'nginx'
# provide the total chaos duration
- name: TOTAL_CHAOS_DURATION
value: '20'
# provide the chaos interval
- name: CHAOS_INTERVAL
value: '10'
# provide the total chaos duration
- name: TOTAL_CHAOS_DURATION
value: '20'
- name: LIB_IMAGE
value: 'litmuschaos/go-runner:latest'
# provide the name of container runtime
# it supports docker, containerd, crio
# default to docker
# for litmus LIB, it supports docker, containerd, crio
# for pumba LIB, it supports docker only
- name: CONTAINER_RUNTIME
value: 'docker'
# provide the container runtime path for containerd
# applicable only for containerd runtime
- name: CONTAINER_PATH
value: '/run/containerd/containerd.sock'
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'
- name: PODS_AFFECTED_PERC
value: ''
- name: TARGET_CONTAINER
value: ''

View File

@@ -18,10 +18,17 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: '60'
# specify the fill percentage according to the disk pressure required
- name: FILL_PERCENTAGE
value: '80'
- name: TARGET_CONTAINER
value: 'nginx'
- name: PODS_AFFECTED_PERC
value: ''
# Provide the container runtime path
# Default set to docker container path
- name: CONTAINER_PATH
value: '/var/lib/docker/containers'

View File

@@ -20,4 +20,4 @@ spec:
value: '90' # in seconds
- name: TARGET_NODE
value: 'node-01'
value: ''

View File

@@ -18,8 +18,8 @@ spec:
# kubernetes.io/hostname: 'node02'
env:
- name: TOTAL_CHAOS_DURATION
value: '90' # in seconds
value: '60' # in seconds
# provide the target node name
- name: TARGET_NODE
value: 'node-01'
value: ''

View File

@@ -52,7 +52,7 @@ spec:
env:
- name: TOTAL_CHAOS_DURATION
value: '90' # in seconds
value: '60' # in seconds
# Period to wait before and after injection of chaos in sec
- name: RAMP_TIME

View File

@@ -21,6 +21,10 @@ spec:
- name: NODE_CPU_CORE
value: ''
# ENTER THE COMMA SEPARATED TARGET NODES NAME
## percentage of total nodes to target
- name: NODES_AFFECTED_PERC
value: ''
# provide the comma separated target node names
- name: TARGET_NODES
value: ''

View File

@@ -17,6 +17,10 @@ spec:
# # provide the node labels
# kubernetes.io/hostname: 'node02'
env:
- name: TOTAL_CHAOS_DURATION
value: '60'
# enter the target node name
- name: TARGET_NODE
value: 'node-01'
value: ''

View File

@@ -30,6 +30,10 @@ spec:
- name: NUMBER_OF_WORKERS
value: '4'
## enter the comma separated target nodes name
## percentage of total nodes to target
- name: NODES_AFFECTED_PERC
value: ''
# provide the comma separated target node names
- name: TARGET_NODES
value: ''

View File

@@ -23,6 +23,10 @@ spec:
- name: MEMORY_CONSUMPTION_PERCENTAGE
value: '30'
# ENTER THE COMMA SEPARATED TARGET NODES NAME
## percentage of total nodes to target
- name: NODES_AFFECTED_PERC
value: ''
# provide the comma separated target node names
- name: TARGET_NODES
value: ''

View File

@@ -17,6 +17,9 @@ spec:
# # provide the node labels
# kubernetes.io/hostname: 'node02'
env:
- name: TOTAL_CHAOS_DURATION
value: '60'
# ENTER THE TARGET NODE NAME
- name: TARGET_NODE
value: ''
@@ -27,4 +30,4 @@ spec:
# ENTER THE USER TO BE USED FOR SSH AUTH
- name: SSH_USER
value: ''
value: 'root'

View File

@@ -55,10 +55,7 @@ spec:
value: 'root'
- name: TOTAL_CHAOS_DURATION
value: '360'
- name: EXPERIMENT_NAME
value: 'node-poweroff'
value: '60'
- name: REBOOT_COMMAND
value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true'

View File

@@ -17,9 +17,12 @@ spec:
# # provide the node labels
# kubernetes.io/hostname: 'node02'
env:
- name: TOTAL_CHAOS_DURATION
value: '60'
# ENTER THE TARGET NODE NAME
- name: TARGET_NODE
value: 'node01'
value: ''
# ENTER THE TARGET NODE IP
- name: TARGET_NODE_IP
@@ -27,4 +30,4 @@ spec:
# ENTER THE USER TO BE USED FOR SSH AUTH
- name: SSH_USER
value: ''
value: 'root'

View File

@@ -17,11 +17,15 @@ spec:
# # provide the node labels
# kubernetes.io/hostname: 'node02'
env:
- name: TOTAL_CHAOS_DURATION
value: '60'
# set target node name
- name: TARGET_NODE
value: 'node-01'
value: ''
# set taint label & effect
# key=value:effect or key:effect
- name: TAINTS
value: 'node.kubernetes.io/unreachable:NoExecute'
value: 'node.kubernetes.io/unreachable:NoExecute'

View File

@@ -16,10 +16,15 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
#number of cpu cores to be consumed
#verify the resources the app has been launched with
- name: CPU_CORES
value: '1'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
## Percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -17,8 +17,20 @@ spec:
spec:
components:
env:
- name: CPU_CORES
value: '1'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
- name: CPU_CORES
value: '1'
## Percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## provide the cluster runtime
- name: CONTAINER_RUNTIME
value: 'docker'
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'

View File

@@ -86,7 +86,6 @@ spec:
value: 'docker'
# provide the socket file path
# it is used in pumba lib
- name: SOCKET_PATH
value: '/var/run/docker.sock'

View File

@@ -27,3 +27,7 @@ spec:
# pod failures without '--force' & default terminationGracePeriodSeconds
- name: FORCE
value: 'false'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -31,3 +31,7 @@ spec:
# pod failures without '--force' & default terminationGracePeriodSeconds
- name: FORCE
value: 'false'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -17,6 +17,9 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: "60" # in seconds
# list of the target hostnames or kewywords eg. '["litmuschaos","chaosnative.io"]' . If empty all hostnames are targets
- name: TARGET_HOSTNAMES
value: ""
@@ -25,9 +28,6 @@ spec:
- name: MATCH_SCHEME
value: "exact"
- name: TOTAL_CHAOS_DURATION
value: "60" # in seconds
# provide the name of container runtime, it supports docker, containerd, crio
- name: CONTAINER_RUNTIME
value: "docker"
@@ -35,3 +35,7 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: "/var/run/docker.sock"
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ""

View File

@@ -17,13 +17,13 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: "60" # in seconds
# map of the target hostnames eg. '{"abc.com":"spoofabc.com"}' . If empty no queries will be spoofed
- name: SPOOF_MAP
value: '{"google.com":"fakegoogle.com"}'
- name: TOTAL_CHAOS_DURATION
value: "60" # in seconds
# provide the name of container runtime, it supports docker, containerd, crio
- name: CONTAINER_RUNTIME
value: "docker"
@@ -31,3 +31,7 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: "/var/run/docker.sock"
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ""

View File

@@ -24,5 +24,10 @@ spec:
- name: FILESYSTEM_UTILIZATION_PERCENTAGE
value: '10'
- name: TARGET_POD
value: ''
## provide the cluster runtime
- name: CONTAINER_RUNTIME
value: 'docker'
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'

View File

@@ -16,10 +16,14 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
# Enter the amount of memory in megabytes to be consumed by the application pod
- name: MEMORY_CONSUMPTION
value: '500'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -16,12 +16,21 @@ spec:
spec:
components:
env:
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
# Enter the amount of memory in megabytes to be consumed by the application pod
- name: MEMORY_CONSUMPTION
value: '500'
- name: NUMBER_OF_WORKERS
value: '1'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
## provide the cluster runtime
- name: CONTAINER_RUNTIME
value: 'docker'
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'

View File

@@ -86,8 +86,11 @@ spec:
- name: STRESS_IMAGE
value: 'alexeiled/stress-ng:latest-ubuntu'
## provide the cluster runtime
- name: CONTAINER_RUNTIME
value: 'docker'
# provide the socket file path
# it is used in pumba lib
- name: SOCKET_PATH
value: '/var/run/docker.sock'

View File

@@ -17,10 +17,6 @@ spec:
spec:
components:
env:
#Network interface inside target container
- name: NETWORK_INTERFACE
value: 'eth0'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
@@ -33,3 +29,10 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'
- name: NETWORK_PACKET_CORRUPTION_PERCENTAGE
value: '100' #in PERCENTAGE
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -21,10 +21,6 @@ spec:
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
#Network interface inside target container
- name: NETWORK_INTERFACE
value: 'eth0'
- name: NETWORK_PACKET_DUPLICATION_PERCENTAGE
value: '100'
@@ -37,3 +33,7 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -17,16 +17,12 @@ spec:
spec:
components:
env:
#Network interface inside target container
- name: NETWORK_INTERFACE
value: 'eth0'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
- name: NETWORK_LATENCY
value: '2000'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
# provide the name of container runtime
# for litmus LIB, it supports docker, containerd, crio
# for pumba LIB, it supports docker only
@@ -36,3 +32,7 @@ spec:
# provide the socket file path
- name: SOCKET_PATH
value: '/var/run/docker.sock'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -18,16 +18,11 @@ spec:
spec:
components:
env:
#Network interface inside target container
- name: NETWORK_INTERFACE
value: 'eth0'
- name: NETWORK_PACKET_LOSS_PERCENTAGE
value: '100'
- name: TOTAL_CHAOS_DURATION
value: '60' # in seconds
- name: NETWORK_PACKET_LOSS_PERCENTAGE
value: '100'
# provide the name of container runtime
# for litmus LIB, it supports docker, containerd, crio
@@ -39,3 +34,7 @@ spec:
- name: SOCKET_PATH
value: '/var/run/docker.sock'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''