87 lines
1.8 KiB
YAML
87 lines
1.8 KiB
YAML
apiVersion: litmuschaos.io/v1alpha1
|
|
description:
|
|
message: "Kills a container belonging to an application pod \n"
|
|
kind: ChaosExperiment
|
|
metadata:
|
|
name: container-kill
|
|
spec:
|
|
definition:
|
|
scope: Namespaced
|
|
permissions:
|
|
- apiGroups:
|
|
- ""
|
|
- "apps"
|
|
- "batch"
|
|
- "litmuschaos.io"
|
|
resources:
|
|
- "jobs"
|
|
- "pods"
|
|
- "pods/log"
|
|
- "events"
|
|
- "pods/exec"
|
|
- "chaosengines"
|
|
- "chaosexperiments"
|
|
- "chaosresults"
|
|
verbs:
|
|
- "create"
|
|
- "list"
|
|
- "get"
|
|
- "update"
|
|
- "patch"
|
|
- "delete"
|
|
- "deletecollection"
|
|
image: "litmuschaos/go-runner:latest"
|
|
imagePullPolicy: Always
|
|
args:
|
|
- -c
|
|
- ./experiments/container-kill
|
|
command:
|
|
- /bin/bash
|
|
env:
|
|
|
|
- name: TARGET_CONTAINER
|
|
value: ''
|
|
|
|
# Period to wait before and after injection of chaos in sec
|
|
- name: RAMP_TIME
|
|
value: ''
|
|
|
|
- name: LIB
|
|
value: 'litmus'
|
|
|
|
- name: TARGET_POD
|
|
value: ''
|
|
|
|
# provide the chaos interval
|
|
- name: CHAOS_INTERVAL
|
|
value: '10'
|
|
|
|
# provide the container runtime path
|
|
# applicable only for containerd and crio runtime
|
|
- name: CONTAINER_PATH
|
|
value: '/run/containerd/containerd.sock'
|
|
|
|
# provide the name of container runtime
|
|
# it supports docker, containerd, crio
|
|
# default to docker
|
|
- name: CONTAINER_RUNTIME
|
|
value: 'docker'
|
|
|
|
# provide the total chaos duration
|
|
- name: TOTAL_CHAOS_DURATION
|
|
value: '20'
|
|
|
|
## percentage of total pods to target
|
|
- name: PODS_AFFECTED_PERC
|
|
value: ''
|
|
|
|
- name: LIB_IMAGE
|
|
value: 'litmuschaos/go-runner:latest'
|
|
|
|
securityContext:
|
|
containerSecurityContext:
|
|
privileged: true
|
|
|
|
labels:
|
|
name: container-kill
|