diff --git a/charts/generic/generic.chartserviceversion.yaml b/charts/generic/generic.chartserviceversion.yaml index f1e1c37..426ae00 100644 --- a/charts/generic/generic.chartserviceversion.yaml +++ b/charts/generic/generic.chartserviceversion.yaml @@ -18,13 +18,15 @@ spec: - pod-cpu-hog - pod-network-latency - drain-node + - pod-network-corruption keywords: - Kubernetes - Container - - node - - pod - - disk + - Node + - Pod + - Disk + - Network maintainers: - name: ksatchit email: karthik.s@mayadata.io diff --git a/charts/generic/generic.package.yaml b/charts/generic/generic.package.yaml index cbc03a3..2297e04 100644 --- a/charts/generic/generic.package.yaml +++ b/charts/generic/generic.package.yaml @@ -27,3 +27,6 @@ experiments: - name: drain-node CSV: drain-node.chartserviceversion.yaml desc: "drain-node" + - name: pod-network-corruption + CSV: pod-network-corruption.chartserviceversion.yaml + desc: "pod-network-corruption" diff --git a/charts/generic/icons/pod-network-corruption.png b/charts/generic/icons/pod-network-corruption.png new file mode 100644 index 0000000..a5b0950 Binary files /dev/null and b/charts/generic/icons/pod-network-corruption.png differ diff --git a/charts/generic/pod-network-corruption/experiment.yaml b/charts/generic/pod-network-corruption/experiment.yaml new file mode 100644 index 0000000..4f9ed31 --- /dev/null +++ b/charts/generic/pod-network-corruption/experiment.yaml @@ -0,0 +1,58 @@ +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Inject network packet corruption into application pod +kind: ChaosExperiment +metadata: + name: pod-network-corruption + version: 0.1.0 +spec: + definition: + scope: Namespaced + permissions: + - apiGroups: + - "" + - "batch" + - "litmuschaos.io" + resources: + - "jobs" + - "pods" + - "chaosengines" + - "chaosexperiments" + - "chaosresults" + verbs: + - "create" + - "delete" + - "list" + - "patch" + - "get" + image: "litmuschaos/ansible-runner:ci" + args: + - -c + - ansible-playbook ./experiments/generic/pod_network_corruption/pod_network_corruption_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 + command: + - /bin/bash + env: + - name: ANSIBLE_STDOUT_CALLBACK + value: 'default' + + - name: TARGET_CONTAINER + value: '' + + # provide lib image + - name: LIB_IMAGE + value: 'gaiaadm/pumba:0.6.5' + + - name: NETWORK_INTERFACE + value: 'eth0' + + - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE + value: '100' #in PERCENTAGE + + - name: TOTAL_CHAOS_DURATION + value: '60000' #in ms + + - name: LIB + value: 'pumba' + labels: + name: pod-network-corruption diff --git a/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml b/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml new file mode 100644 index 0000000..2b36445 --- /dev/null +++ b/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml @@ -0,0 +1,39 @@ +apiVersion: litmuchaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-network-corruption + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: CNCF + support: https://slack.kubernetes.io/ +spec: + displayName: pod-network-corruption + categoryDescription: | + Pod-network-corruption contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject percentage packet corruption on the app replica pods. + - Causes packet corruption of application replica by injecting packet corruption using pumba. + - The application pod should be healthy once chaos is stopped. Service-requests should be served (say, via alternate replicas) despite chaos. + keywords: + - Kubernetes + - Network + - Corruption + platforms: + - GKE + maturity: alpha + maintainers: + - name: Shubham Chaudhary + email: shubham.chaudhary@mayadata.io + minKubeVersion: 1.12.0 + provider: + name: Mayadata + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Docs + url: https://docs.litmuschaos.io/docs/pod-network-corruption/ + icon: + - base64data: "" + mediatype: "" + chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-corruption/experiment.yaml