diff --git a/charts/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml b/charts/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml deleted file mode 100644 index bc01916..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-10T10:28:08Z - name: aws-ssm-chaos-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-ssm-chaos-by-id - categoryDescription: | - AWS SSM Chaos By ID contains chaos to disrupt the state of infra resources. The experiment can induce chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos experiments on resources. - - Causes chaos on AWS ec2 instances with given instance ID(s) using SSM docs for total chaos duration with the specified chaos interval. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). - keywords: - - SSM - - AWS - - EC2 - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm/aws-ssm-chaos-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws-ssm/aws-ssm-chaos-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml diff --git a/charts/aws-ssm/aws-ssm-chaos-by-id/engine.yaml b/charts/aws-ssm/aws-ssm-chaos-by-id/engine.yaml deleted file mode 100644 index 1133a5a..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-id/engine.yaml +++ /dev/null @@ -1,62 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: aws-ssm-chaos-by-id-sa - experiments: - - name: aws-ssm-chaos-by-id - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - # set chaos duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '60' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - # provide the region name of the target instances - - name: REGION - value: '' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' diff --git a/charts/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml b/charts/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml deleted file mode 100644 index ce4b100..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml +++ /dev/null @@ -1,124 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance IDs -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-id - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml b/charts/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml deleted file mode 100644 index 72db75e..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-ssm-chaos-by-id-sa - namespace: default - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: aws-ssm-chaos-by-id-sa - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for creating and managing to execute comands inside target container -- apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: aws-ssm-chaos-by-id-sa - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: aws-ssm-chaos-by-id-sa -subjects: -- kind: ServiceAccount - name: aws-ssm-chaos-by-id-sa - namespace: default diff --git a/charts/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml b/charts/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml deleted file mode 100644 index fea5b08..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-10T10:28:08Z - name: aws-ssm-chaos-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-ssm-chaos-by-tag - categoryDescription: | - AWS SSM Chaos By ID contains chaos to disrupt the state of infra resources. The experiment can induce chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos experiments on resources. - - Causes chaos on AWS ec2 instances with given instance tag using SSM docs for total chaos duration with the specified chaos interval. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). - keywords: - - SSM - - AWS - - EC2 - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm/aws-ssm-chaos-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws-ssm/aws-ssm-chaos-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml diff --git a/charts/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml b/charts/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml deleted file mode 100644 index 19d294b..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml +++ /dev/null @@ -1,62 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: aws-ssm-chaos-by-tag-sa - experiments: - - name: aws-ssm-chaos-by-tag - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - # set chaos duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '60' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - # provide the region name of the target instances - - name: REGION - value: '' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' diff --git a/charts/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml b/charts/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml deleted file mode 100644 index a0d6b95..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml +++ /dev/null @@ -1,128 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance Tag -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-tag - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # percentage of total instance to target - - name: INSTANCE_AFFECTED_PERC - value: '' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml b/charts/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml deleted file mode 100644 index 473d902..0000000 --- a/charts/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-ssm-chaos-by-tag-sa - namespace: default - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: aws-ssm-chaos-by-tag-sa - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for creating and managing to execute comands inside target container -- apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: aws-ssm-chaos-by-tag-sa - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: aws-ssm-chaos-by-tag-sa -subjects: -- kind: ServiceAccount - name: aws-ssm-chaos-by-tag-sa - namespace: default diff --git a/charts/aws-ssm/aws-ssm.chartserviceversion.yaml b/charts/aws-ssm/aws-ssm.chartserviceversion.yaml deleted file mode 100644 index ebfb1a8..0000000 --- a/charts/aws-ssm/aws-ssm.chartserviceversion.yaml +++ /dev/null @@ -1,36 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-11T10:28:08Z - name: aws-ssm - version: 0.1.0 - annotations: - categories: Kubernetes - chartDescription: Injects aws ssm chaos -spec: - displayName: AWS SSM - categoryDescription: > - aws ssm contains chaos to disrupt state of aws resources by litmus aws ssm docs - experiments: - - aws-ssm-chaos-by-id - - aws-ssm-chaos-by-tag - keywords: - - AWS - - SSM - - EC2 - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/icons/aws-ssm.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/experiments.yaml diff --git a/charts/aws-ssm/aws-ssm.package.yaml b/charts/aws-ssm/aws-ssm.package.yaml deleted file mode 100644 index cfae7ec..0000000 --- a/charts/aws-ssm/aws-ssm.package.yaml +++ /dev/null @@ -1,8 +0,0 @@ -packageName: aws-ssm -experiments: - - name: aws-ssm-chaos-by-id - CSV: aws-ssm-chaos-by-id.chartserviceversion.yaml - desc: "aws-ssm-chaos-by-id" - - name: aws-ssm-chaos-by-tag - CSV: aws-ssm-chaos-by-tag.chartserviceversion.yaml - desc: "aws-ssm-chaos-by-tag" \ No newline at end of file diff --git a/charts/aws-ssm/experiments.yaml b/charts/aws-ssm/experiments.yaml deleted file mode 100644 index 4e9da4b..0000000 --- a/charts/aws-ssm/experiments.yaml +++ /dev/null @@ -1,256 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance IDs -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-id - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance Tag -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-tag - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # percentage of total instance to target - - name: INSTANCE_AFFECTED_PERC - value: '' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/charts/aws-ssm/icons/aws-ssm-chaos-by-tag.png b/charts/aws-ssm/icons/aws-ssm-chaos-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/aws-ssm/icons/aws-ssm-chaos-by-tag.png and /dev/null differ diff --git a/charts/aws-ssm/icons/aws-ssm.png b/charts/aws-ssm/icons/aws-ssm.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/aws-ssm/icons/aws-ssm.png and /dev/null differ diff --git a/charts/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml b/charts/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml deleted file mode 100644 index ab5f152..0000000 --- a/charts/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: azure-disk-loss - version: 0.1.0 - annotations: - categories: Azure - vendor: ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: azure-disk-loss - categoryDescription: | - This experiment causes the detachment of the disk from the VM for a certain chaos duration - - Causes detachment of the disk from the VM and then reattachment of the disk to the VM - - It helps to check the performance of the application on the instance. - keywords: - - Azure - - Disk - - AKS - platforms: - - Azure - maturity: alpha - maintainers: - - name: avaakash - email: akash@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/azure/disk-loss/experiment - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/azure/azure-disk-loss/ - # - name: Video - # url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/azure-disk-loss/experiment.yaml \ No newline at end of file diff --git a/charts/azure/azure-disk-loss/engine.yaml b/charts/azure/azure-disk-loss/engine.yaml deleted file mode 100644 index 18d029f..0000000 --- a/charts/azure/azure-disk-loss/engine.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos -spec: - # It can be active/stop - engineState: 'active' - chaosServiceAccount: azure-disk-loss-sa - experiments: - - name: azure-disk-loss - 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: '30' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # provide the virtual disk names (comma separated if multiple) - - name: VIRTUAL_DISK_NAMES - value: '' \ No newline at end of file diff --git a/charts/azure/azure-disk-loss/experiment.yaml b/charts/azure/azure-disk-loss/experiment.yaml deleted file mode 100644 index 65ce54d..0000000 --- a/charts/azure/azure-disk-loss/experiment.yaml +++ /dev/null @@ -1,92 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaches disk from the VM and then re-attaches disk to the VM -kind: ChaosExperiment -metadata: - name: azure-disk-loss - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # provide the virtual disk names (comma separated if multiple) - - name: VIRTUAL_DISK_NAMES - value: '' - - # provide the sequence type for the run. Options: serial/parallel - - name: SEQUENCE - value: 'parallel' - - # provide the path to aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/azure/azure-disk-loss/rbac.yaml b/charts/azure/azure-disk-loss/rbac.yaml deleted file mode 100644 index 0e91994..0000000 --- a/charts/azure/azure-disk-loss/rbac.yaml +++ /dev/null @@ -1,64 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: azure-disk-loss-sa -subjects: -- kind: ServiceAccount - name: azure-disk-loss-sa - namespace: default \ No newline at end of file diff --git a/charts/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml b/charts/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml deleted file mode 100644 index a6db416..0000000 --- a/charts/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-02-20T10:28:08Z - name: azure-instance-stop - version: 0.1.0 - annotations: - categories: Azure - vendor: ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: azure-instance-stop - categoryDescription: | - This experiment causes the power off of an azure instance for a certain chaos duration. - - Causes termination of an azure instance before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the instance. - keywords: - - Azure - - Scaleset - - AKS - platforms: - - Azure - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: Chaos Native - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/azure/instance-stop/experiment - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/azure/azure-instance-stop/ - # - name: Video - # url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/azure-instance-stop/experiment.yaml - diff --git a/charts/azure/azure-instance-stop/experiment.yaml b/charts/azure/azure-instance-stop/experiment.yaml deleted file mode 100644 index 37be90e..0000000 --- a/charts/azure/azure-instance-stop/experiment.yaml +++ /dev/null @@ -1,91 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Terminating azure VM instance -kind: ChaosExperiment -metadata: - name: azure-instance-stop - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the target instance name(s) (comma separated if multiple) - - name: AZURE_INSTANCE_NAMES - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # Provide the path of aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - - name: SEQUENCE - value: 'parallel' - - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - diff --git a/charts/azure/azure-instance-stop/rbac.yaml b/charts/azure/azure-instance-stop/rbac.yaml deleted file mode 100644 index 323e2f3..0000000 --- a/charts/azure/azure-instance-stop/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: azure-instance-stop-sa - namespace: default - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: azure-instance-stop-sa - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: azure-instance-stop-sa - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: azure-instance-stop-sa -subjects: -- kind: ServiceAccount - name: azure-instance-stop-sa - namespace: default diff --git a/charts/azure/azure.chartserviceversion.yaml b/charts/azure/azure.chartserviceversion.yaml deleted file mode 100644 index a298c6d..0000000 --- a/charts/azure/azure.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-02-20T10:28:08Z - name: azure - version: 0.1.0 - annotations: - categories: Kubernetes - chartDescription: Injects chaos on azure servies -spec: - displayName: Azure - categoryDescription: > - Azure category of chaos experiments causes the disruption of the azure serives for a certain chaos duration. - experiments: - - azure-instance-stop - - azure-disk-loss - keywords: - - Azure - - Instance - - AKS - - Scaleset - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - provider: - name: Chaos Native - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/azure/experiments/azure - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#cloud-infrastructure - icon: - - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/experiments.yaml - diff --git a/charts/azure/experiments.yaml b/charts/azure/experiments.yaml deleted file mode 100644 index 7c27b7a..0000000 --- a/charts/azure/experiments.yaml +++ /dev/null @@ -1,187 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaches disk from the VM and then re-attaches disk to the VM -kind: ChaosExperiment -metadata: - name: azure-disk-loss - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # provide the virtual disk names (comma separated if multiple) - - name: VIRTUAL_DISK_NAMES - value: '' - - # provide the sequence type for the run. Options: serial/parallel - - name: SEQUENCE - value: 'parallel' - - # provide the path to aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Terminating azure VM instance -kind: ChaosExperiment -metadata: - name: azure-instance-stop - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the target instance name(s) (comma separated if multiple) - - name: AZURE_INSTANCE_NAMES - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # Provide the path of aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - - name: SEQUENCE - value: 'parallel' - - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - - ---- diff --git a/charts/gcp/experiments.yaml b/charts/gcp/experiments.yaml deleted file mode 100644 index 3cdda68..0000000 --- a/charts/gcp/experiments.yaml +++ /dev/null @@ -1,366 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop-by-label - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop-by-label - command: - - /bin/bash - 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: '30' - - - name: SEQUENCE - value: 'parallel' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Label of the target vm instance(s) - - name: INSTANCE_LABEL - value: '' - - # Zone in which the target vm instance(s) filtered by the label exist - # all the instances should lie in a single zone - - name: ZONES - value: '' - - # enable it if the target instance is a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # set the percentage value of the instances with the given label - # which should be targeted as part of the chaos injection - - name: INSTANCE_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # parallel or serial; determines how the VM instances are terminated, all at once or one at a time - - name: SEQUENCE - value: 'parallel' - - # period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable or disable; shall be set to enable if the target instances are a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # Instance name of the target vm instance(s) - # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - - name: VM_INSTANCE_NAMES - value: '' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their - # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - - name: ZONES - value: '' - - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss-by-label - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss-by-label - command: - - /bin/bash - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the zone in which all the disks are created - # all the disks must exist in the same zone - - name: ZONES - value: '' - - # set the label of the target disk volumes - - name: DISK_VOLUME_LABEL - value: '' - - # set the percentage value of the disks with the given label - # which should be targeted as part of the chaos injection - - name: DISK_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the disk volume name(s) as comma seperated values - # eg. volume1,volume2,... - - name: DISK_VOLUME_NAMES - value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME - # eg. zone1,zone2,... - - name: ZONES - value: '' - - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/charts/gcp/gcp-vm-disk-loss-by-label/experiment.yaml b/charts/gcp/gcp-vm-disk-loss-by-label/experiment.yaml deleted file mode 100644 index dd92aa5..0000000 --- a/charts/gcp/gcp-vm-disk-loss-by-label/experiment.yaml +++ /dev/null @@ -1,83 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss-by-label - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss-by-label - command: - - /bin/bash - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the zone in which all the disks are created - # all the disks must exist in the same zone - - name: ZONES - value: '' - - # set the label of the target disk volumes - - name: DISK_VOLUME_LABEL - value: '' - - # set the percentage value of the disks with the given label - # which should be targeted as part of the chaos injection - - name: DISK_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml b/charts/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml deleted file mode 100644 index 2aa5bee..0000000 --- a/charts/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-disk-loss-by-label - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-disk-loss-by-label - categoryDescription: > - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back - keywords: - - "Disk" - - "GCP" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-disk-loss-by-label/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-disk-loss-by-label/experiment.yaml diff --git a/charts/gcp/gcp-vm-disk-loss-by-label/rbac.yaml b/charts/gcp/gcp-vm-disk-loss-by-label/rbac.yaml deleted file mode 100644 index 3406523..0000000 --- a/charts/gcp/gcp-vm-disk-loss-by-label/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-disk-loss-by-label-sa - namespace: default - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-disk-loss-by-label-sa - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-disk-loss-by-label-sa - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-disk-loss-by-label-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-disk-loss-by-label-sa - namespace: default \ No newline at end of file diff --git a/charts/gcp/gcp-vm-disk-loss/experiment.yaml b/charts/gcp/gcp-vm-disk-loss/experiment.yaml deleted file mode 100644 index 24c37e1..0000000 --- a/charts/gcp/gcp-vm-disk-loss/experiment.yaml +++ /dev/null @@ -1,86 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the disk volume name(s) as comma seperated values - # eg. volume1,volume2,... - - name: DISK_VOLUME_NAMES - value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME - # eg. zone1,zone2,... - - name: ZONES - value: '' - - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml b/charts/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml deleted file mode 100644 index 452dffe..0000000 --- a/charts/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-disk-loss - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-disk-loss - categoryDescription: > - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back - keywords: - - "Disk" - - "GCP" - platforms: - - "GCP" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-disk-loss/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-disk-loss/experiment.yaml diff --git a/charts/gcp/gcp-vm-disk-loss/rbac.yaml b/charts/gcp/gcp-vm-disk-loss/rbac.yaml deleted file mode 100644 index 27c2072..0000000 --- a/charts/gcp/gcp-vm-disk-loss/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-disk-loss-sa - namespace: default - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-disk-loss-sa - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-disk-loss-sa - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-disk-loss-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-disk-loss-sa - namespace: default \ No newline at end of file diff --git a/charts/gcp/gcp-vm-instance-stop-by-label/experiment.yaml b/charts/gcp/gcp-vm-instance-stop-by-label/experiment.yaml deleted file mode 100644 index c4a68d1..0000000 --- a/charts/gcp/gcp-vm-instance-stop-by-label/experiment.yaml +++ /dev/null @@ -1,95 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop-by-label - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop-by-label - command: - - /bin/bash - 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: '30' - - - name: SEQUENCE - value: 'parallel' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Label of the target vm instance(s) - - name: INSTANCE_LABEL - value: '' - - # Zone in which the target vm instance(s) filtered by the label exist - # all the instances should lie in a single zone - - name: ZONES - value: '' - - # enable it if the target instance is a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # set the percentage value of the instances with the given label - # which should be targeted as part of the chaos injection - - name: INSTANCE_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml b/charts/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml deleted file mode 100644 index f14399d..0000000 --- a/charts/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-instance-stop-by-label - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-instance-stop-by-label - categoryDescription: > - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them - keywords: - - "VM" - - "GCP" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-instance-stop-by-label/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-instance-stop-by-label/experiment.yaml diff --git a/charts/gcp/gcp-vm-instance-stop-by-label/rbac.yaml b/charts/gcp/gcp-vm-instance-stop-by-label/rbac.yaml deleted file mode 100644 index f37f8f7..0000000 --- a/charts/gcp/gcp-vm-instance-stop-by-label/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-instance-stop-by-label-sa - namespace: default - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-instance-stop-by-label-sa - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-instance-stop-by-label-sa - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-instance-stop-by-label-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-instance-stop-by-label-sa - namespace: default \ No newline at end of file diff --git a/charts/gcp/gcp-vm-instance-stop/experiment.yaml b/charts/gcp/gcp-vm-instance-stop/experiment.yaml deleted file mode 100644 index facab7d..0000000 --- a/charts/gcp/gcp-vm-instance-stop/experiment.yaml +++ /dev/null @@ -1,94 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # parallel or serial; determines how the VM instances are terminated, all at once or one at a time - - name: SEQUENCE - value: 'parallel' - - # period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable or disable; shall be set to enable if the target instances are a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # Instance name of the target vm instance(s) - # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - - name: VM_INSTANCE_NAMES - value: '' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their - # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - - name: ZONES - value: '' - - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml b/charts/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml deleted file mode 100644 index 6b8aab2..0000000 --- a/charts/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-instance-stop - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-instance-stop - categoryDescription: > - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them - keywords: - - "VM" - - "GCP" - platforms: - - "GCP" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-instance-stop/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-instance-stop/experiment.yaml diff --git a/charts/gcp/gcp-vm-instance-stop/rbac.yaml b/charts/gcp/gcp-vm-instance-stop/rbac.yaml deleted file mode 100644 index 0592ea9..0000000 --- a/charts/gcp/gcp-vm-instance-stop/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-instance-stop-sa - namespace: default - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-instance-stop-sa - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-instance-stop-sa - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-instance-stop-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-instance-stop-sa - namespace: default \ No newline at end of file diff --git a/charts/gcp/gcp.chartserviceversion.yaml b/charts/gcp/gcp.chartserviceversion.yaml deleted file mode 100644 index bcf249e..0000000 --- a/charts/gcp/gcp.chartserviceversion.yaml +++ /dev/null @@ -1,38 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp chaos - categoryDescription: > - GCP contains chaos to disrupt state of gcp resources running part of the gcp services - experiments: - - gcp-vm-instance-stop - - gcp-vm-disk-loss - - gcp-vm-instance-stop-by-label - - gcp-vm-disk-loss-by-label - keywords: - - "VM" - - "Disk" - - "GCP" - - "Infra" - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - links: - - name: GCP Website - url: https://cloud.google.com/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#cloud-infrastructure - - name: Community Slack - url: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/experiments.yaml diff --git a/charts/generic/container-kill/container-kill.chartserviceversion.yaml b/charts/generic/container-kill/container-kill.chartserviceversion.yaml deleted file mode 100644 index 14db31c..0000000 --- a/charts/generic/container-kill/container-kill.chartserviceversion.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-15T10:28:08Z - name: container-kill - version: 0.1.13 - annotations: - categories: "Kubernetes" - vendor: "CNCF" - support: https://slack.openebs.io/ -spec: - displayName: container-kill - categoryDescription: | - Container kill contains chaos to disrupt state of kubernetes resources. Experiments can inject random container delete failures against specified application. - - Executes SIGKILL on containers of random replicas of an application deployment. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. - keywords: - - Kubernetes - - K8S - - Pod - - Container - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/container-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/container-kill/ - - name: Video - url: https://www.youtube.com/watch?v=XKyMNdVsKMo - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/container-kill/experiment.yaml diff --git a/charts/generic/container-kill/engine.yaml b/charts/generic/container-kill/engine.yaml deleted file mode 100644 index 399084c..0000000 --- a/charts/generic/container-kill/engine.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: container-kill-sa - experiments: - - name: container-kill - spec: - components: - env: - # 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 - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_CONTAINER - value: '' - \ No newline at end of file diff --git a/charts/generic/container-kill/engine_nginx_getstarted.yaml b/charts/generic/container-kill/engine_nginx_getstarted.yaml deleted file mode 100644 index df1430a..0000000 --- a/charts/generic/container-kill/engine_nginx_getstarted.yaml +++ /dev/null @@ -1,46 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: nginx -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'nginx' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: container-kill-sa - # It can be delete/retain - jobCleanUpPolicy: 'delete' - experiments: - - name: container-kill - spec: - components: - env: - # 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 - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_CONTAINER - value: '' - \ No newline at end of file diff --git a/charts/generic/container-kill/experiment.yaml b/charts/generic/container-kill/experiment.yaml deleted file mode 100644 index 905c73a..0000000 --- a/charts/generic/container-kill/experiment.yaml +++ /dev/null @@ -1,121 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: "Kills a container belonging to an application pod \n" -kind: ChaosExperiment -metadata: - name: container-kill - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name 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: TARGET_PODS - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - - name: SIGNAL - value: 'SIGKILL' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/container-kill/rbac-psp.yaml b/charts/generic/container-kill/rbac-psp.yaml deleted file mode 100644 index 12de772..0000000 --- a/charts/generic/container-kill/rbac-psp.yaml +++ /dev/null @@ -1,86 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: default - diff --git a/charts/generic/container-kill/rbac.yaml b/charts/generic/container-kill/rbac.yaml deleted file mode 100644 index ccea310..0000000 --- a/charts/generic/container-kill/rbac.yaml +++ /dev/null @@ -1,81 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: default - diff --git a/charts/generic/container-kill/rbac_nginx_getstarted.yaml b/charts/generic/container-kill/rbac_nginx_getstarted.yaml deleted file mode 100644 index 461b164..0000000 --- a/charts/generic/container-kill/rbac_nginx_getstarted.yaml +++ /dev/null @@ -1,78 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: nginx - diff --git a/charts/generic/disk-fill/engine.yaml b/charts/generic/disk-fill/engine.yaml deleted file mode 100644 index 5245c86..0000000 --- a/charts/generic/disk-fill/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: disk-fill-sa - experiments: - - name: disk-fill - 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: PODS_AFFECTED_PERC - value: '' - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' diff --git a/charts/generic/disk-fill/experiment.yaml b/charts/generic/disk-fill/experiment.yaml deleted file mode 100644 index 1f5e0a2..0000000 --- a/charts/generic/disk-fill/experiment.yaml +++ /dev/null @@ -1,123 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Fillup Ephemeral Storage of a Resource -kind: ChaosExperiment -metadata: - name: disk-fill - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name disk-fill - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: FILL_PERCENTAGE - value: '80' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the data block size - # supported unit is KB - - name: DATA_BLOCK_SIZE - value: '256' - - - name: TARGET_PODS - value: '' - - - name: EPHEMERAL_STORAGE_MEBIBYTES - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/host-path-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/disk-fill/rbac-psp.yaml b/charts/generic/disk-fill/rbac-psp.yaml deleted file mode 100644 index e7aa880..0000000 --- a/charts/generic/disk-fill/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: disk-fill-sa -subjects: -- kind: ServiceAccount - name: disk-fill-sa - namespace: default diff --git a/charts/generic/disk-fill/rbac.yaml b/charts/generic/disk-fill/rbac.yaml deleted file mode 100644 index 37a9d9a..0000000 --- a/charts/generic/disk-fill/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: disk-fill-sa -subjects: -- kind: ServiceAccount - name: disk-fill-sa - namespace: default diff --git a/charts/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml b/charts/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml deleted file mode 100644 index 0f629dd..0000000 --- a/charts/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-07-14T10:28:08Z - name: docker-service-kill - version: 0.1.1 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: docker-service-kill - categoryDescription: | - docker-service-kill contains killing docker service gracefully for a certain chaos duration. - - Causes replicas may be evicted or becomes unreachable on account on nodes turning unschedulable (Not Ready) due to docker service kill. - - The application node should be healthy once chaos is stopped and the services are reaccessable. - keywords: - - Kubernetes - - K8S - - Node - - Service - - Docker - platforms: - - GKE - - AKS - maturity: alpha - maintainers: - - name: Ankur Ghosh - email: ankur.ghosh3@wipro.com - minKubeVersion: 1.12.0 - provider: - name: Wipro - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/docker-service-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/docker-service-kill/ - - name: Video - url: - - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/docker-service-kill/experiment.yaml diff --git a/charts/generic/docker-service-kill/rbac-psp.yaml b/charts/generic/docker-service-kill/rbac-psp.yaml deleted file mode 100644 index cc1c8a9..0000000 --- a/charts/generic/docker-service-kill/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: docker-service-kill-sa - namespace: default - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: docker-service-kill-sa -subjects: -- kind: ServiceAccount - name: docker-service-kill-sa - namespace: default diff --git a/charts/generic/docker-service-kill/rbac.yaml b/charts/generic/docker-service-kill/rbac.yaml deleted file mode 100644 index 1972a97..0000000 --- a/charts/generic/docker-service-kill/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: docker-service-kill-sa - namespace: default - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: docker-service-kill-sa -subjects: -- kind: ServiceAccount - name: docker-service-kill-sa - namespace: default diff --git a/charts/generic/experiments.yaml b/charts/generic/experiments.yaml deleted file mode 100644 index 842cfa3..0000000 --- a/charts/generic/experiments.yaml +++ /dev/null @@ -1,3398 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give IO disk stress on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-io-stress - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-io-stress - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Number of core of CPU - - name: CPU - value: '1' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Total number of vm workers - - name: VM_WORKERS - value: '1' - - ## enter the comma separated target nodes name - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-latency - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: NETWORK_INTERFACE - value: 'eth0' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_LATENCY - value: '2000' #in ms - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: JITTER - value: '0' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - poweroff node -kind: ChaosExperiment -metadata: - name: node-poweroff - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: REBOOT_COMMAND - value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - it injects chaos into the pod which stops outgoing http requests by resetting the TCP connection and then reverts back to the original state after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-reset-peer - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-reset-peer - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # reset timeout specifies after how much duration to reset the connection - - name: RESET_TIMEOUT - value: '0' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects chaos inside the pod which modifies the status code of the response from the provided application server to desired status code provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-status-code - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-status-code - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # modified status code for the http response - # if no value is provided, a random status code from the supported code list will selected - # if an invalid status code is provided, the experiment will fail - # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504] - - name: STATUS_CODE - value: '' - - # whether to modify the body as per the status code provided - - name: "MODIFY_RESPONSE_BODY" - value: "true" - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a cpu spike on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-cpu-hog - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-cpu-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - - name: NODE_CPU_CORE - value: '' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog-exec - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/md5sum' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}')" - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the header of the request/response from the provided application server to the headers provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-header - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-header - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} - # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} - - name: HEADERS_MAP - value: '{}' - - # whether to modify response headers or request headers. Accepted values: request, response - - name: HEADER_MODE - value: 'response' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects http request latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-http-latency - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # set latency value for the chaos - - name: LATENCY - value: '2000' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Taint the node where application pod is scheduled -kind: ChaosExperiment -metadata: - name: node-taint - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-taint - command: - - /bin/bash - env: - - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # set taint label & effect - # key=value:effect or key:effect - - name: TAINTS - value: '' - - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet duplication on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-duplication - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-duplication - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: RAMP_TIME - value: '' - - - name: TARGET_CONTAINER - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE - value: '100' # in percentage - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Pod DNS Error injects dns failure/error in target pod containers -kind: ChaosExperiment -metadata: - name: pod-dns-error - labels: - name: pod-dns-error - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-dns-error - command: - - /bin/bash - env: - - name: TARGET_CONTAINER - value: "" - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: "" - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" - - - name: TARGET_PODS - value: "" - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: "parallel" - - # list of the target hostnames or kewywords eg. '["litmuschaos","chaosnative.io"]' . If empty all hostnames are targets - - name: TARGET_HOSTNAMES - value: "" - - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring - - name: MATCH_SCHEME - value: "exact" - - labels: - experiment: pod-dns-error - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames -kind: ChaosExperiment -metadata: - name: pod-dns-spoof - labels: - name: pod-dns-spoof - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-dns-spoof - command: - - /bin/bash - env: - - name: TARGET_CONTAINER - value: "" - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: "" - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" - - - name: TARGET_PODS - value: "" - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: "parallel" - - # map of the target hostnames eg. '{"abc.com":"spoofabc.com"}' . If empty no queries will be spoofed - - name: SPOOF_MAP - value: "" - - labels: - experiment: pod-dns-spoof - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: "Kills a container belonging to an application pod \n" -kind: ChaosExperiment -metadata: - name: container-kill - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name 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: TARGET_PODS - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - - name: SIGNAL - value: 'SIGKILL' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Inject network packet corruption into application pod -kind: ChaosExperiment -metadata: - name: pod-network-corruption - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-corruption - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-loss - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-loss - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects 100% network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-partition - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-partition - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide network policy type - # support ingress, egress, all values - - name: POLICY_TYPES - value: 'all' - - # provide labels of the destination pods - - name: POD_SELECTOR - value: '' - - # provide labels the destination namespaces - - name: NAMESPACE_SELECTOR - value: '' - - # provide comma separated ports - - name: PORTS - value: '' - - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- ---- -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: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - 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' - - # 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 - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the docker service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: docker-service-kill - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name docker-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '90' # in seconds - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-delete - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Restart node -kind: ChaosExperiment -metadata: - name: node-restart - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects memory consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-memory-hog - labels: - name: pod-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-memory-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## Number of workers to perform stress - - name: NUMBER_OF_WORKERS - value: '1' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - labels: - name: pod-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - IO stress on a app pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-io-stress - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-io-stress - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # provide volume mount path - - name: VOLUME_MOUNT_PATH - value: '' - - ## specify the comma separated target pods - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a memory hog on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-memory-hog - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-memory-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## Specify the size as percent of total node capacity Ex: '30' - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - - name: MEMORY_CONSUMPTION_PERCENTAGE - value: '' - - ## Specify the amount of memory to be consumed in mebibytes - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - - name: MEMORY_CONSUMPTION_MEBIBYTES - value: '' - - - name: NUMBER_OF_WORKERS - value: '1' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects memory consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-memory-hog-exec - labels: - name: pod-memory-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-memory-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/dd' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}' | head -n 1)" - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - - name: TARGET_PODS - value: '' - - labels: - name: pod-memory-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the kubelet service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: kubelet-service-kill - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name kubelet-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Scale the application replicas and test the node autoscaling on cluster -kind: ChaosExperiment -metadata: - name: pod-autoscaler - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-autoscaler - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Number of replicas to scale - - name: REPLICA_COUNT - value: '5' - - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the body of the response from the provided application server to the body string provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-body - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-body - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the body string to overwrite the response body - # if no value is provided, response will be an empty body. - - name: RESPONSE_BODY - value: '' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Fillup Ephemeral Storage of a Resource -kind: ChaosExperiment -metadata: - name: disk-fill - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name disk-fill - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: FILL_PERCENTAGE - value: '80' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the data block size - # supported unit is KB - - name: DATA_BLOCK_SIZE - value: '256' - - - name: TARGET_PODS - value: '' - - - name: EPHEMERAL_STORAGE_MEBIBYTES - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/host-path-usage: "true" - app.kubernetes.io/version: latest - ---- diff --git a/charts/generic/generic.chartserviceversion.yaml b/charts/generic/generic.chartserviceversion.yaml deleted file mode 100644 index 9042fb0..0000000 --- a/charts/generic/generic.chartserviceversion.yaml +++ /dev/null @@ -1,80 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-09-26T10:28:08Z - name: generic - version: 0.1.16 - annotations: - categories: Kubernetes - chartDescription: Injects generic kubernetes chaos -spec: - displayName: Generic Chaos - categoryDescription: > - Kubernetes is an open-source system for automating deployment, scaling, and management of containerized applications. It groups containers that make up an application into logical units for easier management and discovery. It will install all the experiments which can be used to inject chaos into containerized applications. - - experiments: - - pod-delete - - container-kill - - pod-cpu-hog - - pod-network-loss - - pod-network-latency - - pod-network-corruption - - node-drain - - node-cpu-hog - - disk-fill - - node-memory-hog - - pod-memory-hog - - kubelet-service-kill - - pod-network-duplication - - node-taint - - docker-service-kill - - pod-autoscaler - - node-io-stress - - pod-io-stress - - node-restart - - pod-dns-error - - pod-dns-spoof - - pod-cpu-hog-exec - - pod-memory-hog-exec - - pod-network-partition - - pod-http-latency - - pod-http-status-code - - pod-http-modify-header - - pod-http-modify-body - - pod-http-reset-peer - keywords: - - Kubernetes - - K8S - - Container - - Node - - Pod - - Disk - - IO - - Filesystem - - Network - - CPU - - Memory - - Stress - - Service - - DNS - - Scale - - Http - maintainers: - - name: ksatchit - email: karthik.s@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: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#generic - icon: - - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/experiments.yaml diff --git a/charts/generic/generic.package.yaml b/charts/generic/generic.package.yaml deleted file mode 100644 index 3dd250d..0000000 --- a/charts/generic/generic.package.yaml +++ /dev/null @@ -1,89 +0,0 @@ -packageName: generic -experiments: - - name: pod-delete - CSV: pod-delete.chartserviceversion.yaml - desc: "pod-delete" - - name: container-kill - CSV: container-kill.chartserviceversion.yaml - desc: "container-kill" - - name: pod-network-loss - CSV: pod-network-loss.chartserviceversion.yaml - desc: "Pod-network-loss" - - name: pod-network-latency - CSV: pod-network-latency.chartserviceversion.yaml - desc: "pod-network-latency" - - name: pod-cpu-hog - CSV: pod-cpu-hog.chartserviceversion.yaml - desc: "pod-cpu-hog" - - name: node-cpu-hog - CSV: node-cpu-hog.chartserviceversion.yaml - desc: "node-cpu-hog" - - name: disk-fill - CSV: disk-fill.chartserviceversion.yaml - desc: "disk-fill" - - name: node-drain - CSV: node-drain.chartserviceversion.yaml - desc: "node-drain" - - name: pod-network-corruption - CSV: pod-network-corruption.chartserviceversion.yaml - desc: "pod-network-corruption" - - name: node-memory-hog - CSV: node-memory-hog.chartserviceversion.yaml - desc: "node-memory-hog" - - name: pod-memory-hog - CSV: pod-memory-hog.chartserviceversion.yaml - desc: "pod-memory-hog" - - name: kubelet-service-kill - CSV: kubelet-service-kill.chartserviceversion.yaml - desc: "kubelet-service-kill" - - name: pod-network-duplication - CSV: pod-network-duplication.chartserviceversion.yaml - desc: "pod-network-duplication" - - name: node-taint - CSV: node-taint.chartserviceversion.yaml - desc: "node-taint" - - name: docker-service-kill - CSV: docker-service-kill.chartserviceversion.yaml - desc: "docker-service-kill" - - name: pod-autoscaler - CSV: pod-autoscaler.chartserviceversion.yaml - desc: "pod-autoscaler" - - name: node-io-stress - CSV: node-io-stress.chartserviceversion.yaml - desc: "node-io-stress" - - name: pod-io-stress - CSV: pod-io-stress.chartserviceversion.yaml - desc: "pod-io-stress" - - name: node-restart - CSV: node-restart.chartserviceversion.yaml - desc: "node-restart" - - name: pod-dns-error - CSV: pod-dns-error.chartserviceversion.yaml - desc: "pod-dns-error" - - name: pod-dns-spoof - CSV: pod-dns-spoof.chartserviceversion.yaml - desc: "pod-dns-spoof" - - name: pod-cpu-hog-exec - CSV: pod-cpu-hog-exec.chartserviceversion.yaml - desc: "pod-cpu-hog-exec" - - name: pod-memory-hog-exec - CSV: pod-memory-hog-exec.chartserviceversion.yaml - desc: "pod-memory-hog-exec" - - name: pod-network-partition - CSV: pod-network-partition.chartserviceversion.yaml - desc: "pod-network-partition" - - name: pod-http-latency - CSV: pod-http-latency.chartserviceversion.yaml - desc: "pod-http-latency" - - name: pod-http-status-code - CSV: pod-http-status-code.chartserviceversion.yaml - desc: "pod-http-status-code" - - name: pod-http-modify-header - CSV: pod-http-modify-header.chartserviceversion.yaml - desc: "pod-http-modify-header" - - name: pod-http-modify-body - CSV: pod-http-modify-body.chartserviceversion.yaml - desc: "pod-http-modify-body" - - name: pod-http-reset-peer - CSV: pod-http-reset-peer.chartserviceversion.yaml - desc: "pod-http-reset-peer" diff --git a/charts/generic/icons/byoc-pod-delete.png b/charts/generic/icons/byoc-pod-delete.png deleted file mode 100644 index 16aa7b4..0000000 Binary files a/charts/generic/icons/byoc-pod-delete.png and /dev/null differ diff --git a/charts/generic/kubelet-service-kill/experiment.yaml b/charts/generic/kubelet-service-kill/experiment.yaml deleted file mode 100644 index e844d28..0000000 --- a/charts/generic/kubelet-service-kill/experiment.yaml +++ /dev/null @@ -1,81 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the kubelet service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: kubelet-service-kill - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name kubelet-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml b/charts/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml deleted file mode 100644 index 65f3032..0000000 --- a/charts/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-06-13T10:28:08Z - name: kubelet-service-kill - version: 0.1.3 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: kubelet-service-kill - categoryDescription: | - kubelet-service-kill contains killing kubelet service gracefully for a certain chaos duration. - - Causes replicas may be evicted or becomes unreachable on account on nodes turning unschedulable (Not Ready) due to kubelet service kill. - - The application node should be healthy once chaos is stopped and the services are reaccessable. - - keywords: - - Kubernetes - - K8S - - Kubelet - - Node - - Service - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/kubelet-service-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/kubelet-service-kill/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/kubelet-service-kill/experiment.yaml diff --git a/charts/generic/kubelet-service-kill/rbac-psp.yaml b/charts/generic/kubelet-service-kill/rbac-psp.yaml deleted file mode 100644 index fb2dac3..0000000 --- a/charts/generic/kubelet-service-kill/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: kubelet-service-kill-sa - namespace: default - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: kubelet-service-kill-sa -subjects: -- kind: ServiceAccount - name: kubelet-service-kill-sa - namespace: default diff --git a/charts/generic/kubelet-service-kill/rbac.yaml b/charts/generic/kubelet-service-kill/rbac.yaml deleted file mode 100644 index 4840f37..0000000 --- a/charts/generic/kubelet-service-kill/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: kubelet-service-kill-sa - namespace: default - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: kubelet-service-kill-sa -subjects: -- kind: ServiceAccount - name: kubelet-service-kill-sa - namespace: default diff --git a/charts/generic/node-cpu-hog/experiment.yaml b/charts/generic/node-cpu-hog/experiment.yaml deleted file mode 100644 index 6a3459a..0000000 --- a/charts/generic/node-cpu-hog/experiment.yaml +++ /dev/null @@ -1,99 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a cpu spike on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-cpu-hog - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-cpu-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - - name: NODE_CPU_CORE - value: '' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml b/charts/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml deleted file mode 100644 index f479b53..0000000 --- a/charts/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-cpu-hog - version: 0.0.15 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-cpu-hog - categoryDescription: | - Node CPU hog contains chaos to disrupt the state of Kubernetes resources. Experiments can inject a CPU spike on a node where the application pod is scheduled. - - CPU hog on a particular node where the application deployment is available. - - After test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. - keywords: - - Kubernetes - - K8S - - CPU - - Node - platforms: - - GKE - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - chaosType: infra - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-cpu-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-cpu-hog/ - - name: Video - url: https://www.youtube.com/watch?v=jpJttftsZqA - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-cpu-hog/experiment.yaml diff --git a/charts/generic/node-cpu-hog/rbac-psp.yaml b/charts/generic/node-cpu-hog/rbac-psp.yaml deleted file mode 100644 index 4ae8ce7..0000000 --- a/charts/generic/node-cpu-hog/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-cpu-hog-sa - namespace: default - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: node-cpu-hog-sa - namespace: default diff --git a/charts/generic/node-cpu-hog/rbac.yaml b/charts/generic/node-cpu-hog/rbac.yaml deleted file mode 100644 index 40e88cd..0000000 --- a/charts/generic/node-cpu-hog/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-cpu-hog-sa - namespace: default - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: node-cpu-hog-sa - namespace: default diff --git a/charts/generic/node-drain/engine.yaml b/charts/generic/node-drain/engine.yaml deleted file mode 100644 index 65a4216..0000000 --- a/charts/generic/node-drain/engine.yaml +++ /dev/null @@ -1,26 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-drain-sa - experiments: - - name: node-drain - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - # enter the target node name - - name: TARGET_NODE - value: '' - \ No newline at end of file diff --git a/charts/generic/node-drain/experiment.yaml b/charts/generic/node-drain/experiment.yaml deleted file mode 100644 index c322907..0000000 --- a/charts/generic/node-drain/experiment.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -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: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - 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' - - # 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 diff --git a/charts/generic/node-drain/node-drain.chartserviceversion.yaml b/charts/generic/node-drain/node-drain.chartserviceversion.yaml deleted file mode 100644 index 9b513d9..0000000 --- a/charts/generic/node-drain/node-drain.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-13T10:28:08Z - name: node-drain - version: 0.1.12 - annotations: - categories: Kubernetes - vendor: Mayadata - repository: https://github.com/litmuschaos/chaos-charts - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: node-drain - categoryDescription: > - Drain the node where application pod is scheduled - keywords: - - Kubernetes - - K8S - - Node - - Drain - platforms: - - GKE - - AWS(KOPS) - - Packet(Kubeadm) - - Konvoy - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-drain - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-drain/ - - name: Video - url: https://www.youtube.com/watch?v=LQVCZUQ4-ok - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-drain/experiment.yaml diff --git a/charts/generic/node-drain/rbac-psp.yaml b/charts/generic/node-drain/rbac-psp.yaml deleted file mode 100644 index c1ddf8c..0000000 --- a/charts/generic/node-drain/rbac-psp.yaml +++ /dev/null @@ -1,75 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-drain-sa - namespace: default - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-drain-sa -subjects: -- kind: ServiceAccount - name: node-drain-sa - namespace: default diff --git a/charts/generic/node-drain/rbac.yaml b/charts/generic/node-drain/rbac.yaml deleted file mode 100644 index e16cbd8..0000000 --- a/charts/generic/node-drain/rbac.yaml +++ /dev/null @@ -1,70 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-drain-sa - namespace: default - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-drain-sa -subjects: -- kind: ServiceAccount - name: node-drain-sa - namespace: default diff --git a/charts/generic/node-io-stress/experiment.yaml b/charts/generic/node-io-stress/experiment.yaml deleted file mode 100644 index eec95f0..0000000 --- a/charts/generic/node-io-stress/experiment.yaml +++ /dev/null @@ -1,111 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give IO disk stress on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-io-stress - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-io-stress - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Number of core of CPU - - name: CPU - value: '1' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Total number of vm workers - - name: VM_WORKERS - value: '1' - - ## enter the comma separated target nodes name - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/node-io-stress/node-io-stress.chartserviceversion.yaml b/charts/generic/node-io-stress/node-io-stress.chartserviceversion.yaml deleted file mode 100644 index 2f990bc..0000000 --- a/charts/generic/node-io-stress/node-io-stress.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-09-12T10:28:08Z - name: node-io-stress - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-io-stress - categoryDescription: | - This experiment causes disk stress on the Kubernetes node. The experiment aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes.. - - Disk stress on a particular node filesystem where the application deployment is available. - - The amount of disk stress can be either specifed as the size in percentage of the total free space on the file system or simply in Gigabytes(GB) - keywords: - - Kubernetes - - K8S - - Disk - - IO - - Filesystem - - Node - platforms: - - GKE - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-io-stress - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-io-stress/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-io-stress/experiment.yaml diff --git a/charts/generic/node-io-stress/rbac-psp.yaml b/charts/generic/node-io-stress/rbac-psp.yaml deleted file mode 100644 index ab12913..0000000 --- a/charts/generic/node-io-stress/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-io-stress-sa - namespace: default - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-io-stress-sa -subjects: -- kind: ServiceAccount - name: node-io-stress-sa - namespace: default diff --git a/charts/generic/node-io-stress/rbac.yaml b/charts/generic/node-io-stress/rbac.yaml deleted file mode 100644 index a6858e7..0000000 --- a/charts/generic/node-io-stress/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-io-stress-sa - namespace: default - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-io-stress-sa -subjects: -- kind: ServiceAccount - name: node-io-stress-sa - namespace: default diff --git a/charts/generic/node-memory-hog/experiment.yaml b/charts/generic/node-memory-hog/experiment.yaml deleted file mode 100644 index 94912ad..0000000 --- a/charts/generic/node-memory-hog/experiment.yaml +++ /dev/null @@ -1,102 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a memory hog on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-memory-hog - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-memory-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## Specify the size as percent of total node capacity Ex: '30' - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - - name: MEMORY_CONSUMPTION_PERCENTAGE - value: '' - - ## Specify the amount of memory to be consumed in mebibytes - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - - name: MEMORY_CONSUMPTION_MEBIBYTES - value: '' - - - name: NUMBER_OF_WORKERS - value: '1' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml b/charts/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml deleted file mode 100644 index f6d7cf1..0000000 --- a/charts/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-28T10:28:08Z - name: node-memory-hog - version: 0.1.5 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-memory-hog - categoryDescription: | - Kubernetes Node memory hog contains chaos to disrupt the state of Kubernetes resources. Experiments can inject a memory spike on a node where the application pod is scheduled. - - Memory hog on a particular node where the application deployment is available. - - After the test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. - keywords: - - Kubernetes - - K8S - - Memory - - Node - platforms: - - GKE - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-memory-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-memory-hog/ - - name: Video - url: https://www.youtube.com/watch?v=ECxlWgQ8F5w - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-memory-hog/experiment.yaml diff --git a/charts/generic/node-memory-hog/rbac-psp.yaml b/charts/generic/node-memory-hog/rbac-psp.yaml deleted file mode 100644 index a6002c5..0000000 --- a/charts/generic/node-memory-hog/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-memory-hog-sa - namespace: default - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-memory-hog-sa -subjects: -- kind: ServiceAccount - name: node-memory-hog-sa - namespace: default diff --git a/charts/generic/node-memory-hog/rbac.yaml b/charts/generic/node-memory-hog/rbac.yaml deleted file mode 100644 index 74cd3eb..0000000 --- a/charts/generic/node-memory-hog/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-memory-hog-sa - namespace: default - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-memory-hog-sa -subjects: -- kind: ServiceAccount - name: node-memory-hog-sa - namespace: default diff --git a/charts/generic/node-poweroff/engine.yaml b/charts/generic/node-poweroff/engine.yaml deleted file mode 100644 index 68ac3a7..0000000 --- a/charts/generic/node-poweroff/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-poweroff-sa - experiments: - - name: node-poweroff - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - # ENTER THE USER TO BE USED FOR SSH AUTH - - name: SSH_USER - value: 'root' diff --git a/charts/generic/node-poweroff/node-poweroff.chartserviceversion.yaml b/charts/generic/node-poweroff/node-poweroff.chartserviceversion.yaml deleted file mode 100644 index 566ca14..0000000 --- a/charts/generic/node-poweroff/node-poweroff.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-poweroff - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-poweroff - categoryDescription: | - Node poweroff contains chaos experiment to poweroff a node via SSH. - keywords: - - Kubernetes - - K8S - - Poweroff - - Node - platforms: - - KVM/LibVirt based K8s - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: jordigilh - email: jordi.gil@gmail.com - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-restart - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-restart - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-poweroff/experiment.yaml diff --git a/charts/generic/node-poweroff/rbac-psp.yaml b/charts/generic/node-poweroff/rbac-psp.yaml deleted file mode 100644 index 93abac3..0000000 --- a/charts/generic/node-poweroff/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-poweroff-sa - namespace: default - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-poweroff-sa -subjects: -- kind: ServiceAccount - name: node-poweroff-sa - namespace: default diff --git a/charts/generic/node-poweroff/rbac.yaml b/charts/generic/node-poweroff/rbac.yaml deleted file mode 100644 index 16898df..0000000 --- a/charts/generic/node-poweroff/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-poweroff-sa - namespace: default - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-poweroff-sa -subjects: -- kind: ServiceAccount - name: node-poweroff-sa - namespace: default diff --git a/charts/generic/node-restart/engine.yaml b/charts/generic/node-restart/engine.yaml deleted file mode 100644 index 71e3d70..0000000 --- a/charts/generic/node-restart/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-restart-sa - experiments: - - name: node-restart - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - # ENTER THE USER TO BE USED FOR SSH AUTH - - name: SSH_USER - value: 'root' diff --git a/charts/generic/node-restart/node-restart.chartserviceversion.yaml b/charts/generic/node-restart/node-restart.chartserviceversion.yaml deleted file mode 100644 index 4eceec8..0000000 --- a/charts/generic/node-restart/node-restart.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-restart - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-restart - categoryDescription: | - Node restart contains chaos to restart the node via SSH. - keywords: - - Kubernetes - - K8S - - Restart - - Node - platforms: - - KVM/LibVirt based K8s - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: machacekondra - email: machacek.ondra@gmail.com - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-restart - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-restart - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-restart/experiment.yaml diff --git a/charts/generic/node-restart/rbac-psp.yaml b/charts/generic/node-restart/rbac-psp.yaml deleted file mode 100644 index b21b60b..0000000 --- a/charts/generic/node-restart/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-restart-sa - namespace: default - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-restart-sa -subjects: -- kind: ServiceAccount - name: node-restart-sa - namespace: default diff --git a/charts/generic/node-restart/rbac.yaml b/charts/generic/node-restart/rbac.yaml deleted file mode 100644 index 9b48dd1..0000000 --- a/charts/generic/node-restart/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-restart-sa - namespace: default - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-restart-sa -subjects: -- kind: ServiceAccount - name: node-restart-sa - namespace: default diff --git a/charts/generic/node-taint/node-taint.chartserviceversion.yaml b/charts/generic/node-taint/node-taint.chartserviceversion.yaml deleted file mode 100644 index 6e19973..0000000 --- a/charts/generic/node-taint/node-taint.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-13T10:28:08Z - name: node-taint - version: 0.1.2 - annotations: - categories: Kubernetes - vendor: Mayadata - repository: https://github.com/litmuschaos/chaos-charts - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: node-taint - categoryDescription: > - Taint the node where application pod is scheduled - keywords: - - Kubernetes - - K8S - - Node - - Taint - platforms: - - GKE - - AWS(KOPS) - - Packet(Kubeadm) - - Konvoy - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-taint - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-taint/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-taint/experiment.yaml diff --git a/charts/generic/node-taint/rbac-psp.yaml b/charts/generic/node-taint/rbac-psp.yaml deleted file mode 100644 index 1188ec7..0000000 --- a/charts/generic/node-taint/rbac-psp.yaml +++ /dev/null @@ -1,75 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-taint-sa - namespace: default - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-taint-sa -subjects: -- kind: ServiceAccount - name: node-taint-sa - namespace: default diff --git a/charts/generic/node-taint/rbac.yaml b/charts/generic/node-taint/rbac.yaml deleted file mode 100644 index 8981a55..0000000 --- a/charts/generic/node-taint/rbac.yaml +++ /dev/null @@ -1,70 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-taint-sa - namespace: default - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-taint-sa -subjects: -- kind: ServiceAccount - name: node-taint-sa - namespace: default diff --git a/charts/generic/pod-autoscaler/experiment.yaml b/charts/generic/pod-autoscaler/experiment.yaml deleted file mode 100644 index 2ad3058..0000000 --- a/charts/generic/pod-autoscaler/experiment.yaml +++ /dev/null @@ -1,73 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Scale the application replicas and test the node autoscaling on cluster -kind: ChaosExperiment -metadata: - name: pod-autoscaler - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-autoscaler - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Number of replicas to scale - - name: REPLICA_COUNT - value: '5' - - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml b/charts/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml deleted file mode 100644 index a22bc4c..0000000 --- a/charts/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-08-08T10:28:08Z - name: pod-autoscaler - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-autoscaler - categoryDescription: | - The experiment aims to check the ability of nodes to accommodate the number of replicas a given application pod. - This experiment can be used for other scenarios as well, such as for checking the Node auto-scaling feature. For example, check if the pods are successfully rescheduled within a specified period in cases where the existing nodes are already running at the specified limits. - keywords: - - Kubernetes - - K8S - - Scale - - Pod - platforms: - - GKE - - EKS - - Minikube - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-autoscaler - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-autoscaler/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-autoscaler/experiment.yaml diff --git a/charts/generic/pod-autoscaler/rbac-psp.yaml b/charts/generic/pod-autoscaler/rbac-psp.yaml deleted file mode 100644 index 49a03ac..0000000 --- a/charts/generic/pod-autoscaler/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-autoscaler-sa - namespace: default - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-autoscaler-sa -subjects: -- kind: ServiceAccount - name: pod-autoscaler-sa - namespace: default diff --git a/charts/generic/pod-autoscaler/rbac.yaml b/charts/generic/pod-autoscaler/rbac.yaml deleted file mode 100644 index 19114f1..0000000 --- a/charts/generic/pod-autoscaler/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-autoscaler-sa - namespace: default - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-autoscaler-sa -subjects: -- kind: ServiceAccount - name: pod-autoscaler-sa - namespace: default diff --git a/charts/generic/pod-cpu-hog-exec/engine.yaml b/charts/generic/pod-cpu-hog-exec/engine.yaml deleted file mode 100644 index c793410..0000000 --- a/charts/generic/pod-cpu-hog-exec/engine.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-cpu-hog-exec-sa - experiments: - - name: pod-cpu-hog-exec - 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' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/charts/generic/pod-cpu-hog-exec/experiment.yaml b/charts/generic/pod-cpu-hog-exec/experiment.yaml deleted file mode 100644 index 744d7ec..0000000 --- a/charts/generic/pod-cpu-hog-exec/experiment.yaml +++ /dev/null @@ -1,100 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog-exec - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/md5sum' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}')" - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml b/charts/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml deleted file mode 100644 index 65ef4e8..0000000 --- a/charts/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-cpu-hog-exec - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-cpu-hog-exec - categoryDescription: | - pod-cpu-hog-exec contains chaos to consume CPU resouces of specified containers in Kubernetes pods. - - Causes high CPU resource consumption utilizing one or more cores by triggering md5sum commands - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - CPU - - Pod - - Exec - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - maturity: alpha - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-cpu-hog-exec - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-cpu-hog-exec/ - - name: Video - url: https://www.youtube.com/watch?v=MBGSPmZKb2I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-cpu-hog-exec/experiment.yaml diff --git a/charts/generic/pod-cpu-hog-exec/rbac-psp.yaml b/charts/generic/pod-cpu-hog-exec/rbac-psp.yaml deleted file mode 100644 index f1733be..0000000 --- a/charts/generic/pod-cpu-hog-exec/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-exec-sa - namespace: default diff --git a/charts/generic/pod-cpu-hog-exec/rbac.yaml b/charts/generic/pod-cpu-hog-exec/rbac.yaml deleted file mode 100644 index 9e80151..0000000 --- a/charts/generic/pod-cpu-hog-exec/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-exec-sa - namespace: default diff --git a/charts/generic/pod-cpu-hog/engine.yaml b/charts/generic/pod-cpu-hog/engine.yaml deleted file mode 100644 index dfa9bbb..0000000 --- a/charts/generic/pod-cpu-hog/engine.yaml +++ /dev/null @@ -1,36 +0,0 @@ - -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-cpu-hog-sa - experiments: - - name: pod-cpu-hog - spec: - components: - env: - - 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: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' diff --git a/charts/generic/pod-cpu-hog/experiment.yaml b/charts/generic/pod-cpu-hog/experiment.yaml deleted file mode 100644 index b379903..0000000 --- a/charts/generic/pod-cpu-hog/experiment.yaml +++ /dev/null @@ -1,122 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml b/charts/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml deleted file mode 100644 index 5206115..0000000 --- a/charts/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml +++ /dev/null @@ -1,53 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-cpu-hog - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-cpu-hog - categoryDescription: | - Pod-CPU-Hog contains chaos to consume CPU resouces of specified containers in Kubernetes pods. - - Causes CPU resource consumption on specified application containers using cgroups and litmus nsutil which consume CPU resources of the given target containers. - - It Can test the application's resilience to potential slowness/unavailability of some replicas due to high CPU load - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - CPU - - Pod - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - maturity: alpha - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-cpu-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-cpu-hog/ - - name: Video - url: https://www.youtube.com/watch?v=MBGSPmZKb2I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-cpu-hog/experiment.yaml diff --git a/charts/generic/pod-cpu-hog/rbac-psp.yaml b/charts/generic/pod-cpu-hog/rbac-psp.yaml deleted file mode 100644 index 8952968..0000000 --- a/charts/generic/pod-cpu-hog/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-sa - namespace: default diff --git a/charts/generic/pod-cpu-hog/rbac.yaml b/charts/generic/pod-cpu-hog/rbac.yaml deleted file mode 100644 index f045de3..0000000 --- a/charts/generic/pod-cpu-hog/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-sa - namespace: default diff --git a/charts/generic/pod-delete/ansible/engine.yaml b/charts/generic/pod-delete/ansible/engine.yaml deleted file mode 100644 index 871f8f2..0000000 --- a/charts/generic/pod-delete/ansible/engine.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: pod-delete-sa - 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' diff --git a/charts/generic/pod-delete/ansible/experiment.yaml b/charts/generic/pod-delete/ansible/experiment.yaml deleted file mode 100644 index 86a289a..0000000 --- a/charts/generic/pod-delete/ansible/experiment.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/generic/pod_delete/pod_delete_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - - name: LIB_IMAGE - value: 'litmuschaos/pod-delete-helper:latest' - - - name: LIB - value: 'litmus' - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-delete/ansible/powerfulseal_rbac.yaml b/charts/generic/pod-delete/ansible/powerfulseal_rbac.yaml deleted file mode 100644 index f53e37b..0000000 --- a/charts/generic/pod-delete/ansible/powerfulseal_rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-delete-sa - labels: - name: pod-delete-sa -rules: -- apiGroups: ["","litmuschaos.io","batch","apps"] - resources: ["pods","deployments","pods/log","events","jobs","configmaps","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-delete-sa - labels: - name: pod-delete-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/charts/generic/pod-delete/ansible/rbac.yaml b/charts/generic/pod-delete/ansible/rbac.yaml deleted file mode 100644 index 6a1535b..0000000 --- a/charts/generic/pod-delete/ansible/rbac.yaml +++ /dev/null @@ -1,40 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","litmuschaos.io","batch","apps"] - resources: ["pods","deployments","pods/log","events","jobs","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/charts/generic/pod-delete/engine.yaml b/charts/generic/pod-delete/engine.yaml deleted file mode 100644 index c211c73..0000000 --- a/charts/generic/pod-delete/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - chaosServiceAccount: pod-delete-sa - 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/charts/generic/pod-delete/engine_nginx_getstarted.yaml b/charts/generic/pod-delete/engine_nginx_getstarted.yaml deleted file mode 100644 index 043113f..0000000 --- a/charts/generic/pod-delete/engine_nginx_getstarted.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: nginx -spec: - appinfo: - appns: 'nginx' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: pod-delete-sa - # 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/charts/generic/pod-delete/pod-delete.chartserviceversion.yaml b/charts/generic/pod-delete/pod-delete.chartserviceversion.yaml deleted file mode 100644 index b5e42b6..0000000 --- a/charts/generic/pod-delete/pod-delete.chartserviceversion.yaml +++ /dev/null @@ -1,52 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-15T10:28:08Z - name: pod-delete - version: 0.1.13 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-delete - categoryDescription: | - Pod delete contains chaos to disrupt state of kubernetes resources. Experiments can inject random pod delete failures against specified application. - - Causes (forced/graceful) pod failure of random replicas of an application deployment. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. - - keywords: - - Kubernetes - - K8S - - Pod - platforms: - - GKE - - Konvoy - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-delete - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-delete/ - - name: Video - url: https://www.youtube.com/watch?v=X3JvY_58V9A - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-delete/experiment.yaml diff --git a/charts/generic/pod-delete/python/experiment.yaml b/charts/generic/pod-delete/python/experiment.yaml deleted file mode 100644 index d80a29d..0000000 --- a/charts/generic/pod-delete/python/experiment.yaml +++ /dev/null @@ -1,90 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "apps.openshift.io" - - "argoproj.io" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "replicationcontrollers" - - "deployments" - - "statefulsets" - - "daemonsets" - - "replicasets" - - "deploymentconfigs" - - "rollouts" - - "pods/exec" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - "deletecollection" - image: "litmuschaos/py-runner:latest" - imagePullPolicy: Always - args: - - -c - - python3 -u experiment - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-delete/python/rbac.yaml b/charts/generic/pod-delete/python/rbac.yaml deleted file mode 100644 index 350173d..0000000 --- a/charts/generic/pod-delete/python/rbac.yaml +++ /dev/null @@ -1,58 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: [""] - resources: ["pods","events"] - verbs: ["create","list","get","patch","update","delete","deletecollection"] -- apiGroups: [""] - resources: ["pods/exec","pods/log","replicationcontrollers"] - verbs: ["create","list","get"] -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -- apiGroups: ["apps"] - resources: ["deployments","statefulsets","daemonsets","replicasets"] - verbs: ["list","get"] -- apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] -- apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/charts/generic/pod-delete/rbac-psp.yaml b/charts/generic/pod-delete/rbac-psp.yaml deleted file mode 100644 index e494e6b..0000000 --- a/charts/generic/pod-delete/rbac-psp.yaml +++ /dev/null @@ -1,86 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/charts/generic/pod-delete/rbac.yaml b/charts/generic/pod-delete/rbac.yaml deleted file mode 100644 index a3f4f5c..0000000 --- a/charts/generic/pod-delete/rbac.yaml +++ /dev/null @@ -1,81 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/charts/generic/pod-delete/rbac_nginx_getstarted.yaml b/charts/generic/pod-delete/rbac_nginx_getstarted.yaml deleted file mode 100644 index 5ff2c83..0000000 --- a/charts/generic/pod-delete/rbac_nginx_getstarted.yaml +++ /dev/null @@ -1,77 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: nginx \ No newline at end of file diff --git a/charts/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml b/charts/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml deleted file mode 100644 index 4ece88e..0000000 --- a/charts/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-dns-error - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-dns-error - categoryDescription: > - Pod DNS Error injects dns failure/error in target pod containers - keywords: - - "Pod" - - K8S - - "Kubernetes" - - "DNS" - maturity: alpha - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - maintainers: - - name: gdsoumya - email: gdsoumya@chaosnative.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-dns-error - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/getstarted/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-dns-error/experiment.yaml diff --git a/charts/generic/pod-dns-error/rbac-psp.yaml b/charts/generic/pod-dns-error/rbac-psp.yaml deleted file mode 100644 index 1e8bbfd..0000000 --- a/charts/generic/pod-dns-error/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-error-sa -subjects: - - kind: ServiceAccount - name: pod-dns-error-sa - namespace: default diff --git a/charts/generic/pod-dns-error/rbac.yaml b/charts/generic/pod-dns-error/rbac.yaml deleted file mode 100644 index 84dc894..0000000 --- a/charts/generic/pod-dns-error/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-error-sa -subjects: - - kind: ServiceAccount - name: pod-dns-error-sa - namespace: default diff --git a/charts/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml b/charts/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml deleted file mode 100644 index b179d30..0000000 --- a/charts/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-dns-spoof - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-dns-spoof - categoryDescription: > - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames - keywords: - - "Pod" - - K8S - - "Kubernetes" - - "DNS" - maturity: alpha - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - maintainers: - - name: gdsoumya - email: gdsoumya@chaosnative.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-dns-spoof - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/getstarted/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-dns-spoof/experiment.yaml diff --git a/charts/generic/pod-dns-spoof/rbac-psp.yaml b/charts/generic/pod-dns-spoof/rbac-psp.yaml deleted file mode 100644 index 106c044..0000000 --- a/charts/generic/pod-dns-spoof/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-spoof-sa -subjects: - - kind: ServiceAccount - name: pod-dns-spoof-sa - namespace: default diff --git a/charts/generic/pod-dns-spoof/rbac.yaml b/charts/generic/pod-dns-spoof/rbac.yaml deleted file mode 100644 index 6d2c76d..0000000 --- a/charts/generic/pod-dns-spoof/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-spoof-sa -subjects: - - kind: ServiceAccount - name: pod-dns-spoof-sa - namespace: default diff --git a/charts/generic/pod-http-latency/engine.yaml b/charts/generic/pod-http-latency/engine.yaml deleted file mode 100644 index 83f891e..0000000 --- a/charts/generic/pod-http-latency/engine.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-http-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-http-latency-sa - experiments: - - name: pod-http-latency - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # set latency value for the chaos - - name: LATENCY - value: '2000' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # provide the name of container runtime - # it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/charts/generic/pod-http-latency/experiment.yaml b/charts/generic/pod-http-latency/experiment.yaml deleted file mode 100644 index 0a4fb57..0000000 --- a/charts/generic/pod-http-latency/experiment.yaml +++ /dev/null @@ -1,131 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects http request latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-http-latency - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # set latency value for the chaos - - name: LATENCY - value: '2000' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml b/charts/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml deleted file mode 100644 index d39adc4..0000000 --- a/charts/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2022-05-21T10:28:08Z - name: pod-http-latency - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-http-latency - categoryDescription: | - Pod-http-latency contains chaos to disrupt http requests of kubernetes pods. This experiment can inject random http response delays on the app replica pods. - - Causes flaky access to application replica by injecting http response delay using toxiproxy. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - HTTP - - Pod - - Latency - platforms: - - GKE - - Minikube - - EKS - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-latency - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-latency/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-latency/experiment.yaml diff --git a/charts/generic/pod-http-latency/rbac-psp.yaml b/charts/generic/pod-http-latency/rbac-psp.yaml deleted file mode 100644 index 3b472ee..0000000 --- a/charts/generic/pod-http-latency/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-latency-sa -subjects: -- kind: ServiceAccount - name: pod-http-latency-sa - namespace: default diff --git a/charts/generic/pod-http-latency/rbac.yaml b/charts/generic/pod-http-latency/rbac.yaml deleted file mode 100644 index 6c46d88..0000000 --- a/charts/generic/pod-http-latency/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-latency-sa -subjects: -- kind: ServiceAccount - name: pod-http-latency-sa - namespace: default diff --git a/charts/generic/pod-http-modify-body/engine.yaml b/charts/generic/pod-http-modify-body/engine.yaml deleted file mode 100644 index fa5305d..0000000 --- a/charts/generic/pod-http-modify-body/engine.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-http-modify-body-sa - experiments: - - name: pod-http-modify-body - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # provide the body string to overwrite the response body - - name: RESPONSE_BODY - value: '' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # provide the name of container runtime - # it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/charts/generic/pod-http-modify-body/experiment.yaml b/charts/generic/pod-http-modify-body/experiment.yaml deleted file mode 100644 index 81ec27e..0000000 --- a/charts/generic/pod-http-modify-body/experiment.yaml +++ /dev/null @@ -1,131 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the body of the response from the provided application server to the body string provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-body - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-body - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the body string to overwrite the response body - # if no value is provided, response will be an empty body. - - name: RESPONSE_BODY - value: '' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml b/charts/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml deleted file mode 100644 index 1a66390..0000000 --- a/charts/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-modify-body - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-modify-body - categoryDescription: > - it injects http modify body chaos inside the pod which modifies the body of the response from the provided application server to the body string provided by user and reverts after specified duration - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "response body" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-modify-body - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-modify-body/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-modify-body/experiment.yaml \ No newline at end of file diff --git a/charts/generic/pod-http-modify-body/rbac-psp.yaml b/charts/generic/pod-http-modify-body/rbac-psp.yaml deleted file mode 100644 index 2869bde..0000000 --- a/charts/generic/pod-http-modify-body/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-body-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-body-sa - namespace: default diff --git a/charts/generic/pod-http-modify-body/rbac.yaml b/charts/generic/pod-http-modify-body/rbac.yaml deleted file mode 100644 index 584be62..0000000 --- a/charts/generic/pod-http-modify-body/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-body-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-body-sa - namespace: default diff --git a/charts/generic/pod-http-modify-header/engine.yaml b/charts/generic/pod-http-modify-header/engine.yaml deleted file mode 100644 index 84ee278..0000000 --- a/charts/generic/pod-http-modify-header/engine.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-http-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-http-modify-header-sa - experiments: - - name: pod-http-modify-header - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} - # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} - - name: HEADERS_MAP - value: '{}' - - # whether to modify response headers or request headers. Accepted values: request, response - - name: HEADER_MODE - value: 'response' - - # provide the name of container runtime - # it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/charts/generic/pod-http-modify-header/experiment.yaml b/charts/generic/pod-http-modify-header/experiment.yaml deleted file mode 100644 index 8a9deca..0000000 --- a/charts/generic/pod-http-modify-header/experiment.yaml +++ /dev/null @@ -1,136 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the header of the request/response from the provided application server to the headers provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-header - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-header - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} - # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} - - name: HEADERS_MAP - value: '{}' - - # whether to modify response headers or request headers. Accepted values: request, response - - name: HEADER_MODE - value: 'response' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml b/charts/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml deleted file mode 100644 index c34601a..0000000 --- a/charts/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2022-07-13T2:14:08Z - name: pod-http-modify-header - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-http-modify-header - categoryDescription: | - Pod-http-modify-header contains chaos to disrupt http requests of kubernetes pods. This experiment can modify headers of incoming requests or the response from the service targetted. - - Causes modification of request/response headers of the HTTP request. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - HTTP - - Pod - - Headers - platforms: - - GKE - - Minikube - - EKS - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-modify-header - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-modify-header/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-modify-header/experiment.yaml diff --git a/charts/generic/pod-http-modify-header/rbac-psp.yaml b/charts/generic/pod-http-modify-header/rbac-psp.yaml deleted file mode 100644 index fb35617..0000000 --- a/charts/generic/pod-http-modify-header/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-header-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-header-sa - namespace: default diff --git a/charts/generic/pod-http-modify-header/rbac.yaml b/charts/generic/pod-http-modify-header/rbac.yaml deleted file mode 100644 index 5f9208f..0000000 --- a/charts/generic/pod-http-modify-header/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-header-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-header-sa - namespace: default diff --git a/charts/generic/pod-http-reset-peer/experiment.yaml b/charts/generic/pod-http-reset-peer/experiment.yaml deleted file mode 100644 index f89099c..0000000 --- a/charts/generic/pod-http-reset-peer/experiment.yaml +++ /dev/null @@ -1,130 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - it injects chaos into the pod which stops outgoing http requests by resetting the TCP connection and then reverts back to the original state after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-reset-peer - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-reset-peer - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # reset timeout specifies after how much duration to reset the connection - - name: RESET_TIMEOUT - value: '0' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml b/charts/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml deleted file mode 100644 index 5758eae..0000000 --- a/charts/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-reset-peer - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-reset-peer - categoryDescription: > - it injects http reset into the pod which stops outgoing http requests by resetting the TCP connection and then reverts back to the original state after the specified duration - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "loss" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-reset-peer - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-reset-peer/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-reset-peer/experiment.yaml \ No newline at end of file diff --git a/charts/generic/pod-http-reset-peer/rbac-psp.yaml b/charts/generic/pod-http-reset-peer/rbac-psp.yaml deleted file mode 100644 index 5c22b38..0000000 --- a/charts/generic/pod-http-reset-peer/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-reset-peer-sa -subjects: -- kind: ServiceAccount - name: pod-http-reset-peer-sa - namespace: default diff --git a/charts/generic/pod-http-reset-peer/rbac.yaml b/charts/generic/pod-http-reset-peer/rbac.yaml deleted file mode 100644 index 0c71681..0000000 --- a/charts/generic/pod-http-reset-peer/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-reset-peer-sa -subjects: -- kind: ServiceAccount - name: pod-http-reset-peer-sa - namespace: default diff --git a/charts/generic/pod-http-status-code/experiment.yaml b/charts/generic/pod-http-status-code/experiment.yaml deleted file mode 100644 index 7162037..0000000 --- a/charts/generic/pod-http-status-code/experiment.yaml +++ /dev/null @@ -1,137 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects chaos inside the pod which modifies the status code of the response from the provided application server to desired status code provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-status-code - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-status-code - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # modified status code for the http response - # if no value is provided, a random status code from the supported code list will selected - # if an invalid status code is provided, the experiment will fail - # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504] - - name: STATUS_CODE - value: '' - - # whether to modify the body as per the status code provided - - name: "MODIFY_RESPONSE_BODY" - value: "true" - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml b/charts/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml deleted file mode 100644 index af809c9..0000000 --- a/charts/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-status-code - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-status-code - categoryDescription: > - it injects http status code chaos inside the pod which modifies the status code of the response from the provided application server to desired status code provided by user and reverts after specified duration - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "status code" - - "response code" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-status-code - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-status-code/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-status-code/experiment.yaml \ No newline at end of file diff --git a/charts/generic/pod-http-status-code/rbac-psp.yaml b/charts/generic/pod-http-status-code/rbac-psp.yaml deleted file mode 100644 index 8318ccd..0000000 --- a/charts/generic/pod-http-status-code/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-status-code-sa -subjects: -- kind: ServiceAccount - name: pod-http-status-code-sa - namespace: default diff --git a/charts/generic/pod-http-status-code/rbac.yaml b/charts/generic/pod-http-status-code/rbac.yaml deleted file mode 100644 index 5f117f5..0000000 --- a/charts/generic/pod-http-status-code/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-status-code-sa -subjects: -- kind: ServiceAccount - name: pod-http-status-code-sa - namespace: default diff --git a/charts/generic/pod-io-stress/experiment.yaml b/charts/generic/pod-io-stress/experiment.yaml deleted file mode 100644 index ea37036..0000000 --- a/charts/generic/pod-io-stress/experiment.yaml +++ /dev/null @@ -1,129 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - IO stress on a app pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-io-stress - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-io-stress - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # provide volume mount path - - name: VOLUME_MOUNT_PATH - value: '' - - ## specify the comma separated target pods - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml b/charts/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml deleted file mode 100644 index 8f7a010..0000000 --- a/charts/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-09-13T10:28:08Z - name: pod-io-stress - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-io-stress - categoryDescription: | - This experiment causes disk stress on the application pod. The experiment aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes. - - Consumes the disk available by executing filesystem IO stress as available memory or by providing the value in GB - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - IO - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-io-stress - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-io-stress/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-io-stress/experiment.yaml diff --git a/charts/generic/pod-io-stress/rbac-psp.yaml b/charts/generic/pod-io-stress/rbac-psp.yaml deleted file mode 100644 index 755512a..0000000 --- a/charts/generic/pod-io-stress/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-io-stress-sa -subjects: -- kind: ServiceAccount - name: pod-io-stress-sa - namespace: default diff --git a/charts/generic/pod-io-stress/rbac.yaml b/charts/generic/pod-io-stress/rbac.yaml deleted file mode 100644 index e80025d..0000000 --- a/charts/generic/pod-io-stress/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-io-stress-sa -subjects: -- kind: ServiceAccount - name: pod-io-stress-sa - namespace: default diff --git a/charts/generic/pod-memory-hog-exec/engine.yaml b/charts/generic/pod-memory-hog-exec/engine.yaml deleted file mode 100644 index 5bc6b0d..0000000 --- a/charts/generic/pod-memory-hog-exec/engine.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-memory-hog-exec-sa - experiments: - - name: pod-memory-hog-exec - 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/charts/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml b/charts/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml deleted file mode 100644 index 2e37699..0000000 --- a/charts/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-04-10T10:28:08Z - name: pod-memory-hog-exec - version: 0.1.4 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-memory-hog-exec - categoryDescription: | - pod-memory-hog-exec contains chaos to consume Memory resouces of specified containers in Kubernetes pods. - - Consumes the memory specified by executing a dd command against special files /dev/zero(input) and /dev/null(output) - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - Exec - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-memory-hog-exec - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-memory-hog-exec/ - - name: Video - url: https://www.youtube.com/watch?v=HuAXg8W5Tzo - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-memory-hog-exec/experiment.yaml diff --git a/charts/generic/pod-memory-hog-exec/rbac-psp.yaml b/charts/generic/pod-memory-hog-exec/rbac-psp.yaml deleted file mode 100644 index eb39cec..0000000 --- a/charts/generic/pod-memory-hog-exec/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-exec-sa - namespace: default diff --git a/charts/generic/pod-memory-hog-exec/rbac.yaml b/charts/generic/pod-memory-hog-exec/rbac.yaml deleted file mode 100644 index d4da0ca..0000000 --- a/charts/generic/pod-memory-hog-exec/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-exec-sa - namespace: default diff --git a/charts/generic/pod-memory-hog/engine.yaml b/charts/generic/pod-memory-hog/engine.yaml deleted file mode 100644 index d039dee..0000000 --- a/charts/generic/pod-memory-hog/engine.yaml +++ /dev/null @@ -1,36 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-memory-hog-sa - experiments: - - name: pod-memory-hog - 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' diff --git a/charts/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml b/charts/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml deleted file mode 100644 index 958f9e4..0000000 --- a/charts/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-memory-hog - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-memory-hog - categoryDescription: | - Pod-Memory-Hog contains chaos to consume memory resouces of specified containers in Kubernetes pods. - - Causes memory resource consumption on specified application containers using cgroups and litmus nsutil that consume memory resources of the given target containers. - - It Can test the application's resilience to potential slowness/unavailability of some replicas due to high memory load - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-memory-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-memory-hog/ - - name: Video - url: https://www.youtube.com/watch?v=HuAXg8W5Tzo - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-memory-hog/experiment.yaml diff --git a/charts/generic/pod-memory-hog/rbac-psp.yaml b/charts/generic/pod-memory-hog/rbac-psp.yaml deleted file mode 100644 index 3ad222d..0000000 --- a/charts/generic/pod-memory-hog/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-sa - namespace: default diff --git a/charts/generic/pod-memory-hog/rbac.yaml b/charts/generic/pod-memory-hog/rbac.yaml deleted file mode 100644 index 61445c9..0000000 --- a/charts/generic/pod-memory-hog/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-sa - namespace: default diff --git a/charts/generic/pod-network-corruption/experiment.yaml b/charts/generic/pod-network-corruption/experiment.yaml deleted file mode 100644 index af626a1..0000000 --- a/charts/generic/pod-network-corruption/experiment.yaml +++ /dev/null @@ -1,134 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Inject network packet corruption into application pod -kind: ChaosExperiment -metadata: - name: pod-network-corruption - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-corruption - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml b/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml deleted file mode 100644 index c4991a9..0000000 --- a/charts/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-01-07T10:28:08Z - name: pod-network-corruption - version: 0.1.10 - 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 - - K8S - - Network - - Pod - - Corruption - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: LaumiH - email: laura-marie.henning@stud.h-da.de - minKubeVersion: 1.12.0 - provider: - name: Laura-Marie Henning - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-corruption - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-corruption/ - - name: Video - url: https://www.youtube.com/watch?v=kSiLrIaILvs - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-corruption/experiment.yaml diff --git a/charts/generic/pod-network-corruption/rbac-psp.yaml b/charts/generic/pod-network-corruption/rbac-psp.yaml deleted file mode 100644 index 685855b..0000000 --- a/charts/generic/pod-network-corruption/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-corruption-sa -subjects: -- kind: ServiceAccount - name: pod-network-corruption-sa - namespace: default diff --git a/charts/generic/pod-network-corruption/rbac.yaml b/charts/generic/pod-network-corruption/rbac.yaml deleted file mode 100644 index f0319df..0000000 --- a/charts/generic/pod-network-corruption/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-corruption-sa -subjects: -- kind: ServiceAccount - name: pod-network-corruption-sa - namespace: default diff --git a/charts/generic/pod-network-duplication/experiment.yaml b/charts/generic/pod-network-duplication/experiment.yaml deleted file mode 100644 index 21627d0..0000000 --- a/charts/generic/pod-network-duplication/experiment.yaml +++ /dev/null @@ -1,131 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet duplication on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-duplication - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-duplication - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: RAMP_TIME - value: '' - - - name: TARGET_CONTAINER - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE - value: '100' # in percentage - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml b/charts/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml deleted file mode 100644 index cec3785..0000000 --- a/charts/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-07-01T10:28:08Z - name: pod-network-duplication - version: 0.1.2 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-duplication - categoryDescription: | - Pod-network-duplication contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject percentage packet duplication on the app replica pods. - - Causes lossy access to application replica by injecting packet duplication 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 - - K8S - - Network - - Pod - - Duplication - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-duplication - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-duplication/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-duplication/experiment.yaml diff --git a/charts/generic/pod-network-duplication/rbac-psp.yaml b/charts/generic/pod-network-duplication/rbac-psp.yaml deleted file mode 100644 index 01acf1a..0000000 --- a/charts/generic/pod-network-duplication/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-duplication-sa -subjects: -- kind: ServiceAccount - name: pod-network-duplication-sa - namespace: default diff --git a/charts/generic/pod-network-duplication/rbac.yaml b/charts/generic/pod-network-duplication/rbac.yaml deleted file mode 100644 index d225750..0000000 --- a/charts/generic/pod-network-duplication/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-duplication-sa -subjects: -- kind: ServiceAccount - name: pod-network-duplication-sa - namespace: default diff --git a/charts/generic/pod-network-latency/engine.yaml b/charts/generic/pod-network-latency/engine.yaml deleted file mode 100644 index aa4396c..0000000 --- a/charts/generic/pod-network-latency/engine.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-network-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-latency-sa - experiments: - - name: pod-network-latency - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: NETWORK_LATENCY - value: '2000' - - - name: JITTER - value: '0' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/charts/generic/pod-network-latency/experiment.yaml b/charts/generic/pod-network-latency/experiment.yaml deleted file mode 100644 index 1159c20..0000000 --- a/charts/generic/pod-network-latency/experiment.yaml +++ /dev/null @@ -1,137 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-latency - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: NETWORK_INTERFACE - value: 'eth0' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_LATENCY - value: '2000' #in ms - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: JITTER - value: '0' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml b/charts/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml deleted file mode 100644 index 8e40c7a..0000000 --- a/charts/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-11T10:28:08Z - name: pod-network-latency - version: 0.1.13 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-latency - categoryDescription: | - Pod-network-latency contains chaos to disrupt network connectivity of kubernetes pods. Experiments can inject random network delays on the app replica pods. - - Causes flaky access to application replica by injecting network delay using pumba. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Network - - Pod - - Latency - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-latency - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-latency/ - - name: Video - url: https://www.youtube.com/watch?v=QsQZyXVCcCw - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-latency/experiment.yaml diff --git a/charts/generic/pod-network-latency/rbac-psp.yaml b/charts/generic/pod-network-latency/rbac-psp.yaml deleted file mode 100644 index ee147c7..0000000 --- a/charts/generic/pod-network-latency/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-latency-sa -subjects: -- kind: ServiceAccount - name: pod-network-latency-sa - namespace: default diff --git a/charts/generic/pod-network-latency/rbac.yaml b/charts/generic/pod-network-latency/rbac.yaml deleted file mode 100644 index 4b65e6b..0000000 --- a/charts/generic/pod-network-latency/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-latency-sa -subjects: -- kind: ServiceAccount - name: pod-network-latency-sa - namespace: default diff --git a/charts/generic/pod-network-loss/experiment.yaml b/charts/generic/pod-network-loss/experiment.yaml deleted file mode 100644 index aefe99e..0000000 --- a/charts/generic/pod-network-loss/experiment.yaml +++ /dev/null @@ -1,134 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-loss - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-loss - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml b/charts/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml deleted file mode 100644 index 71ae971..0000000 --- a/charts/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-11T10:28:08Z - name: pod-network-loss - version: 0.1.12 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-loss - categoryDescription: | - Pod-network-loss contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject percentage packet loss on the app replica pods. - - Causes loss of access to application replica by injecting packet loss 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 - - K8S - - Network - - Pod - - Loss - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-loss - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-loss/ - - name: Video - url: https://www.youtube.com/watch?v=jqvYy-nWc_I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-loss/experiment.yaml diff --git a/charts/generic/pod-network-loss/rbac-psp.yaml b/charts/generic/pod-network-loss/rbac-psp.yaml deleted file mode 100644 index d3af1b8..0000000 --- a/charts/generic/pod-network-loss/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-loss-sa -subjects: -- kind: ServiceAccount - name: pod-network-loss-sa - namespace: default diff --git a/charts/generic/pod-network-loss/rbac.yaml b/charts/generic/pod-network-loss/rbac.yaml deleted file mode 100644 index caa0918..0000000 --- a/charts/generic/pod-network-loss/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-loss-sa -subjects: -- kind: ServiceAccount - name: pod-network-loss-sa - namespace: default diff --git a/charts/generic/pod-network-partition/experiment.yaml b/charts/generic/pod-network-partition/experiment.yaml deleted file mode 100644 index 06ee41e..0000000 --- a/charts/generic/pod-network-partition/experiment.yaml +++ /dev/null @@ -1,96 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects 100% network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-partition - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-partition - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide network policy type - # support ingress, egress, all values - - name: POLICY_TYPES - value: 'all' - - # provide labels of the destination pods - - name: POD_SELECTOR - value: '' - - # provide labels the destination namespaces - - name: NAMESPACE_SELECTOR - value: '' - - # provide comma separated ports - - name: PORTS - value: '' - - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml b/charts/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml deleted file mode 100644 index 89b3957..0000000 --- a/charts/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-08-25T10:28:08Z - name: pod-network-partition - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-partition - categoryDescription: | - pod-network-partition contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject complete egress/ingress network loss based on label and namespace selectors. - - The application pod should be healthy once chaos is stopped. Service-requests should be served (say, via alternate replicas) despite chaos. - keywords: - - Kubernetes - - K8S - - Pod - - Network - - Partition - platforms: - - Minikube - - Packet(Kubeadm) - maturity: alpha - maintainers: - - name: ispeakc0de - email: shubham@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-partition - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-partition/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-partition/experiment.yaml diff --git a/charts/generic/pod-network-partition/rbac-psp.yaml b/charts/generic/pod-network-partition/rbac-psp.yaml deleted file mode 100644 index 9335123..0000000 --- a/charts/generic/pod-network-partition/rbac-psp.yaml +++ /dev/null @@ -1,72 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-partition-sa -subjects: -- kind: ServiceAccount - name: pod-network-partition-sa - namespace: default diff --git a/charts/generic/pod-network-partition/rbac.yaml b/charts/generic/pod-network-partition/rbac.yaml deleted file mode 100644 index e2a0ae7..0000000 --- a/charts/generic/pod-network-partition/rbac.yaml +++ /dev/null @@ -1,67 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-partition-sa -subjects: -- kind: ServiceAccount - name: pod-network-partition-sa - namespace: default diff --git a/charts/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml b/charts/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml deleted file mode 100755 index 1632138..0000000 --- a/charts/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: aws-az-chaos - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-az-chaos - categoryDescription: > - Execute aws-az chaos to detach the target zones from the load balancer - keywords: - - "zone" - - "load-balancer" - - "aws" - platforms: - - "AWS" - maturity: alpha - maintainers: - - name: oumkale - email: imkaleoum@gmail.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-python/tree/master/experiments/aws_az - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/aws-az-chaos/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/aws-az-chaos/experiment.yaml diff --git a/charts/kube-aws/aws-az-chaos/rbac.yaml b/charts/kube-aws/aws-az-chaos/rbac.yaml deleted file mode 100755 index 3d2284c..0000000 --- a/charts/kube-aws/aws-az-chaos/rbac.yaml +++ /dev/null @@ -1,60 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1beta1 -kind: Role -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1beta1 -kind: RoleBinding -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: aws-az-chaos-sa -subjects: -- kind: ServiceAccount - name: aws-az-chaos-sa - namespace: default \ No newline at end of file diff --git a/charts/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml b/charts/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml deleted file mode 100644 index 9946442..0000000 --- a/charts/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-10-28T10:28:08Z - name: ebs-loss-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: ebs-loss-by-id - categoryDescription: | - EBS Loss By ID contains chaos to disrupt state of infra resources. The experiment can induce ebs volume loss against specified application for the give EBS Volume(s). - - Causes ebs volume loss from node or ec2 instance for a certain chaos interval from total chaos duration. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod - keywords: - - EBS - - Volume - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ebs-loss-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ebs-loss-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ebs-loss-by-id/experiment.yaml diff --git a/charts/kube-aws/ebs-loss-by-id/experiment.yaml b/charts/kube-aws/ebs-loss-by-id/experiment.yaml deleted file mode 100644 index 73c8661..0000000 --- a/charts/kube-aws/ebs-loss-by-id/experiment.yaml +++ /dev/null @@ -1,83 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-id - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/kube-aws/ebs-loss-by-id/rbac.yaml b/charts/kube-aws/ebs-loss-by-id/rbac.yaml deleted file mode 100644 index 52a1c57..0000000 --- a/charts/kube-aws/ebs-loss-by-id/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ebs-loss-by-id-sa - namespace: default - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ebs-loss-by-id-sa - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ebs-loss-by-id-sa - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ebs-loss-by-id-sa -subjects: -- kind: ServiceAccount - name: ebs-loss-by-id-sa - namespace: default diff --git a/charts/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml b/charts/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml deleted file mode 100644 index 95eca97..0000000 --- a/charts/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-15T10:28:08Z - name: ebs-loss-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: ebs-loss-by-tag - categoryDescription: | - EBS Loss By Tag contains chaos to disrupt state of infra resources. The experiment can induce ebs volume loss against specified application for given volume tag. - - Causes ebs volume loss by tag from node or ec2 instance for certain chaos interval from total chaos duration. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod - keywords: - - EBS - - Volume - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ebs-loss-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ebs-loss-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ebs-loss-by-tag/experiment.yaml diff --git a/charts/kube-aws/ebs-loss-by-tag/experiment.yaml b/charts/kube-aws/ebs-loss-by-tag/experiment.yaml deleted file mode 100644 index aa652e6..0000000 --- a/charts/kube-aws/ebs-loss-by-tag/experiment.yaml +++ /dev/null @@ -1,85 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-tag - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_TAG - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - - name: VOLUME_AFFECTED_PERC - value: '' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/kube-aws/ebs-loss-by-tag/rbac.yaml b/charts/kube-aws/ebs-loss-by-tag/rbac.yaml deleted file mode 100644 index 52ad320..0000000 --- a/charts/kube-aws/ebs-loss-by-tag/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ebs-loss-by-tag-sa - namespace: default - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ebs-loss-by-tag-sa - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ebs-loss-by-tag-sa - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ebs-loss-by-tag-sa -subjects: -- kind: ServiceAccount - name: ebs-loss-by-tag-sa - namespace: default diff --git a/charts/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml b/charts/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml deleted file mode 100644 index b8de45f..0000000 --- a/charts/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-10-28T10:28:08Z - name: ec2-terminate-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: Mayadata - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: ec2-terminate-by-id - categoryDescription: | - This experiment causes termination of an EC2 instance for a certain chaos duration. - - Causes termination of an EC2 instance provided by instance ID before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the ec2 instance. - keywords: - - EC2 - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ec2-terminate-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ec2-terminate-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ec2-terminate-by-id/experiment.yaml diff --git a/charts/kube-aws/ec2-terminate-by-id/engine.yaml b/charts/kube-aws/ec2-terminate-by-id/engine.yaml deleted file mode 100644 index efceae8..0000000 --- a/charts/kube-aws/ec2-terminate-by-id/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: ec2-terminate-by-id-sa - experiments: - - name: ec2-terminate-by-id - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set interval duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - # provide the region name of the instance - - name: REGION - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' \ No newline at end of file diff --git a/charts/kube-aws/ec2-terminate-by-id/experiment.yaml b/charts/kube-aws/ec2-terminate-by-id/experiment.yaml deleted file mode 100644 index 21b6bbf..0000000 --- a/charts/kube-aws/ec2-terminate-by-id/experiment.yaml +++ /dev/null @@ -1,93 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by ID. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-id - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/kube-aws/ec2-terminate-by-id/rbac.yaml b/charts/kube-aws/ec2-terminate-by-id/rbac.yaml deleted file mode 100644 index 0f7fb1c..0000000 --- a/charts/kube-aws/ec2-terminate-by-id/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ec2-terminate-by-id-sa - namespace: default - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ec2-terminate-by-id-sa - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ec2-terminate-by-id-sa - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ec2-terminate-by-id-sa -subjects: -- kind: ServiceAccount - name: ec2-terminate-by-id-sa - namespace: default \ No newline at end of file diff --git a/charts/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml b/charts/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml deleted file mode 100644 index 1caf610..0000000 --- a/charts/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-15T10:28:08Z - name: ec2-terminate-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: Mayadata - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: ec2-terminate-by-tag - categoryDescription: | - This experiment causes termination of an EC2 instance for a certain chaos duration. - - Causes termination of an EC2 instance using instance tags before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the ec2 instance. - keywords: - - EC2 - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ec2-terminate-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ec2-terminate-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ec2-terminate-by-tag/experiment.yaml diff --git a/charts/kube-aws/ec2-terminate-by-tag/experiment.yaml b/charts/kube-aws/ec2-terminate-by-tag/experiment.yaml deleted file mode 100644 index 15cb10c..0000000 --- a/charts/kube-aws/ec2-terminate-by-tag/experiment.yaml +++ /dev/null @@ -1,95 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by tag. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-tag - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: INSTANCE_TAG - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - - name: REGION - value: '' - - # Target the percentage of instance filtered from tag - - name: INSTANCE_AFFECTED_PERC - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/charts/kube-aws/ec2-terminate-by-tag/rbac.yaml b/charts/kube-aws/ec2-terminate-by-tag/rbac.yaml deleted file mode 100644 index e03101d..0000000 --- a/charts/kube-aws/ec2-terminate-by-tag/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ec2-terminate-by-tag-sa - namespace: default - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ec2-terminate-by-tag-sa - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ec2-terminate-by-tag-sa - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ec2-terminate-by-tag-sa -subjects: -- kind: ServiceAccount - name: ec2-terminate-by-tag-sa - namespace: default \ No newline at end of file diff --git a/charts/kube-aws/experiments.yaml b/charts/kube-aws/experiments.yaml deleted file mode 100644 index d28a523..0000000 --- a/charts/kube-aws/experiments.yaml +++ /dev/null @@ -1,442 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by tag. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-tag - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: INSTANCE_TAG - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - - name: REGION - value: '' - - # Target the percentage of instance filtered from tag - - name: INSTANCE_AFFECTED_PERC - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by ID. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-id - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute aws-az chaos to detach the target zones from the load balancer -kind: ChaosExperiment -metadata: - name: aws-az-chaos - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/py-runner:latest" - imagePullPolicy: Always - args: - - -c - - python3 -u experiment -name aws-az-chaos - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - name: CHAOS_INTERVAL - value: '30' - - name: LIB - value: 'litmus' - - name: LOAD_BALANCER_NAME - value: '' - - name: LOAD_BALANCER_ZONES - value: '' - - name: LOAD_BALANCERNAME_ARN - value: 'na' - - name: AWS_SHARED_CREDENTIALS_FILE - value: "/tmp/cloud_config.yml" - - name: RAMP_TIME - value: '' - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-tag - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_TAG - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - - name: VOLUME_AFFECTED_PERC - value: '' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-id - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/charts/kube-aws/icons/aws-az-chaos.png b/charts/kube-aws/icons/aws-az-chaos.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/aws-az-chaos.png and /dev/null differ diff --git a/charts/kube-aws/icons/ebs-loss-by-id.png b/charts/kube-aws/icons/ebs-loss-by-id.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/ebs-loss-by-id.png and /dev/null differ diff --git a/charts/kube-aws/icons/ebs-loss-by-tag.png b/charts/kube-aws/icons/ebs-loss-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/ebs-loss-by-tag.png and /dev/null differ diff --git a/charts/kube-aws/icons/ec2-terminate-by-id.png b/charts/kube-aws/icons/ec2-terminate-by-id.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/ec2-terminate-by-id.png and /dev/null differ diff --git a/charts/kube-aws/icons/ec2-terminate-by-tag.png b/charts/kube-aws/icons/ec2-terminate-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/ec2-terminate-by-tag.png and /dev/null differ diff --git a/charts/kube-aws/icons/k8-aws-ec2-terminate.png b/charts/kube-aws/icons/k8-aws-ec2-terminate.png deleted file mode 100644 index cb58737..0000000 Binary files a/charts/kube-aws/icons/k8-aws-ec2-terminate.png and /dev/null differ diff --git a/charts/kube-aws/icons/kube-aws.png b/charts/kube-aws/icons/kube-aws.png deleted file mode 100644 index fd09e34..0000000 Binary files a/charts/kube-aws/icons/kube-aws.png and /dev/null differ diff --git a/charts/kube-aws/kube-aws.chartserviceversion.yaml b/charts/kube-aws/kube-aws.chartserviceversion.yaml deleted file mode 100644 index cb18e72..0000000 --- a/charts/kube-aws/kube-aws.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-09-26T10:28:08Z - name: kube-aws - version: 0.1.16 - annotations: - categories: Kubernetes - chartDescription: Injects kube-aws kubernetes chaos -spec: - displayName: Kube AWS - categoryDescription: > - kube-aws contains chaos to disrupt state of aws resources running part of kubernetes cluster - experiments: - - ec2-terminate-by-id - - ec2-terminate-by-tag - - ebs-loss-by-id - - ebs-loss-by-tag - - aws-az-chaos - keywords: - - AWS - - EC2 - - EBS - - AZ - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - - name: oumkale - email: imkaleoum@gmail.com - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws - - name: Source Code - url: https://github.com/litmuschaos/litmus-python/tree/master/experiments/aws_az - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/icons/kube-aws.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/experiments.yaml diff --git a/charts/kube-aws/kube-aws.package.yaml b/charts/kube-aws/kube-aws.package.yaml deleted file mode 100644 index db03f2e..0000000 --- a/charts/kube-aws/kube-aws.package.yaml +++ /dev/null @@ -1,17 +0,0 @@ -packageName: kube-aws -experiments: - - name: ec2-terminate-by-id - CSV: ec2-terminate-by-id.chartserviceversion.yaml - desc: "ec2-terminate-by-id" - - name: ec2-terminate-by-tag - CSV: ec2-terminate-by-tag.chartserviceversion.yaml - desc: "ec2-terminate-by-tag" - - name: ebs-loss-by-id - CSV: ebs-loss-by-id.chartserviceversion.yaml - desc: "ebs-loss-by-id" - - name: ebs-loss-by-tag - CSV: ebs-loss-by-tag.chartserviceversion.yaml - desc: "ebs-loss-by-tag" - - name: aws-az-chaos - CSV: aws-az-chaos.chartserviceversion.yaml - desc: "aws-az-chaos" diff --git a/charts/kube-aws/rbac-admin.yaml b/charts/kube-aws/rbac-admin.yaml deleted file mode 100644 index f386c6c..0000000 --- a/charts/kube-aws/rbac-admin.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: chaos-admin - labels: - name: chaos-admin ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: chaos-admin - labels: - name: chaos-admin -rules: -- apiGroups: ["","apps","batch","extensions","litmuschaos.io","openebs.io","storage.k8s.io"] - resources: ["chaosengines","chaosexperiments","chaosresults","configmaps","cstorpools","cstorvolumereplicas","events","jobs","persistentvolumeclaims","persistentvolumes","pods","pods/exec","pods/log","secrets","storageclasses","chaosengines","chaosexperiments","chaosresults","configmaps","cstorpools","cstorvolumereplicas","daemonsets","deployments","events","jobs","persistentvolumeclaims","persistentvolumes","pods","pods/eviction","pods/exec","pods/log","replicasets","secrets","services","statefulsets","storageclasses"] - verbs: ["create","delete","get","list","patch","update"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: chaos-admin - labels: - name: chaos-admin -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: chaos-admin -subjects: -- kind: ServiceAccount - name: chaos-admin - namespace: default diff --git a/charts/mongodb/experiments.yaml b/charts/mongodb/experiments.yaml deleted file mode 100644 index e69de29..0000000 diff --git a/charts/mongodb/icons/mongodb.png b/charts/mongodb/icons/mongodb.png deleted file mode 100644 index ab6378f..0000000 Binary files a/charts/mongodb/icons/mongodb.png and /dev/null differ diff --git a/charts/mongodb/mongodb.chartserviceversion.yaml b/charts/mongodb/mongodb.chartserviceversion.yaml deleted file mode 100644 index 2849aab..0000000 --- a/charts/mongodb/mongodb.chartserviceversion.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-17T10:28:08Z - name: mongodb - version: 0.0.2 - annotations: - categories: mongodb - chartDescription: Injects chaos on mongodb components -spec: - displayName: MongoDB Chaos - categoryDescription: > - MongoDB is a general purpose, document-based, distributed database built for modern application developers and for the cloud era. - experiments: - keywords: - - Kubernetes - - MongoDB - maintainers: - - name: Sanjay1611 - email: sanjay.nathani@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: MongoDB Website - url: https://www.mongodb.com/ - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/mongodb/experiments.yaml diff --git a/charts/mongodb/mongodb.package.yaml b/charts/mongodb/mongodb.package.yaml deleted file mode 100644 index 1ad30e8..0000000 --- a/charts/mongodb/mongodb.package.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packageName: mongodb -experiments: diff --git a/charts/spring-boot/experiments.yaml b/charts/spring-boot/experiments.yaml deleted file mode 100644 index 10e5e5b..0000000 --- a/charts/spring-boot/experiments.yaml +++ /dev/null @@ -1,605 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency -kind: ChaosExperiment -metadata: - name: spring-boot-exceptions - labels: - name: spring-boot-exceptions - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-exceptions - command: - - /bin/bash - env: - - # Type of raised exception - - name: CM_EXCEPTIONS_TYPE - value: 'java.lang.IllegalArgumentException' - - # Argument of raised exception - - name: CM_EXCEPTIONS_ARGUMENTS - value: 'java.lang.String:custom illegal argument exception' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-exceptions - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress -kind: ChaosExperiment -metadata: - name: spring-boot-cpu-stress - labels: - name: spring-boot-cpu-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-cpu-stress - command: - - /bin/bash - env: - - # it contains fraction of cpu to be stressed(0.95 equals 95%) - # it supports value in range [0.1,1.0] - - name: CPU_LOAD_FRACTION - value: '0.9' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-cpu-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress -kind: ChaosExperiment -metadata: - name: spring-boot-memory-stress - labels: - name: spring-boot-memory-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-memory-stress - command: - - /bin/bash - env: - - # it contains fraction of memory to be stressed(0.70 equals 70%) - # it supports value in range [0.01,0.95] - - name: MEMORY_FILL_FRACTION - value: '0.70' - - # port of the spring boot application - - name: CM_PORT - value: '' - - # it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-memory-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency -kind: ChaosExperiment -metadata: - name: spring-boot-latency - labels: - name: spring-boot-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-latency - command: - - /bin/bash - env: - - # provide the latency (ms) - - name: LATENCY - value: '2000' - - # port of the spring boot application - - name: CM_PORT - value: '' - - # it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill -kind: ChaosExperiment -metadata: - name: spring-boot-app-kill - labels: - name: spring-boot-app-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-app-kill - command: - - /bin/bash - env: - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-app-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress -kind: ChaosExperiment -metadata: - name: spring-boot-faults - labels: - name: spring-boot-faults - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-faults - command: - - /bin/bash - env: - - # it enables spring app-kill fault - - name: CM_KILL_APPLICATION_ACTIVE - value: '' - - # it enables spring-boot latency fault - - name: CM_LATENCY_ACTIVE - value: '' - - # provide the latency (ms) - # it is applicable when latency is active - - name: LATENCY - value: '2000' - - # it enables spring-boot memory stress fault - - name: CM_MEMORY_ACTIVE - value: '' - - # it contains fraction of memory to be stressed(0.70 equals 70%) - # it supports value in range [0.01,0.95] - # it is applicable when memory is active - - name: MEMORY_FILL_FRACTION - value: '0.70' - - # it enables spring-boot cpu stress fault - - name: CM_CPU_ACTIVE - value: '' - - # it contains fraction of cpu to be stressed(0.95 equals 95%) - # it supports value in range [0.1,1.0] - # it is applicable when cpu is active - - name: CPU_LOAD_FRACTION - value: '0.9' - - # it enables spring-boot exceptions fault - - name: CM_EXCEPTIONS_ACTIVE - value: '' - - # Type of raised exception - # it is applicable when exceptions is active - - name: CM_EXCEPTIONS_TYPE - value: 'java.lang.IllegalArgumentException' - - # Argument of raised exception - # it is applicable when exceptions is active - - name: CM_EXCEPTIONS_ARGUMENTS - value: 'java.lang.String:custom illegal argument exception' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-faults - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- diff --git a/charts/spring-boot/spring-boot-app-kill/experiment.yaml b/charts/spring-boot/spring-boot-app-kill/experiment.yaml deleted file mode 100644 index 6e5864b..0000000 --- a/charts/spring-boot/spring-boot-app-kill/experiment.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill -kind: ChaosExperiment -metadata: - name: spring-boot-app-kill - labels: - name: spring-boot-app-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-app-kill - command: - - /bin/bash - env: - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-app-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-app-kill/rbac.yaml b/charts/spring-boot/spring-boot-app-kill/rbac.yaml deleted file mode 100644 index 991ef22..0000000 --- a/charts/spring-boot/spring-boot-app-kill/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-app-kill-sa - namespace: default - labels: - name: spring-boot-app-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-app-kill-sa - namespace: default - labels: - name: spring-boot-app-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-app-kill-sa - namespace: default - labels: - name: spring-boot-app-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-app-kill-sa -subjects: -- kind: ServiceAccount - name: spring-boot-app-kill-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot-cpu-stress/experiment.yaml b/charts/spring-boot/spring-boot-cpu-stress/experiment.yaml deleted file mode 100644 index 4c4f030..0000000 --- a/charts/spring-boot/spring-boot-cpu-stress/experiment.yaml +++ /dev/null @@ -1,93 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress -kind: ChaosExperiment -metadata: - name: spring-boot-cpu-stress - labels: - name: spring-boot-cpu-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-cpu-stress - command: - - /bin/bash - env: - - # it contains fraction of cpu to be stressed(0.95 equals 95%) - # it supports value in range [0.1,1.0] - - name: CPU_LOAD_FRACTION - value: '0.9' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-cpu-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-cpu-stress/rbac.yaml b/charts/spring-boot/spring-boot-cpu-stress/rbac.yaml deleted file mode 100644 index 812ec5b..0000000 --- a/charts/spring-boot/spring-boot-cpu-stress/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-cpu-stress-sa - namespace: default - labels: - name: spring-boot-cpu-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-cpu-stress-sa - namespace: default - labels: - name: spring-boot-cpu-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-cpu-stress-sa - namespace: default - labels: - name: spring-boot-cpu-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-cpu-stress-sa -subjects: -- kind: ServiceAccount - name: spring-boot-cpu-stress-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot-exceptions/experiment.yaml b/charts/spring-boot/spring-boot-exceptions/experiment.yaml deleted file mode 100644 index d0b4732..0000000 --- a/charts/spring-boot/spring-boot-exceptions/experiment.yaml +++ /dev/null @@ -1,96 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency -kind: ChaosExperiment -metadata: - name: spring-boot-exceptions - labels: - name: spring-boot-exceptions - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-exceptions - command: - - /bin/bash - env: - - # Type of raised exception - - name: CM_EXCEPTIONS_TYPE - value: 'java.lang.IllegalArgumentException' - - # Argument of raised exception - - name: CM_EXCEPTIONS_ARGUMENTS - value: 'java.lang.String:custom illegal argument exception' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-exceptions - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-exceptions/rbac.yaml b/charts/spring-boot/spring-boot-exceptions/rbac.yaml deleted file mode 100644 index 6ef38ba..0000000 --- a/charts/spring-boot/spring-boot-exceptions/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-exceptions-sa - namespace: default - labels: - name: spring-boot-exceptions-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-exceptions-sa - namespace: default - labels: - name: spring-boot-exceptions-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-exceptions-sa - namespace: default - labels: - name: spring-boot-exceptions-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-exceptions-sa -subjects: -- kind: ServiceAccount - name: spring-boot-exceptions-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot-faults/experiment.yaml b/charts/spring-boot/spring-boot-faults/experiment.yaml deleted file mode 100644 index 8f47e56..0000000 --- a/charts/spring-boot/spring-boot-faults/experiment.yaml +++ /dev/null @@ -1,135 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress -kind: ChaosExperiment -metadata: - name: spring-boot-faults - labels: - name: spring-boot-faults - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-faults - command: - - /bin/bash - env: - - # it enables spring app-kill fault - - name: CM_KILL_APPLICATION_ACTIVE - value: '' - - # it enables spring-boot latency fault - - name: CM_LATENCY_ACTIVE - value: '' - - # provide the latency (ms) - # it is applicable when latency is active - - name: LATENCY - value: '2000' - - # it enables spring-boot memory stress fault - - name: CM_MEMORY_ACTIVE - value: '' - - # it contains fraction of memory to be stressed(0.70 equals 70%) - # it supports value in range [0.01,0.95] - # it is applicable when memory is active - - name: MEMORY_FILL_FRACTION - value: '0.70' - - # it enables spring-boot cpu stress fault - - name: CM_CPU_ACTIVE - value: '' - - # it contains fraction of cpu to be stressed(0.95 equals 95%) - # it supports value in range [0.1,1.0] - # it is applicable when cpu is active - - name: CPU_LOAD_FRACTION - value: '0.9' - - # it enables spring-boot exceptions fault - - name: CM_EXCEPTIONS_ACTIVE - value: '' - - # Type of raised exception - # it is applicable when exceptions is active - - name: CM_EXCEPTIONS_TYPE - value: 'java.lang.IllegalArgumentException' - - # Argument of raised exception - # it is applicable when exceptions is active - - name: CM_EXCEPTIONS_ARGUMENTS - value: 'java.lang.String:custom illegal argument exception' - - # port of the spring boot application - - name: CM_PORT - value: '' - - #it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-faults - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-faults/rbac.yaml b/charts/spring-boot/spring-boot-faults/rbac.yaml deleted file mode 100644 index 3a124c9..0000000 --- a/charts/spring-boot/spring-boot-faults/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-faults-sa - namespace: default - labels: - name: spring-boot-faults-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-faults-sa - namespace: default - labels: - name: spring-boot-faults-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-faults-sa - namespace: default - labels: - name: spring-boot-faults-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-faults-sa -subjects: -- kind: ServiceAccount - name: spring-boot-faults-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot-latency/experiment.yaml b/charts/spring-boot/spring-boot-latency/experiment.yaml deleted file mode 100644 index 3ae2dc4..0000000 --- a/charts/spring-boot/spring-boot-latency/experiment.yaml +++ /dev/null @@ -1,92 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency -kind: ChaosExperiment -metadata: - name: spring-boot-latency - labels: - name: spring-boot-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-latency - command: - - /bin/bash - env: - - # provide the latency (ms) - - name: LATENCY - value: '2000' - - # port of the spring boot application - - name: CM_PORT - value: '' - - # it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-latency/rbac.yaml b/charts/spring-boot/spring-boot-latency/rbac.yaml deleted file mode 100644 index 91b9639..0000000 --- a/charts/spring-boot/spring-boot-latency/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-latency-sa - namespace: default - labels: - name: spring-boot-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-latency-sa - namespace: default - labels: - name: spring-boot-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-latency-sa - namespace: default - labels: - name: spring-boot-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-latency-sa -subjects: -- kind: ServiceAccount - name: spring-boot-latency-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot-memory-stress/experiment.yaml b/charts/spring-boot/spring-boot-memory-stress/experiment.yaml deleted file mode 100644 index 80be563..0000000 --- a/charts/spring-boot/spring-boot-memory-stress/experiment.yaml +++ /dev/null @@ -1,93 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress -kind: ChaosExperiment -metadata: - name: spring-boot-memory-stress - labels: - name: spring-boot-memory-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [ "" ] - resources: [ "pods" ] - verbs: [ "create","delete","get","list","patch","update", "deletecollection" ] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [ "" ] - resources: [ "events" ] - verbs: [ "create","get","list","patch","update" ] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [ "" ] - resources: [ "pods/log" ] - verbs: [ "get","list","watch" ] - # for creating and managing to execute commands inside target container - - apiGroups: [ "" ] - resources: [ "pods/exec" ] - verbs: [ "get","list","create" ] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: [ "batch" ] - resources: [ "jobs" ] - verbs: [ "create","list","get","delete","deletecollection" ] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: [ "litmuschaos.io" ] - resources: [ "chaosengines","chaosexperiments","chaosresults" ] - verbs: [ "create","list","get","patch","update","delete" ] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name spring-boot-memory-stress - command: - - /bin/bash - env: - - # it contains fraction of memory to be stressed(0.70 equals 70%) - # it supports value in range [0.01,0.95] - - name: MEMORY_FILL_FRACTION - value: '0.70' - - # port of the spring boot application - - name: CM_PORT - value: '' - - # it contains number of requests are to be attacked - # n value means nth request will be affected - - name: CM_LEVEL - value: '1' - - # it limits watched packages/classes/methods - - name: CM_WATCHED_CUSTOM_SERVICES - value: '' - - # provide name of watcher - # it supports controller, restController, service, repository, component, webClient - - name: CM_WATCHERS - value: 'restController' - - - name: TOTAL_CHAOS_DURATION - value: '30' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos - - name: RAMP_TIME - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: spring-boot-memory-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/spring-boot/spring-boot-memory-stress/rbac.yaml b/charts/spring-boot/spring-boot-memory-stress/rbac.yaml deleted file mode 100644 index 4b46775..0000000 --- a/charts/spring-boot/spring-boot-memory-stress/rbac.yaml +++ /dev/null @@ -1,61 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: spring-boot-memory-stress-sa - namespace: default - labels: - name: spring-boot-memory-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: spring-boot-memory-stress-sa - namespace: default - labels: - name: spring-boot-memory-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute commands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: spring-boot-memory-stress-sa - namespace: default - labels: - name: spring-boot-memory-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: spring-boot-memory-stress-sa -subjects: -- kind: ServiceAccount - name: spring-boot-memory-stress-sa - namespace: default - diff --git a/charts/spring-boot/spring-boot.chartserviceversion.yaml b/charts/spring-boot/spring-boot.chartserviceversion.yaml deleted file mode 100644 index 5f2409e..0000000 --- a/charts/spring-boot/spring-boot.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2022-11-17T10:28:08Z - name: spring-boot - version: 0.1.0 - annotations: - categories: Spring Boot - chartDescription: Injects spring boot chaos -spec: - displayName: Spring Boot Chaos - categoryDescription: > - It contains chaos to disrupt state of spring-boot application. - experiments: - - spring-boot-app-kill - - spring-boot-cpu-stress - - spring-boot-memory-stress - - spring-boot-latency - - spring-boot-exceptions - - spring-boot-faults - keywords: - - Kubernetes - - Spring Boot - - K8S - - Pod - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io - minKubeVersion: 1.12.0 - provider: - name: Orange - links: - - name: Documentation - url: https://spring.io/projects/spring-boot - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot/icons/spring-boot.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot/experiments.yaml diff --git a/charts/vmware/experiments.yaml b/charts/vmware/experiments.yaml deleted file mode 100644 index 57f67db..0000000 --- a/charts/vmware/experiments.yaml +++ /dev/null @@ -1,96 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops one or more VMs for a certain chaos duration. -kind: ChaosExperiment -metadata: - name: vm-poweroff - labels: - name: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name vm-poweroff - command: - - /bin/bash - env: - - - name: VCENTERSERVER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERSERVER - - - name: VCENTERUSER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERUSER - - - name: VCENTERPASS - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERPASS - - # provide the VM MOIDs as comma separated values - - name: APP_VM_MOIDS - value: '' - - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos interval (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - # parallel or sequence; the mode of chaos sequence, defaults to parallel - - name: SEQUENCE - value: 'parallel' - - labels: - experiment: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- diff --git a/charts/vmware/vm-poweroff/engine.yaml b/charts/vmware/vm-poweroff/engine.yaml deleted file mode 100644 index a9fa88a..0000000 --- a/charts/vmware/vm-poweroff/engine.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: vmware-vm-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: vm-poweroff-sa - experiments: - - name: vm-poweroff - 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: '30' - - # provide VM MOIDs as comma separated values - - name: APP_VM_MOIDS - value: '' diff --git a/charts/vmware/vm-poweroff/experiment.yaml b/charts/vmware/vm-poweroff/experiment.yaml deleted file mode 100644 index cab2259..0000000 --- a/charts/vmware/vm-poweroff/experiment.yaml +++ /dev/null @@ -1,94 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops one or more VMs for a certain chaos duration. -kind: ChaosExperiment -metadata: - name: vm-poweroff - labels: - name: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name vm-poweroff - command: - - /bin/bash - env: - - - name: VCENTERSERVER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERSERVER - - - name: VCENTERUSER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERUSER - - - name: VCENTERPASS - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERPASS - - # provide the VM MOIDs as comma separated values - - name: APP_VM_MOIDS - value: '' - - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos interval (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - # parallel or sequence; the mode of chaos sequence, defaults to parallel - - name: SEQUENCE - value: 'parallel' - - labels: - experiment: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/charts/vmware/vm-poweroff/rbac.yaml b/charts/vmware/vm-poweroff/rbac.yaml deleted file mode 100644 index 4bbd8ee..0000000 --- a/charts/vmware/vm-poweroff/rbac.yaml +++ /dev/null @@ -1,63 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: vm-poweroff-sa - namespace: default - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: vm-poweroff-sa - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: vm-poweroff-sa - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: vm-poweroff-sa -subjects: -- kind: ServiceAccount - name: vm-poweroff-sa - namespace: default - diff --git a/charts/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml b/charts/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml deleted file mode 100644 index 0b2ad00..0000000 --- a/charts/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-29T10:28:08Z - name: vm-poweroff - annotations: - categories: vmware - vendor: Wipro, ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: vm-poweroff - categoryDescription: | - This experiment causes power-off of target VMWare VM(s) for a certain chaos duration: - - Causes power-off of the VMWare VM(s) provided by the Moid(s) of the instance. - - It helps to check the performance of the application/services on the instance. - - Currently, the experiment is supported for vsphere version 6.X (Support for 7.X will be added soon). - - keywords: - - Vmware - - VM - platforms: - - vmware - maturity: alpha - maintainers: - - name: Delphine Joyneer, Neelanjan Manna - email: golkonda.joyneer@wipro.com, neelanjan@chaosnative.com - provider: - name: Wipro, ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/vmware/vm-poweroff - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/vmware/vm-poweroff/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/vmware/vm-poweroff/experiment.yaml diff --git a/charts/vmware/vmware.chartserviceversion.yaml b/charts/vmware/vmware.chartserviceversion.yaml deleted file mode 100644 index 8c4ed26..0000000 --- a/charts/vmware/vmware.chartserviceversion.yaml +++ /dev/null @@ -1,34 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-29T10:28:08Z - name: vmware - version: 0.1.0 - annotations: - categories: vmware - chartDescription: Injects chaos on VMWare components -spec: - displayName: VMWare Chaos - categoryDescription: > - Contains chaos to disrupt the state of VMWare resources - experiments: - - vm-poweroff - keywords: - - vmware - - VM - maintainers: - - name: Delphine Joyneer, Neelanjan Manna - email: golkonda.joyneer@wipro.com, neelanjan@chaosnative.com - provider: - name: Wipro, ChaosNative - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/vmware - - name: Community Slack - url: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/vmware/experiments.yaml diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml deleted file mode 100644 index bc01916..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-10T10:28:08Z - name: aws-ssm-chaos-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-ssm-chaos-by-id - categoryDescription: | - AWS SSM Chaos By ID contains chaos to disrupt the state of infra resources. The experiment can induce chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos experiments on resources. - - Causes chaos on AWS ec2 instances with given instance ID(s) using SSM docs for total chaos duration with the specified chaos interval. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). - keywords: - - SSM - - AWS - - EC2 - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm/aws-ssm-chaos-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws-ssm/aws-ssm-chaos-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-id/engine.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-id/engine.yaml deleted file mode 100644 index 1133a5a..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-id/engine.yaml +++ /dev/null @@ -1,62 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: aws-ssm-chaos-by-id-sa - experiments: - - name: aws-ssm-chaos-by-id - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - # set chaos duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '60' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - # provide the region name of the target instances - - name: REGION - value: '' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml deleted file mode 100644 index c0f9996..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-id/experiment.yaml +++ /dev/null @@ -1,129 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance IDs -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-id - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml deleted file mode 100644 index 72db75e..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-id/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-ssm-chaos-by-id-sa - namespace: default - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: aws-ssm-chaos-by-id-sa - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for creating and managing to execute comands inside target container -- apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: aws-ssm-chaos-by-id-sa - labels: - name: aws-ssm-chaos-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: aws-ssm-chaos-by-id-sa -subjects: -- kind: ServiceAccount - name: aws-ssm-chaos-by-id-sa - namespace: default diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml deleted file mode 100644 index fea5b08..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-10T10:28:08Z - name: aws-ssm-chaos-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-ssm-chaos-by-tag - categoryDescription: | - AWS SSM Chaos By ID contains chaos to disrupt the state of infra resources. The experiment can induce chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos experiments on resources. - - Causes chaos on AWS ec2 instances with given instance tag using SSM docs for total chaos duration with the specified chaos interval. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). - keywords: - - SSM - - AWS - - EC2 - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm/aws-ssm-chaos-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws-ssm/aws-ssm-chaos-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml deleted file mode 100644 index 19d294b..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-tag/engine.yaml +++ /dev/null @@ -1,62 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: aws-ssm-chaos-by-tag-sa - experiments: - - name: aws-ssm-chaos-by-tag - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - # set chaos duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '60' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - # provide the region name of the target instances - - name: REGION - value: '' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml deleted file mode 100644 index 2ca8c45..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-tag/experiment.yaml +++ /dev/null @@ -1,133 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance Tag -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-tag - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # percentage of total instance to target - - name: INSTANCE_AFFECTED_PERC - value: '' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml b/experiments/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml deleted file mode 100644 index 473d902..0000000 --- a/experiments/aws-ssm/aws-ssm-chaos-by-tag/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-ssm-chaos-by-tag-sa - namespace: default - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: aws-ssm-chaos-by-tag-sa - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for creating and managing to execute comands inside target container -- apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: aws-ssm-chaos-by-tag-sa - labels: - name: aws-ssm-chaos-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: aws-ssm-chaos-by-tag-sa -subjects: -- kind: ServiceAccount - name: aws-ssm-chaos-by-tag-sa - namespace: default diff --git a/experiments/aws-ssm/aws-ssm.chartserviceversion.yaml b/experiments/aws-ssm/aws-ssm.chartserviceversion.yaml deleted file mode 100644 index 38f76a8..0000000 --- a/experiments/aws-ssm/aws-ssm.chartserviceversion.yaml +++ /dev/null @@ -1,38 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-11T10:28:08Z - name: aws-ssm - version: 0.1.0 - annotations: - categories: Kubernetes - chartDescription: Injects aws ssm chaos -spec: - displayName: AWS SSM - categoryDescription: > - aws ssm contains chaos to disrupt state of aws resources by litmus aws ssm docs - experiments: - - name: aws-ssm-chaos-by-id - description: "" - - name: aws-ssm-chaos-by-tag - description: "" - keywords: - - AWS - - SSM - - EC2 - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/aws-ssm - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/icons/aws-ssm.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/aws-ssm/experiments.yaml diff --git a/experiments/aws-ssm/aws-ssm.package.yaml b/experiments/aws-ssm/aws-ssm.package.yaml deleted file mode 100644 index cfae7ec..0000000 --- a/experiments/aws-ssm/aws-ssm.package.yaml +++ /dev/null @@ -1,8 +0,0 @@ -packageName: aws-ssm -experiments: - - name: aws-ssm-chaos-by-id - CSV: aws-ssm-chaos-by-id.chartserviceversion.yaml - desc: "aws-ssm-chaos-by-id" - - name: aws-ssm-chaos-by-tag - CSV: aws-ssm-chaos-by-tag.chartserviceversion.yaml - desc: "aws-ssm-chaos-by-tag" \ No newline at end of file diff --git a/experiments/aws-ssm/experiments.yaml b/experiments/aws-ssm/experiments.yaml deleted file mode 100644 index 6915473..0000000 --- a/experiments/aws-ssm/experiments.yaml +++ /dev/null @@ -1,266 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance IDs -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-id - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to be comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: aws-ssm-chaos-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute AWS SSM Chaos on given ec2 instance Tag -kind: ChaosExperiment -metadata: - name: aws-ssm-chaos-by-tag - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name aws-ssm-chaos-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: CHAOS_INTERVAL - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide tag of the target ec2 instances - # ex: team:devops (key:value) - - name: EC2_INSTANCE_TAG - value: '' - - - name: REGION - value: '' - - # it defines the sequence of chaos execution for multiple target instances - # supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # percentage of total instance to target - - name: INSTANCE_AFFECTED_PERC - value: '' - - # Provide the name of ssm doc - # if not using the default stress docs - - name: DOCUMENT_NAME - value: '' - - # Provide the type of ssm doc - # if not using the default stress docs - - name: DOCUMENT_TYPE - value: '' - - # Provide the format of ssm doc - # if not using the default stress docs - - name: DOCUMENT_FORMAT - value: '' - - # Provide the path of ssm doc - # if not using the default stress docs - - name: DOCUMENT_PATH - value: '' - - # if you want to install dependencies to run default ssm docs - - name: INSTALL_DEPENDENCIES - value: 'True' - - # provide the number of workers for memory stress - - name: NUMBER_OF_WORKERS - value: '1' - - # provide the percentage of available memory to stress - - name: MEMORY_PERCENTAGE - value: '80' - - # provide the CPU chores to comsumed - # 0 will consume all the available cpu cores - - name: CPU_CORE - value: '0' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: aws-ssm-chaos-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/experiments/aws-ssm/icons/aws-ssm-chaos-by-id.png b/experiments/aws-ssm/icons/aws-ssm-chaos-by-id.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/aws-ssm/icons/aws-ssm-chaos-by-id.png and /dev/null differ diff --git a/experiments/aws-ssm/icons/aws-ssm-chaos-by-tag.png b/experiments/aws-ssm/icons/aws-ssm-chaos-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/aws-ssm/icons/aws-ssm-chaos-by-tag.png and /dev/null differ diff --git a/experiments/aws-ssm/icons/aws-ssm.png b/experiments/aws-ssm/icons/aws-ssm.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/aws-ssm/icons/aws-ssm.png and /dev/null differ diff --git a/experiments/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml b/experiments/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml deleted file mode 100644 index ab5f152..0000000 --- a/experiments/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: azure-disk-loss - version: 0.1.0 - annotations: - categories: Azure - vendor: ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: azure-disk-loss - categoryDescription: | - This experiment causes the detachment of the disk from the VM for a certain chaos duration - - Causes detachment of the disk from the VM and then reattachment of the disk to the VM - - It helps to check the performance of the application on the instance. - keywords: - - Azure - - Disk - - AKS - platforms: - - Azure - maturity: alpha - maintainers: - - name: avaakash - email: akash@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/azure/disk-loss/experiment - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/azure/azure-disk-loss/ - # - name: Video - # url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/azure-disk-loss/experiment.yaml \ No newline at end of file diff --git a/experiments/azure/azure-disk-loss/experiment.yaml b/experiments/azure/azure-disk-loss/experiment.yaml deleted file mode 100644 index 0b25921..0000000 --- a/experiments/azure/azure-disk-loss/experiment.yaml +++ /dev/null @@ -1,95 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaches disk from the VM and then re-attaches disk to the VM -kind: ChaosExperiment -metadata: - name: azure-disk-loss - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # provide the virtual disk names (comma separated if multiple) - - name: VIRTUAL_DISK_NAMES - value: '' - - # provide the sequence type for the run. Options: serial/parallel - - name: SEQUENCE - value: 'parallel' - - # provide the path to aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/azure/azure-disk-loss/rbac.yaml b/experiments/azure/azure-disk-loss/rbac.yaml deleted file mode 100644 index 0e91994..0000000 --- a/experiments/azure/azure-disk-loss/rbac.yaml +++ /dev/null @@ -1,64 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: azure-disk-loss-sa - namespace: default - labels: - name: azure-disk-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: azure-disk-loss-sa -subjects: -- kind: ServiceAccount - name: azure-disk-loss-sa - namespace: default \ No newline at end of file diff --git a/experiments/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml b/experiments/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml deleted file mode 100644 index a6db416..0000000 --- a/experiments/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-02-20T10:28:08Z - name: azure-instance-stop - version: 0.1.0 - annotations: - categories: Azure - vendor: ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: azure-instance-stop - categoryDescription: | - This experiment causes the power off of an azure instance for a certain chaos duration. - - Causes termination of an azure instance before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the instance. - keywords: - - Azure - - Scaleset - - AKS - platforms: - - Azure - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - provider: - name: Chaos Native - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/azure/instance-stop/experiment - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/azure/azure-instance-stop/ - # - name: Video - # url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/azure-instance-stop/experiment.yaml - diff --git a/experiments/azure/azure-instance-stop/engine.yaml b/experiments/azure/azure-instance-stop/engine.yaml deleted file mode 100644 index b2d0596..0000000 --- a/experiments/azure/azure-instance-stop/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: azure-instance-stop-sa - experiments: - - name: azure-instance-stop - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos intreval (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - # provide the target instance name(s) (comma separated if multiple) - - name: AZURE_INSTANCE_NAME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - diff --git a/experiments/azure/azure-instance-stop/experiment.yaml b/experiments/azure/azure-instance-stop/experiment.yaml deleted file mode 100644 index c685d9d..0000000 --- a/experiments/azure/azure-instance-stop/experiment.yaml +++ /dev/null @@ -1,96 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Terminating azure VM instance -kind: ChaosExperiment -metadata: - name: azure-instance-stop - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the target instance name(s) (comma separated if multiple) - - name: AZURE_INSTANCE_NAME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # Provide the path of aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - - name: SEQUENCE - value: 'parallel' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - diff --git a/experiments/azure/azure-instance-stop/rbac.yaml b/experiments/azure/azure-instance-stop/rbac.yaml deleted file mode 100644 index 323e2f3..0000000 --- a/experiments/azure/azure-instance-stop/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: azure-instance-stop-sa - namespace: default - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: azure-instance-stop-sa - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: azure-instance-stop-sa - labels: - name: azure-instance-stop-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: azure-instance-stop-sa -subjects: -- kind: ServiceAccount - name: azure-instance-stop-sa - namespace: default diff --git a/experiments/azure/azure.chartserviceversion.yaml b/experiments/azure/azure.chartserviceversion.yaml deleted file mode 100644 index 862959a..0000000 --- a/experiments/azure/azure.chartserviceversion.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-02-20T10:28:08Z - name: azure - version: 0.1.0 - annotations: - categories: Kubernetes - chartDescription: Injects chaos on azure servies -spec: - displayName: Azure - categoryDescription: > - Azure category of chaos experiments causes the disruption of the azure serives for a certain chaos duration. - experiments: - - name: azure-instance-stop - description: "" - - name: azure-disk-loss - description: "" - keywords: - - Azure - - Instance - - AKS - - Scaleset - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - provider: - name: Chaos Native - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/azure/experiments/azure - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#cloud-infrastructure - icon: - - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/azure/experiments.yaml diff --git a/experiments/azure/azure.package.yaml b/experiments/azure/azure.package.yaml deleted file mode 100644 index 904710a..0000000 --- a/experiments/azure/azure.package.yaml +++ /dev/null @@ -1,10 +0,0 @@ -packageName: azure -experiments: - - name: azure-instance-stop - CSV: azure-instance-stop.chartserviceversion.yaml - desc: "azure-instance-stop" - - - name: azure-disk-loss - CSV: azure-disk-loss.chartserviceversion.yaml - desc: "azure-disk-loss" - diff --git a/experiments/azure/experiments.yaml b/experiments/azure/experiments.yaml deleted file mode 100644 index 06d46d2..0000000 --- a/experiments/azure/experiments.yaml +++ /dev/null @@ -1,195 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Terminating azure VM instance -kind: ChaosExperiment -metadata: - name: azure-instance-stop - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the target instance name(s) (comma separated if multiple) - - name: AZURE_INSTANCE_NAME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # Provide the path of aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - - name: SEQUENCE - value: 'parallel' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: azure-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaches disk from the VM and then re-attaches disk to the VM -kind: ChaosExperiment -metadata: - name: azure-disk-loss - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name azure-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the resource group of the instance - - name: RESOURCE_GROUP - value: '' - - # accepts enable/disable, default is disable - - name: SCALE_SET - value: '' - - # provide the virtual disk names (comma separated if multiple) - - name: VIRTUAL_DISK_NAMES - value: '' - - # provide the sequence type for the run. Options: serial/parallel - - name: SEQUENCE - value: 'parallel' - - # provide the path to aks credentials mounted from secret - - name: AZURE_AUTH_LOCATION - value: '/tmp/azure.auth' - - labels: - name: azure-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/experiments/azure/icons/azure-disk-loss.png b/experiments/azure/icons/azure-disk-loss.png deleted file mode 100644 index 5baec5e..0000000 Binary files a/experiments/azure/icons/azure-disk-loss.png and /dev/null differ diff --git a/experiments/azure/icons/azure-instance-stop.png b/experiments/azure/icons/azure-instance-stop.png deleted file mode 100644 index 5baec5e..0000000 Binary files a/experiments/azure/icons/azure-instance-stop.png and /dev/null differ diff --git a/experiments/azure/icons/azure.png b/experiments/azure/icons/azure.png deleted file mode 100644 index 5baec5e..0000000 Binary files a/experiments/azure/icons/azure.png and /dev/null differ diff --git a/experiments/bank-of-anthos/bank-of-anthos.chartserviceversion.yaml b/experiments/bank-of-anthos/bank-of-anthos.chartserviceversion.yaml new file mode 100644 index 0000000..9203890 --- /dev/null +++ b/experiments/bank-of-anthos/bank-of-anthos.chartserviceversion.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: bank-of-anthos + version: 0.1.0 + annotations: + categories: bank-of-anthos + chartDescription: Injects pod network loss chaos in the bank of anthos application +spec: + displayName: Bank of Anthos + categoryDescription: > + Injects pod network loss chaos in the bank of anthos application + faults: + - name: pod-network-loss + description: Injects network packet loss on pods belonging to an app deployment + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + icon: + - url: + mediatype: "" diff --git a/workflows/bank-of-anthos/workflow.yaml b/experiments/bank-of-anthos/experiment.yaml similarity index 93% rename from workflows/bank-of-anthos/workflow.yaml rename to experiments/bank-of-anthos/experiment.yaml index f4f105f..7d086dc 100644 --- a/workflows/bank-of-anthos/workflow.yaml +++ b/experiments/bank-of-anthos/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-bank-of-anthos-resiliency- + name: argowf-chaos-bank-of-anthos-resiliency- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_bank-of-anthos" @@ -22,12 +22,12 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - - name: pod-network-loss template: pod-network-loss - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - name: delete-application template: delete-application @@ -36,7 +36,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=bank","-typeName=resilient","-operation=apply","-timeout=400", "-app=bank-of-anthos","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -108,7 +108,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=bank","-typeName=resilient","-operation=delete", "-app=bank-of-anthos"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/bank-of-anthos/workflow_cron.yaml b/experiments/bank-of-anthos/experiment_cron.yaml similarity index 93% rename from workflows/bank-of-anthos/workflow_cron.yaml rename to experiments/bank-of-anthos/experiment_cron.yaml index e9adbcb..3222b99 100644 --- a/workflows/bank-of-anthos/workflow_cron.yaml +++ b/experiments/bank-of-anthos/experiment_cron.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: CronWorkflow metadata: - generateName: argowf-chaos-bank-of-anthos-resiliency-cron-wf- + name: argowf-chaos-bank-of-anthos-resiliency-cron-wf- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_bank-of-anthos" @@ -26,12 +26,12 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - - name: pod-network-loss template: pod-network-loss - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - name: delete-application template: delete-application @@ -40,7 +40,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=bank","-typeName=resilient","-operation=apply","-timeout=400", "-app=bank-of-anthos","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -112,7 +112,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=bank","-typeName=resilient","-operation=delete", "-app=bank-of-anthos"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/coredns/coredns-pod-delete/coredns-pod-delete.chartserviceversion.yaml b/experiments/coredns/coredns-pod-delete/coredns-pod-delete.chartserviceversion.yaml deleted file mode 100644 index d0288b4..0000000 --- a/experiments/coredns/coredns-pod-delete/coredns-pod-delete.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-12-30T10:28:08Z - name: coredns-pod-delete - version: 0.1.7 - annotations: - categories: CoreDNS - vendor: CNCF - support: https://slack.cncf.io/ -spec: - displayName: coredns-pod-delete - categoryDescription: | - Pod delete contains chaos to disrupt state of coredns resources. Experiments can inject random pod delete failures against specified application. - - Causes (forced/graceful) pod failure of coredns replicas of an application deployment. - - Tests of successful resolution of app services during chaos injection - keywords: - - Kubernetes - - K8S - - CoreDNS - - DNS - - Pod - platforms: - - GKE - - Minikube - maturity: alpha - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/coredns/pod_delete - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/coredns-pod-delete/ - - name: Video - url: https://www.youtube.com/watch?v=pwo5idKW7q8 - chaosexpcrdlink: https://raw.githubusercontent.com/litmuchaos/chaos-charts/master/charts/coredns/coredns-pod-delete/experiment.yaml \ No newline at end of file diff --git a/experiments/coredns/coredns-pod-delete/engine.yaml b/experiments/coredns/coredns-pod-delete/engine.yaml deleted file mode 100644 index 329bdef..0000000 --- a/experiments/coredns/coredns-pod-delete/engine.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: engine-coredns - namespace: kube-system -spec: - appinfo: - appns: 'kube-system' - applabel: 'k8s-app=kube-dns' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: coredns-pod-delete-sa - experiments: - - name: coredns-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' - - - name: CHAOS_NAMESPACE - value: 'kube-system' \ No newline at end of file diff --git a/experiments/coredns/coredns-pod-delete/experiment.yaml b/experiments/coredns/coredns-pod-delete/experiment.yaml deleted file mode 100644 index 44edb19..0000000 --- a/experiments/coredns/coredns-pod-delete/experiment.yaml +++ /dev/null @@ -1,72 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes coredns pod in kube-system namespace -kind: ChaosExperiment -metadata: - name: coredns-pod-delete - labels: - name: coredns-pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - permissions: - - apiGroups: - - "" - - "batch" - - "litmuschaos.io" - resources: - - "services" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "get" - - "list" - - "patch" - - "create" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/coredns/pod_delete/pod_delete_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - #supported libs are litmus and powerfulseal - - name: LIB - value: 'litmus' - - - name: LIB_IMAGE - value: 'litmuschaos/pod-delete-helper:latest' - - labels: - name: coredns-pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/coredns/coredns-pod-delete/rbac.yaml b/experiments/coredns/coredns-pod-delete/rbac.yaml deleted file mode 100644 index 00fe7db..0000000 --- a/experiments/coredns/coredns-pod-delete/rbac.yaml +++ /dev/null @@ -1,36 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: coredns-pod-delete-sa - namespace: kube-system - labels: - name: coredns-pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: coredns-pod-delete-sa - labels: - name: coredns-pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","litmuschaos.io","batch"] - resources: ["services", "pods","jobs","events","pods/log","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: coredns-pod-delete-sa - labels: - name: coredns-pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: coredns-pod-delete-sa -subjects: -- kind: ServiceAccount - name: coredns-pod-delete-sa - namespace: kube-system diff --git a/experiments/coredns/coredns.chartserviceversion.yaml b/experiments/coredns/coredns.chartserviceversion.yaml deleted file mode 100644 index dbe4fc8..0000000 --- a/experiments/coredns/coredns.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-12-30T10:28:08Z - name: coredns - version: 0.1.4 - annotations: - categories: Kubernetes - chartDescription: Injects coredns chaos -spec: - displayName: CoreDNS chaos - categoryDescription: > - CoreDNS is an open-source system for DNS management of containerized applications. - It helps to resolve services to IP address. It will install all the experiments which can be used to inject chaos into containerized applications. - experiments: - - name: coredns-pod-delete - description: "" - keywords: - - Kubernetes - - K8S - - Pod - - CoreDNS - - DNS - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: CoreDNS Website - url: https://coredns.io - - name: Source Code - url: https://github.com/coredns/coredns - - name: CoreDNS Slack - url: https://slack.cncf.io/ - - name: Documentation - url: https://coredns.io/manual/toc/ - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/coredns/icons/coredns-pod-delete.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/coredns/experiments.yaml diff --git a/experiments/coredns/coredns.package.yaml b/experiments/coredns/coredns.package.yaml deleted file mode 100644 index 9fa1e66..0000000 --- a/experiments/coredns/coredns.package.yaml +++ /dev/null @@ -1,5 +0,0 @@ -packageName: coredns -experiments: - - name: coredns-pod-delete - CSV: coredns-pod-delete.chartserviceversion.yaml - desc: "coredns pod delete experiment" \ No newline at end of file diff --git a/experiments/coredns/experiments.yaml b/experiments/coredns/experiments.yaml deleted file mode 100644 index 46c81be..0000000 --- a/experiments/coredns/experiments.yaml +++ /dev/null @@ -1,74 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes coredns pod in kube-system namespace -kind: ChaosExperiment -metadata: - name: coredns-pod-delete - labels: - name: coredns-pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - permissions: - - apiGroups: - - "" - - "batch" - - "litmuschaos.io" - resources: - - "services" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "get" - - "list" - - "patch" - - "create" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/coredns/pod_delete/pod_delete_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - #supported libs are litmus and powerfulseal - - name: LIB - value: 'litmus' - - - name: LIB_IMAGE - value: 'litmuschaos/pod-delete-helper:latest' - - labels: - name: coredns-pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- diff --git a/experiments/coredns/icons/coredns-pod-delete.png b/experiments/coredns/icons/coredns-pod-delete.png deleted file mode 100644 index c643b7b..0000000 Binary files a/experiments/coredns/icons/coredns-pod-delete.png and /dev/null differ diff --git a/experiments/coredns/icons/coredns.png b/experiments/coredns/icons/coredns.png deleted file mode 100644 index c643b7b..0000000 Binary files a/experiments/coredns/icons/coredns.png and /dev/null differ diff --git a/experiments/gcp/experiments.yaml b/experiments/gcp/experiments.yaml deleted file mode 100644 index c262a5d..0000000 --- a/experiments/gcp/experiments.yaml +++ /dev/null @@ -1,374 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss-by-label - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss-by-label - command: - - /bin/bash - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the zone in which all the disks are created - # all the disks must exist in the same zone - - name: DISK_ZONES - value: '' - - # set the label of the target disk volumes - - name: DISK_VOLUME_LABEL - value: '' - - # set the percentage value of the disks with the given label - # which should be targeted as part of the chaos injection - - name: DISK_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop-by-label - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop-by-label - command: - - /bin/bash - 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: '30' - - - name: SEQUENCE - value: 'parallel' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Label of the target vm instance(s) - - name: INSTANCE_LABEL - value: '' - - # Zone in which the target vm instance(s) filtered by the label exist - # all the instances should lie in a single zone - - name: INSTANCE_ZONES - value: '' - - # enable it if the target instance is a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # set the percentage value of the instances with the given label - # which should be targeted as part of the chaos injection - - name: INSTANCE_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # parallel or serial; determines how the VM instances are terminated, all at once or one at a time - - name: SEQUENCE - value: 'parallel' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - # period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable or disable; shall be set to enable if the target instances are a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # Instance name of the target vm instance(s) - # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - - name: VM_INSTANCE_NAMES - value: '' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their - # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - - name: INSTANCE_ZONES - value: '' - - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the disk volume name(s) as comma seperated values - # eg. volume1,volume2,... - - name: DISK_VOLUME_NAMES - value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME - # eg. zone1,zone2,... - - name: DISK_ZONES - value: '' - - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/experiments/gcp/gcp-vm-disk-loss-by-label/engine.yaml b/experiments/gcp/gcp-vm-disk-loss-by-label/engine.yaml deleted file mode 100644 index 827a47e..0000000 --- a/experiments/gcp/gcp-vm-disk-loss-by-label/engine.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: gcp-disk-chaos -spec: - engineState: 'active' - chaosServiceAccount: gcp-vm-disk-loss-by-label-sa - experiments: - - name: gcp-vm-disk-loss-by-label - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the zone in which all the disks are created - # all the disks must exist in the same zone - - name: DISK_ZONES - value: '' - - # set the label of the target disk volumes - - name: DISK_VOLUME_LABEL - value: '' - - # set the percentage value of the disks with the given label - # which should be targeted as part of the chaos injection - - name: DISK_AFFECTED_PERC - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' diff --git a/experiments/gcp/gcp-vm-disk-loss-by-label/experiment.yaml b/experiments/gcp/gcp-vm-disk-loss-by-label/experiment.yaml deleted file mode 100644 index 773443c..0000000 --- a/experiments/gcp/gcp-vm-disk-loss-by-label/experiment.yaml +++ /dev/null @@ -1,83 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss-by-label - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss-by-label - command: - - /bin/bash - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the zone in which all the disks are created - # all the disks must exist in the same zone - - name: DISK_ZONES - value: '' - - # set the label of the target disk volumes - - name: DISK_VOLUME_LABEL - value: '' - - # set the percentage value of the disks with the given label - # which should be targeted as part of the chaos injection - - name: DISK_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-disk-loss-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml b/experiments/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml deleted file mode 100644 index 2aa5bee..0000000 --- a/experiments/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-disk-loss-by-label - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-disk-loss-by-label - categoryDescription: > - Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back - keywords: - - "Disk" - - "GCP" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-disk-loss-by-label/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-disk-loss-by-label/experiment.yaml diff --git a/experiments/gcp/gcp-vm-disk-loss-by-label/rbac.yaml b/experiments/gcp/gcp-vm-disk-loss-by-label/rbac.yaml deleted file mode 100644 index 3406523..0000000 --- a/experiments/gcp/gcp-vm-disk-loss-by-label/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-disk-loss-by-label-sa - namespace: default - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-disk-loss-by-label-sa - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-disk-loss-by-label-sa - labels: - name: gcp-vm-disk-loss-by-label-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-disk-loss-by-label-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-disk-loss-by-label-sa - namespace: default \ No newline at end of file diff --git a/experiments/gcp/gcp-vm-disk-loss/engine.yaml b/experiments/gcp/gcp-vm-disk-loss/engine.yaml deleted file mode 100644 index 71a4b35..0000000 --- a/experiments/gcp/gcp-vm-disk-loss/engine.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: gcp-disk-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - chaosServiceAccount: gcp-vm-disk-loss-sa - experiments: - - name: gcp-vm-disk-loss - 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: '30' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the disk volume name(s) as comma seperated values - # eg. volume1,volume2,... - - name: DISK_VOLUME_NAMES - value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME - # eg. zone1,zone2,... - - name: DISK_ZONES - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' diff --git a/experiments/gcp/gcp-vm-disk-loss/experiment.yaml b/experiments/gcp/gcp-vm-disk-loss/experiment.yaml deleted file mode 100644 index dc9fa37..0000000 --- a/experiments/gcp/gcp-vm-disk-loss/experiment.yaml +++ /dev/null @@ -1,89 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back -kind: ChaosExperiment -metadata: - name: gcp-vm-disk-loss - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-disk-loss - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' - - # set the GCP project id - - name: GCP_PROJECT_ID - value: '' - - # set the disk volume name(s) as comma seperated values - # eg. volume1,volume2,... - - name: DISK_VOLUME_NAMES - value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME - # eg. zone1,zone2,... - - name: DISK_ZONES - value: '' - - labels: - name: gcp-vm-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml b/experiments/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml deleted file mode 100644 index 452dffe..0000000 --- a/experiments/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-disk-loss - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-disk-loss - categoryDescription: > - Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back - keywords: - - "Disk" - - "GCP" - platforms: - - "GCP" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-disk-loss/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-disk-loss/experiment.yaml diff --git a/experiments/gcp/gcp-vm-disk-loss/rbac.yaml b/experiments/gcp/gcp-vm-disk-loss/rbac.yaml deleted file mode 100644 index 27c2072..0000000 --- a/experiments/gcp/gcp-vm-disk-loss/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-disk-loss-sa - namespace: default - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-disk-loss-sa - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-disk-loss-sa - labels: - name: gcp-vm-disk-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-disk-loss-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-disk-loss-sa - namespace: default \ No newline at end of file diff --git a/experiments/gcp/gcp-vm-instance-stop-by-label/engine.yaml b/experiments/gcp/gcp-vm-instance-stop-by-label/engine.yaml deleted file mode 100644 index 34bf1be..0000000 --- a/experiments/gcp/gcp-vm-instance-stop-by-label/engine.yaml +++ /dev/null @@ -1,46 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: gcp-vm-chaos -spec: - # It can be active/stop - engineState: 'active' - chaosServiceAccount: gcp-vm-instance-stop-by-label-sa - # It can be delete/retain - experiments: - - name: gcp-vm-instance-stop-by-label - 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: '30' - - - name: SEQUENCE - value: 'parallel' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Label of the target vm instance(s) - - name: INSTANCE_LABEL - value: '' - - # Zone in which the target vm instance(s) filtered by the label exist - # all the instances should lie in a single zone - - name: INSTANCE_ZONES - value: '' - - # enable it if the target instances are a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # set the percentage value of the instances with the given label - # which should be targeted as part of the chaos injection - - name: INSTANCE_AFFECTED_PERC - value: '' \ No newline at end of file diff --git a/experiments/gcp/gcp-vm-instance-stop-by-label/experiment.yaml b/experiments/gcp/gcp-vm-instance-stop-by-label/experiment.yaml deleted file mode 100644 index 4091b8f..0000000 --- a/experiments/gcp/gcp-vm-instance-stop-by-label/experiment.yaml +++ /dev/null @@ -1,95 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop-by-label - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop-by-label - command: - - /bin/bash - 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: '30' - - - name: SEQUENCE - value: 'parallel' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Label of the target vm instance(s) - - name: INSTANCE_LABEL - value: '' - - # Zone in which the target vm instance(s) filtered by the label exist - # all the instances should lie in a single zone - - name: INSTANCE_ZONES - value: '' - - # enable it if the target instance is a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # set the percentage value of the instances with the given label - # which should be targeted as part of the chaos injection - - name: INSTANCE_AFFECTED_PERC - value: '' - - labels: - name: gcp-vm-instance-stop-by-label - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml b/experiments/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml deleted file mode 100644 index f14399d..0000000 --- a/experiments/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-instance-stop-by-label - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-instance-stop-by-label - categoryDescription: > - Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them - keywords: - - "VM" - - "GCP" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-instance-stop-by-label/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-instance-stop-by-label/experiment.yaml diff --git a/experiments/gcp/gcp-vm-instance-stop-by-label/rbac.yaml b/experiments/gcp/gcp-vm-instance-stop-by-label/rbac.yaml deleted file mode 100644 index f37f8f7..0000000 --- a/experiments/gcp/gcp-vm-instance-stop-by-label/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-instance-stop-by-label-sa - namespace: default - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-instance-stop-by-label-sa - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-instance-stop-by-label-sa - labels: - name: gcp-vm-instance-stop-by-label-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-instance-stop-by-label-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-instance-stop-by-label-sa - namespace: default \ No newline at end of file diff --git a/experiments/gcp/gcp-vm-instance-stop/engine.yaml b/experiments/gcp/gcp-vm-instance-stop/engine.yaml deleted file mode 100644 index 3966faa..0000000 --- a/experiments/gcp/gcp-vm-instance-stop/engine.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: gcp-vm-chaos -spec: - engineState: 'active' - chaosServiceAccount: gcp-vm-instance-stop-sa - experiments: - - name: gcp-vm-instance-stop - 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: '30' - - # Instance name of the target vm instance(s) - # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - - name: VM_INSTANCE_NAMES - value: '' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their - # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - - name: INSTANCE_ZONES - value: '' - - # enable it if the target instance is a part of a managed instance group. - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # parallel or serial; determines how chaos is injected - - name: SEQUENCE - value: 'parallel' diff --git a/experiments/gcp/gcp-vm-instance-stop/experiment.yaml b/experiments/gcp/gcp-vm-instance-stop/experiment.yaml deleted file mode 100644 index f1a60ab..0000000 --- a/experiments/gcp/gcp-vm-instance-stop/experiment.yaml +++ /dev/null @@ -1,99 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them -kind: ChaosExperiment -metadata: - name: gcp-vm-instance-stop - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name gcp-vm-instance-stop - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # parallel or serial; determines how the VM instances are terminated, all at once or one at a time - - name: SEQUENCE - value: 'parallel' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - # period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable or disable; shall be set to enable if the target instances are a part of a managed instance group - - name: MANAGED_INSTANCE_GROUP - value: 'disable' - - # Instance name of the target vm instance(s) - # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - - name: VM_INSTANCE_NAMES - value: '' - - # GCP project ID to which the vm instances belong - - name: GCP_PROJECT_ID - value: '' - - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their - # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - - name: INSTANCE_ZONES - value: '' - - labels: - name: gcp-vm-instance-stop - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml b/experiments/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml deleted file mode 100644 index 6b8aab2..0000000 --- a/experiments/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp-vm-instance-stop - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp-vm-instance-stop - categoryDescription: > - Stops GCP VM instances and GKE nodes for a specified duration and later restarts them - keywords: - - "VM" - - "GCP" - platforms: - - "GCP" - maturity: alpha - maintainers: - - name: Neelanjan Manna - email: neelanjan@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/gcp/gcp-vm-instance-stop/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/gcp-vm-instance-stop/experiment.yaml diff --git a/experiments/gcp/gcp-vm-instance-stop/rbac.yaml b/experiments/gcp/gcp-vm-instance-stop/rbac.yaml deleted file mode 100644 index 0592ea9..0000000 --- a/experiments/gcp/gcp-vm-instance-stop/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: gcp-vm-instance-stop-sa - namespace: default - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: gcp-vm-instance-stop-sa - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: gcp-vm-instance-stop-sa - labels: - name: gcp-vm-instance-stop-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: gcp-vm-instance-stop-sa -subjects: -- kind: ServiceAccount - name: gcp-vm-instance-stop-sa - namespace: default \ No newline at end of file diff --git a/experiments/gcp/gcp.chartserviceversion.yaml b/experiments/gcp/gcp.chartserviceversion.yaml deleted file mode 100644 index ed3d603..0000000 --- a/experiments/gcp/gcp.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: gcp - version: 0.1.0 - annotations: - categories: gcp -spec: - displayName: gcp chaos - categoryDescription: > - GCP contains chaos to disrupt state of gcp resources running part of the gcp services - experiments: - - name: gcp-vm-instance-stop - description: "" - - name: gcp-vm-disk-loss - description: "" - - name: gcp-vm-instance-stop-by-label - description: "" - - name: gcp-vm-disk-loss-by-label - description: "" - keywords: - - "VM" - - "Disk" - - "GCP" - - "Infra" - maintainers: - - name: Neelanjan Manna - email: neelanjan.manna@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - links: - - name: GCP Website - url: https://cloud.google.com/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#cloud-infrastructure - - name: Community Slack - url: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/gcp/experiments.yaml diff --git a/experiments/gcp/gcp.package.yaml b/experiments/gcp/gcp.package.yaml deleted file mode 100644 index 28c1b33..0000000 --- a/experiments/gcp/gcp.package.yaml +++ /dev/null @@ -1,14 +0,0 @@ -packageName: gcp -experiments: - - name: gcp-vm-instance-stop - CSV: gcp-vm-instance-stop.chartserviceversion.yaml - desc: "gcp-vm-instance-stop" - - name: gcp-vm-disk-loss - CSV: gcp-vm-disk-loss.chartserviceversion.yaml - desc: "gcp-vm-disk-loss" - - name: gcp-vm-instance-stop-by-label - CSV: gcp-vm-instance-stop-by-label.chartserviceversion.yaml - desc: "gcp-vm-instance-stop-by-label" - - name: gcp-vm-disk-loss-by-label - CSV: gcp-vm-disk-loss-by-label.chartserviceversion.yaml - desc: "gcp-vm-disk-loss-by-label" diff --git a/experiments/gcp/icons/gcp-vm-disk-loss-by-label.png b/experiments/gcp/icons/gcp-vm-disk-loss-by-label.png deleted file mode 100644 index 1b1b94c..0000000 Binary files a/experiments/gcp/icons/gcp-vm-disk-loss-by-label.png and /dev/null differ diff --git a/experiments/gcp/icons/gcp-vm-disk-loss.png b/experiments/gcp/icons/gcp-vm-disk-loss.png deleted file mode 100644 index 1b1b94c..0000000 Binary files a/experiments/gcp/icons/gcp-vm-disk-loss.png and /dev/null differ diff --git a/experiments/gcp/icons/gcp-vm-instance-stop-by-label.png b/experiments/gcp/icons/gcp-vm-instance-stop-by-label.png deleted file mode 100644 index 9f1b90f..0000000 Binary files a/experiments/gcp/icons/gcp-vm-instance-stop-by-label.png and /dev/null differ diff --git a/experiments/gcp/icons/gcp-vm-instance-stop.png b/experiments/gcp/icons/gcp-vm-instance-stop.png deleted file mode 100644 index 9f1b90f..0000000 Binary files a/experiments/gcp/icons/gcp-vm-instance-stop.png and /dev/null differ diff --git a/experiments/gcp/icons/gcp.png b/experiments/gcp/icons/gcp.png deleted file mode 100644 index 577f8ba..0000000 Binary files a/experiments/gcp/icons/gcp.png and /dev/null differ diff --git a/experiments/generic/container-kill/container-kill.chartserviceversion.yaml b/experiments/generic/container-kill/container-kill.chartserviceversion.yaml deleted file mode 100644 index 14db31c..0000000 --- a/experiments/generic/container-kill/container-kill.chartserviceversion.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-15T10:28:08Z - name: container-kill - version: 0.1.13 - annotations: - categories: "Kubernetes" - vendor: "CNCF" - support: https://slack.openebs.io/ -spec: - displayName: container-kill - categoryDescription: | - Container kill contains chaos to disrupt state of kubernetes resources. Experiments can inject random container delete failures against specified application. - - Executes SIGKILL on containers of random replicas of an application deployment. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. - keywords: - - Kubernetes - - K8S - - Pod - - Container - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/container-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/container-kill/ - - name: Video - url: https://www.youtube.com/watch?v=XKyMNdVsKMo - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/container-kill/experiment.yaml diff --git a/experiments/generic/container-kill/engine_nginx_getstarted.yaml b/experiments/generic/container-kill/engine_nginx_getstarted.yaml deleted file mode 100644 index df1430a..0000000 --- a/experiments/generic/container-kill/engine_nginx_getstarted.yaml +++ /dev/null @@ -1,46 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: nginx -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'nginx' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: container-kill-sa - # It can be delete/retain - jobCleanUpPolicy: 'delete' - experiments: - - name: container-kill - spec: - components: - env: - # 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 - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_CONTAINER - value: '' - \ No newline at end of file diff --git a/experiments/generic/container-kill/experiment.yaml b/experiments/generic/container-kill/experiment.yaml deleted file mode 100644 index bf60b7d..0000000 --- a/experiments/generic/container-kill/experiment.yaml +++ /dev/null @@ -1,125 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: "Kills a container belonging to an application pod \n" -kind: ChaosExperiment -metadata: - name: container-kill - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name 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: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - - name: SIGNAL - value: 'SIGKILL' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/container-kill/rbac-psp.yaml b/experiments/generic/container-kill/rbac-psp.yaml deleted file mode 100644 index 12de772..0000000 --- a/experiments/generic/container-kill/rbac-psp.yaml +++ /dev/null @@ -1,86 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: default - diff --git a/experiments/generic/container-kill/rbac.yaml b/experiments/generic/container-kill/rbac.yaml deleted file mode 100644 index ccea310..0000000 --- a/experiments/generic/container-kill/rbac.yaml +++ /dev/null @@ -1,81 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: default - labels: - name: container-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: default - diff --git a/experiments/generic/container-kill/rbac_nginx_getstarted.yaml b/experiments/generic/container-kill/rbac_nginx_getstarted.yaml deleted file mode 100644 index 461b164..0000000 --- a/experiments/generic/container-kill/rbac_nginx_getstarted.yaml +++ /dev/null @@ -1,78 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: container-kill-sa - namespace: nginx - labels: - name: container-kill-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: container-kill-sa -subjects: -- kind: ServiceAccount - name: container-kill-sa - namespace: nginx - diff --git a/experiments/generic/disk-fill/disk-fill.chartserviceversion.yaml b/experiments/generic/disk-fill/disk-fill.chartserviceversion.yaml deleted file mode 100644 index e5b202c..0000000 --- a/experiments/generic/disk-fill/disk-fill.chartserviceversion.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-11-11T10:28:08Z - name: disk-fill - version: 0.0.12 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: disk-fill - categoryDescription: | - Disk fill contains chaos to disrupt state of kubernetes resources. - - Causes (forced/graceful) Disk Stress by filling up the Ephemeral Storage of the Pod using one of it containers. - - Causes Pod to get Evicted if the Pod exceeds it Ephemeral Storage Limit. - - Tests the Ephemeral Storage Limits, to ensure those parameters are sufficient. - keywords: - - Kubernetes - - K8S - - Pod - - Disk - platforms: - - GKE - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/disk-fill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/disk-fill/ - - name: Video - url: https://www.youtube.com/watch?v=pbok737rUPQ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/disk-fill/experiment.yaml diff --git a/experiments/generic/disk-fill/experiment.yaml b/experiments/generic/disk-fill/experiment.yaml deleted file mode 100644 index 74f62b9..0000000 --- a/experiments/generic/disk-fill/experiment.yaml +++ /dev/null @@ -1,128 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Fillup Ephemeral Storage of a Resource -kind: ChaosExperiment -metadata: - name: disk-fill - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name disk-fill - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: FILL_PERCENTAGE - value: '80' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide the data block size - # supported unit is KB - - name: DATA_BLOCK_SIZE - value: '256' - - - name: TARGET_PODS - value: '' - - - name: EPHEMERAL_STORAGE_MEBIBYTES - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/host-path-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/disk-fill/rbac-psp.yaml b/experiments/generic/disk-fill/rbac-psp.yaml deleted file mode 100644 index e7aa880..0000000 --- a/experiments/generic/disk-fill/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: disk-fill-sa -subjects: -- kind: ServiceAccount - name: disk-fill-sa - namespace: default diff --git a/experiments/generic/disk-fill/rbac.yaml b/experiments/generic/disk-fill/rbac.yaml deleted file mode 100644 index 37a9d9a..0000000 --- a/experiments/generic/disk-fill/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: disk-fill-sa - namespace: default - labels: - name: disk-fill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: disk-fill-sa -subjects: -- kind: ServiceAccount - name: disk-fill-sa - namespace: default diff --git a/experiments/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml b/experiments/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml deleted file mode 100644 index 0f629dd..0000000 --- a/experiments/generic/docker-service-kill/docker-service-kill.chartserviceversion.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-07-14T10:28:08Z - name: docker-service-kill - version: 0.1.1 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: docker-service-kill - categoryDescription: | - docker-service-kill contains killing docker service gracefully for a certain chaos duration. - - Causes replicas may be evicted or becomes unreachable on account on nodes turning unschedulable (Not Ready) due to docker service kill. - - The application node should be healthy once chaos is stopped and the services are reaccessable. - keywords: - - Kubernetes - - K8S - - Node - - Service - - Docker - platforms: - - GKE - - AKS - maturity: alpha - maintainers: - - name: Ankur Ghosh - email: ankur.ghosh3@wipro.com - minKubeVersion: 1.12.0 - provider: - name: Wipro - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/docker-service-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/docker-service-kill/ - - name: Video - url: - - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/docker-service-kill/experiment.yaml diff --git a/experiments/generic/docker-service-kill/engine.yaml b/experiments/generic/docker-service-kill/engine.yaml deleted file mode 100644 index cfc1d1a..0000000 --- a/experiments/generic/docker-service-kill/engine.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - auxiliaryAppInfo: '' - chaosServiceAccount: docker-service-kill-sa - experiments: - - name: docker-service-kill - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '90' # in seconds - - - name: TARGET_NODE - value: '' \ No newline at end of file diff --git a/experiments/generic/docker-service-kill/experiment.yaml b/experiments/generic/docker-service-kill/experiment.yaml deleted file mode 100644 index 056f9a6..0000000 --- a/experiments/generic/docker-service-kill/experiment.yaml +++ /dev/null @@ -1,85 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the docker service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: docker-service-kill - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name docker-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '90' # in seconds - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: LIB - value: 'litmus' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - diff --git a/experiments/generic/docker-service-kill/rbac-psp.yaml b/experiments/generic/docker-service-kill/rbac-psp.yaml deleted file mode 100644 index cc1c8a9..0000000 --- a/experiments/generic/docker-service-kill/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: docker-service-kill-sa - namespace: default - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: docker-service-kill-sa -subjects: -- kind: ServiceAccount - name: docker-service-kill-sa - namespace: default diff --git a/experiments/generic/docker-service-kill/rbac.yaml b/experiments/generic/docker-service-kill/rbac.yaml deleted file mode 100644 index 1972a97..0000000 --- a/experiments/generic/docker-service-kill/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: docker-service-kill-sa - namespace: default - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: docker-service-kill-sa - labels: - name: docker-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: docker-service-kill-sa -subjects: -- kind: ServiceAccount - name: docker-service-kill-sa - namespace: default diff --git a/experiments/generic/experiments.yaml b/experiments/generic/experiments.yaml deleted file mode 100644 index c232721..0000000 --- a/experiments/generic/experiments.yaml +++ /dev/null @@ -1,3040 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-loss - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-loss - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # it can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - IO stress on a app pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-io-stress - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-io-stress - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # provide volume mount path - - name: VOLUME_MOUNT_PATH - value: '' - - ## specify the comma separated target pods - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # support litmus and pumba - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Pod DNS Error injects dns failure/error in target pod containers -kind: ChaosExperiment -metadata: - name: pod-dns-error - labels: - name: pod-dns-error - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-dns-error - command: - - /bin/bash - env: - - name: TARGET_CONTAINER - value: "" - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: "" - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" - - - name: TARGET_PODS - value: "" - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: "parallel" - - # list of the target hostnames or kewywords eg. '["litmuschaos","chaosnative.io"]' . If empty all hostnames are targets - - name: TARGET_HOSTNAMES - value: "" - - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring - - name: MATCH_SCHEME - value: "exact" - - labels: - experiment: pod-dns-error - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a memory hog on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-memory-hog - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-memory-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## Specify the size as percent of total node capacity Ex: '30' - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - - name: MEMORY_CONSUMPTION_PERCENTAGE - value: '' - - ## Specify the amount of memory to be consumed in mebibytes - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - - name: MEMORY_CONSUMPTION_MEBIBYTES - value: '' - - - name: NUMBER_OF_WORKERS - value: '1' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: "Kills a container belonging to an application pod \n" -kind: ChaosExperiment -metadata: - name: container-kill - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name 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: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - - name: SIGNAL - value: 'SIGKILL' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: container-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Inject network packet corruption into application pod -kind: ChaosExperiment -metadata: - name: pod-network-corruption - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-corruption - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog-exec - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus - - name: LIB - value: 'litmus' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/md5sum' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}')" - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Fillup Ephemeral Storage of a Resource -kind: ChaosExperiment -metadata: - name: disk-fill - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name disk-fill - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: FILL_PERCENTAGE - value: '80' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide the data block size - # supported unit is KB - - name: DATA_BLOCK_SIZE - value: '256' - - - name: TARGET_PODS - value: '' - - - name: EPHEMERAL_STORAGE_MEBIBYTES - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # Provide the container runtime path - # Default set to docker container path - - name: CONTAINER_PATH - value: '/var/lib/docker/containers' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: disk-fill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/host-path-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the docker service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: docker-service-kill - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name docker-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '90' # in seconds - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: LIB - value: 'litmus' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: docker-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects http request latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-http-latency - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: LATENCY - value: '2000' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -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: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - 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 - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kills the kubelet service on the application node to check the resiliency. -kind: ChaosExperiment -metadata: - name: kubelet-service-kill - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name kubelet-service-kill - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: LIB - value: 'litmus' - - - name: NODE_LABEL - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' - - labels: - name: kubelet-service-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects memory consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-memory-hog-exec - labels: - name: pod-memory-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-memory-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus - - name: LIB - value: 'litmus' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/dd' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}' | head -n 1)" - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - - name: TARGET_PODS - value: '' - - labels: - name: pod-memory-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects 100% network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-partition - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-partition - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # it should be litmus - - name: LIB - value: 'litmus' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide network policy type - # support ingress, egress, all values - - name: POLICY_TYPES - value: 'all' - - # provide labels of the destination pods - - name: POD_SELECTOR - value: '' - - # provide labels the destination namespaces - - name: NAMESPACE_SELECTOR - value: '' - - # provide comma separated ports - - name: PORTS - value: '' - - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Scale the application replicas and test the node autoscaling on cluster -kind: ChaosExperiment -metadata: - name: pod-autoscaler - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-autoscaler - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Number of replicas to scale - - name: REPLICA_COUNT - value: '5' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - labels: - name: pod-autoscaler - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - poweroff node -kind: ChaosExperiment -metadata: - name: node-poweroff - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: REBOOT_COMMAND - value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Taint the node where application pod is scheduled -kind: ChaosExperiment -metadata: - name: node-taint - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-taint - 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: '' - - # set taint label & effect - # key=value:effect or key:effect - - name: TAINTS - value: '' - - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, pumba - - name: LIB - value: 'litmus' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet duplication on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-duplication - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-duplication - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: RAMP_TIME - value: '' - - - name: TARGET_CONTAINER - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE - value: '100' # in percentage - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a cpu spike on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-cpu-hog - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-cpu-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - - name: NODE_CPU_CORE - value: '' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-latency - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: NETWORK_INTERFACE - value: 'eth0' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_LATENCY - value: '2000' #in ms - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: JITTER - value: '0' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give IO disk stress on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-io-stress - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-io-stress - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Number of core of CPU - - name: CPU - value: '1' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Total number of vm workers - - name: VM_WORKERS - value: '1' - - ## enter the comma separated target nodes name - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames -kind: ChaosExperiment -metadata: - name: pod-dns-spoof - labels: - name: pod-dns-spoof - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-dns-spoof - command: - - /bin/bash - env: - - name: TARGET_CONTAINER - value: "" - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: "" - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" - - - name: TARGET_PODS - value: "" - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: "parallel" - - # map of the target hostnames eg. '{"abc.com":"spoofabc.com"}' . If empty no queries will be spoofed - - name: SPOOF_MAP - value: "" - - labels: - experiment: pod-dns-spoof - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-delete - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects memory consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-memory-hog - labels: - name: pod-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-memory-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## Number of workers to perform stress - - name: NUMBER_OF_WORKERS - value: '1' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, pumba - - name: LIB - value: 'litmus' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - labels: - name: pod-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Restart node -kind: ChaosExperiment -metadata: - name: node-restart - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ - ---- -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: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - 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 - ---- diff --git a/experiments/generic/generic.chartserviceversion.yaml b/experiments/generic/generic.chartserviceversion.yaml deleted file mode 100644 index a8b31b6..0000000 --- a/experiments/generic/generic.chartserviceversion.yaml +++ /dev/null @@ -1,109 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-09-26T10:28:08Z - name: generic - version: 0.1.16 - annotations: - categories: Kubernetes - chartDescription: Injects generic kubernetes chaos -spec: - displayName: Generic Chaos - categoryDescription: > - Kubernetes is an open-source system for automating deployment, scaling, and management of containerized applications. It groups containers that make up an application into logical units for easier management and discovery. It will install all the experiments which can be used to inject chaos into containerized applications. - - experiments: - - name: pod-delete - description: "deletes a k8s pod" - - name: container-kill - description: "deletes a container in a k8s pod" - - name: pod-cpu-hog - description: "" - - name: pod-network-loss - description: "" - - name: pod-network-latency - description: "" - - name: pod-network-corruption - description: "" - - name: node-drain - description: "" - - name: node-cpu-hog - description: "" - - name: disk-fill - description: "" - - name: node-memory-hog - description: "" - - name: pod-memory-hog - description: "" - - name: kubelet-service-kill - description: "" - - name: pod-network-duplication - description: "" - - name: node-taint - description: "" - - name: docker-service-kill - description: "" - - name: pod-autoscaler - description: "" - - name: node-io-stress - description: "" - - name: pod-io-stress - description: "" - - name: node-restart - description: "" - - name: pod-dns-error - description: "" - - name: pod-dns-spoof - description: "" - - name: pod-cpu-hog-exec - description: "" - - name: pod-memory-hog-exec - description: "" - - name: pod-network-partition - description: "" - - name: pod-http-latency - description: "" - - name: pod-http-modify-body - description: "" - - name: pod-http-reset-peer - description: "" - - name: pod-http-modify-header - description: "" - - name: pod-http-status-code - description: "" - keywords: - - Kubernetes - - K8S - - Container - - Node - - Pod - - Disk - - IO - - Filesystem - - Network - - CPU - - Memory - - Stress - - Service - - DNS - - Scale - - Http - maintainers: - - name: ksatchit - email: karthik.s@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: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#generic - icon: - - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/experiments.yaml diff --git a/experiments/generic/icons/byoc-pod-delete.png b/experiments/generic/icons/byoc-pod-delete.png deleted file mode 100644 index 16aa7b4..0000000 Binary files a/experiments/generic/icons/byoc-pod-delete.png and /dev/null differ diff --git a/experiments/generic/icons/container-kill.png b/experiments/generic/icons/container-kill.png deleted file mode 100644 index a7fb829..0000000 Binary files a/experiments/generic/icons/container-kill.png and /dev/null differ diff --git a/experiments/generic/icons/disk-fill.png b/experiments/generic/icons/disk-fill.png deleted file mode 100644 index a0418ee..0000000 Binary files a/experiments/generic/icons/disk-fill.png and /dev/null differ diff --git a/experiments/generic/icons/docker-service-kill.png b/experiments/generic/icons/docker-service-kill.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/docker-service-kill.png and /dev/null differ diff --git a/experiments/generic/icons/generic.png b/experiments/generic/icons/generic.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/generic.png and /dev/null differ diff --git a/experiments/generic/icons/kubelet-service-kill.png b/experiments/generic/icons/kubelet-service-kill.png deleted file mode 100644 index 6f9e54e..0000000 Binary files a/experiments/generic/icons/kubelet-service-kill.png and /dev/null differ diff --git a/experiments/generic/icons/node-cpu-hog.png b/experiments/generic/icons/node-cpu-hog.png deleted file mode 100644 index aa91993..0000000 Binary files a/experiments/generic/icons/node-cpu-hog.png and /dev/null differ diff --git a/experiments/generic/icons/node-drain.png b/experiments/generic/icons/node-drain.png deleted file mode 100644 index 35e8f31..0000000 Binary files a/experiments/generic/icons/node-drain.png and /dev/null differ diff --git a/experiments/generic/icons/node-io-stress.png b/experiments/generic/icons/node-io-stress.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/node-io-stress.png and /dev/null differ diff --git a/experiments/generic/icons/node-memory-hog.png b/experiments/generic/icons/node-memory-hog.png deleted file mode 100644 index b50396f..0000000 Binary files a/experiments/generic/icons/node-memory-hog.png and /dev/null differ diff --git a/experiments/generic/icons/node-taint.png b/experiments/generic/icons/node-taint.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/node-taint.png and /dev/null differ diff --git a/experiments/generic/icons/pod-autoscaler.png b/experiments/generic/icons/pod-autoscaler.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-autoscaler.png and /dev/null differ diff --git a/experiments/generic/icons/pod-cpu-hog-exec.png b/experiments/generic/icons/pod-cpu-hog-exec.png deleted file mode 100644 index c152ab5..0000000 Binary files a/experiments/generic/icons/pod-cpu-hog-exec.png and /dev/null differ diff --git a/experiments/generic/icons/pod-cpu-hog.png b/experiments/generic/icons/pod-cpu-hog.png deleted file mode 100644 index c152ab5..0000000 Binary files a/experiments/generic/icons/pod-cpu-hog.png and /dev/null differ diff --git a/experiments/generic/icons/pod-delete.png b/experiments/generic/icons/pod-delete.png deleted file mode 100644 index 16aa7b4..0000000 Binary files a/experiments/generic/icons/pod-delete.png and /dev/null differ diff --git a/experiments/generic/icons/pod-dns-error.png b/experiments/generic/icons/pod-dns-error.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-dns-error.png and /dev/null differ diff --git a/experiments/generic/icons/pod-dns-spoof.png b/experiments/generic/icons/pod-dns-spoof.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-dns-spoof.png and /dev/null differ diff --git a/experiments/generic/icons/pod-http-latency.png b/experiments/generic/icons/pod-http-latency.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-http-latency.png and /dev/null differ diff --git a/experiments/generic/icons/pod-http-modify-body.png b/experiments/generic/icons/pod-http-modify-body.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-http-modify-body.png and /dev/null differ diff --git a/experiments/generic/icons/pod-http-modify-header.png b/experiments/generic/icons/pod-http-modify-header.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-http-modify-header.png and /dev/null differ diff --git a/experiments/generic/icons/pod-http-reset-peer.png b/experiments/generic/icons/pod-http-reset-peer.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-http-reset-peer.png and /dev/null differ diff --git a/experiments/generic/icons/pod-http-status-code.png b/experiments/generic/icons/pod-http-status-code.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-http-status-code.png and /dev/null differ diff --git a/experiments/generic/icons/pod-io-stress.png b/experiments/generic/icons/pod-io-stress.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-io-stress.png and /dev/null differ diff --git a/experiments/generic/icons/pod-memory-hog-exec.png b/experiments/generic/icons/pod-memory-hog-exec.png deleted file mode 100644 index e49a468..0000000 Binary files a/experiments/generic/icons/pod-memory-hog-exec.png and /dev/null differ diff --git a/experiments/generic/icons/pod-memory-hog.png b/experiments/generic/icons/pod-memory-hog.png deleted file mode 100644 index e49a468..0000000 Binary files a/experiments/generic/icons/pod-memory-hog.png and /dev/null differ diff --git a/experiments/generic/icons/pod-network-corruption.png b/experiments/generic/icons/pod-network-corruption.png deleted file mode 100644 index 719a526..0000000 Binary files a/experiments/generic/icons/pod-network-corruption.png and /dev/null differ diff --git a/experiments/generic/icons/pod-network-duplication.png b/experiments/generic/icons/pod-network-duplication.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-network-duplication.png and /dev/null differ diff --git a/experiments/generic/icons/pod-network-latency.png b/experiments/generic/icons/pod-network-latency.png deleted file mode 100644 index 9f34798..0000000 Binary files a/experiments/generic/icons/pod-network-latency.png and /dev/null differ diff --git a/experiments/generic/icons/pod-network-loss.png b/experiments/generic/icons/pod-network-loss.png deleted file mode 100644 index 5826e28..0000000 Binary files a/experiments/generic/icons/pod-network-loss.png and /dev/null differ diff --git a/experiments/generic/icons/pod-network-partition.png b/experiments/generic/icons/pod-network-partition.png deleted file mode 100644 index 5d13f6b..0000000 Binary files a/experiments/generic/icons/pod-network-partition.png and /dev/null differ diff --git a/experiments/generic/kubelet-service-kill/engine.yaml b/experiments/generic/kubelet-service-kill/engine.yaml deleted file mode 100644 index 5ebc548..0000000 --- a/experiments/generic/kubelet-service-kill/engine.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: kubelet-service-kill-sa - experiments: - - name: kubelet-service-kill - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # provide the target node name - - name: TARGET_NODE - value: '' diff --git a/experiments/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml b/experiments/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml deleted file mode 100644 index 65f3032..0000000 --- a/experiments/generic/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-06-13T10:28:08Z - name: kubelet-service-kill - version: 0.1.3 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: kubelet-service-kill - categoryDescription: | - kubelet-service-kill contains killing kubelet service gracefully for a certain chaos duration. - - Causes replicas may be evicted or becomes unreachable on account on nodes turning unschedulable (Not Ready) due to kubelet service kill. - - The application node should be healthy once chaos is stopped and the services are reaccessable. - - keywords: - - Kubernetes - - K8S - - Kubelet - - Node - - Service - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/kubelet-service-kill - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/kubelet-service-kill/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/kubelet-service-kill/experiment.yaml diff --git a/experiments/generic/kubelet-service-kill/rbac-psp.yaml b/experiments/generic/kubelet-service-kill/rbac-psp.yaml deleted file mode 100644 index fb2dac3..0000000 --- a/experiments/generic/kubelet-service-kill/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: kubelet-service-kill-sa - namespace: default - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: kubelet-service-kill-sa -subjects: -- kind: ServiceAccount - name: kubelet-service-kill-sa - namespace: default diff --git a/experiments/generic/kubelet-service-kill/rbac.yaml b/experiments/generic/kubelet-service-kill/rbac.yaml deleted file mode 100644 index 4840f37..0000000 --- a/experiments/generic/kubelet-service-kill/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: kubelet-service-kill-sa - namespace: default - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: kubelet-service-kill-sa - labels: - name: kubelet-service-kill-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: kubelet-service-kill-sa -subjects: -- kind: ServiceAccount - name: kubelet-service-kill-sa - namespace: default diff --git a/experiments/generic/node-cpu-hog/engine.yaml b/experiments/generic/node-cpu-hog/engine.yaml deleted file mode 100644 index 85f754f..0000000 --- a/experiments/generic/node-cpu-hog/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-cpu-hog-sa - experiments: - - name: node-cpu-hog - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - - name: NODE_CPU_CORE - value: '1' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '0' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - # provide the comma separated target node names - - name: TARGET_NODES - value: '' diff --git a/experiments/generic/node-cpu-hog/experiment.yaml b/experiments/generic/node-cpu-hog/experiment.yaml deleted file mode 100644 index c0a85dd..0000000 --- a/experiments/generic/node-cpu-hog/experiment.yaml +++ /dev/null @@ -1,104 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a cpu spike on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-cpu-hog - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-cpu-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - - name: NODE_CPU_CORE - value: '' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml b/experiments/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml deleted file mode 100644 index f479b53..0000000 --- a/experiments/generic/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-cpu-hog - version: 0.0.15 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-cpu-hog - categoryDescription: | - Node CPU hog contains chaos to disrupt the state of Kubernetes resources. Experiments can inject a CPU spike on a node where the application pod is scheduled. - - CPU hog on a particular node where the application deployment is available. - - After test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. - keywords: - - Kubernetes - - K8S - - CPU - - Node - platforms: - - GKE - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - chaosType: infra - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-cpu-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-cpu-hog/ - - name: Video - url: https://www.youtube.com/watch?v=jpJttftsZqA - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-cpu-hog/experiment.yaml diff --git a/experiments/generic/node-cpu-hog/rbac-psp.yaml b/experiments/generic/node-cpu-hog/rbac-psp.yaml deleted file mode 100644 index 4ae8ce7..0000000 --- a/experiments/generic/node-cpu-hog/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-cpu-hog-sa - namespace: default - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: node-cpu-hog-sa - namespace: default diff --git a/experiments/generic/node-cpu-hog/rbac.yaml b/experiments/generic/node-cpu-hog/rbac.yaml deleted file mode 100644 index 40e88cd..0000000 --- a/experiments/generic/node-cpu-hog/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-cpu-hog-sa - namespace: default - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-cpu-hog-sa - labels: - name: node-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: node-cpu-hog-sa - namespace: default diff --git a/experiments/generic/node-drain/node-drain.chartserviceversion.yaml b/experiments/generic/node-drain/node-drain.chartserviceversion.yaml deleted file mode 100644 index 9b513d9..0000000 --- a/experiments/generic/node-drain/node-drain.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-13T10:28:08Z - name: node-drain - version: 0.1.12 - annotations: - categories: Kubernetes - vendor: Mayadata - repository: https://github.com/litmuschaos/chaos-charts - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: node-drain - categoryDescription: > - Drain the node where application pod is scheduled - keywords: - - Kubernetes - - K8S - - Node - - Drain - platforms: - - GKE - - AWS(KOPS) - - Packet(Kubeadm) - - Konvoy - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-drain - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-drain/ - - name: Video - url: https://www.youtube.com/watch?v=LQVCZUQ4-ok - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-drain/experiment.yaml diff --git a/experiments/generic/node-drain/rbac-psp.yaml b/experiments/generic/node-drain/rbac-psp.yaml deleted file mode 100644 index c1ddf8c..0000000 --- a/experiments/generic/node-drain/rbac-psp.yaml +++ /dev/null @@ -1,75 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-drain-sa - namespace: default - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-drain-sa -subjects: -- kind: ServiceAccount - name: node-drain-sa - namespace: default diff --git a/experiments/generic/node-drain/rbac.yaml b/experiments/generic/node-drain/rbac.yaml deleted file mode 100644 index e16cbd8..0000000 --- a/experiments/generic/node-drain/rbac.yaml +++ /dev/null @@ -1,70 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-drain-sa - namespace: default - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-drain-sa - labels: - name: node-drain-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-drain-sa -subjects: -- kind: ServiceAccount - name: node-drain-sa - namespace: default diff --git a/experiments/generic/node-io-stress/engine.yaml b/experiments/generic/node-io-stress/engine.yaml deleted file mode 100644 index 938949f..0000000 --- a/experiments/generic/node-io-stress/engine.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-io-stress-sa - experiments: - - name: node-io-stress - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## Number of core of CPU - - name: CPU - value: '1' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - # provide the comma separated target node names - - name: TARGET_NODES - value: '' diff --git a/experiments/generic/node-io-stress/experiment.yaml b/experiments/generic/node-io-stress/experiment.yaml deleted file mode 100644 index 0e46e7f..0000000 --- a/experiments/generic/node-io-stress/experiment.yaml +++ /dev/null @@ -1,116 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give IO disk stress on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-io-stress - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-io-stress - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - ## default value 90 (in percentage) - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space - ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - - name: FILESYSTEM_UTILIZATION_BYTES - value: '' - - ## Number of core of CPU - - name: CPU - value: '1' - - ## Total number of workers default value is 4 - - name: NUMBER_OF_WORKERS - value: '4' - - ## Total number of vm workers - - name: VM_WORKERS - value: '1' - - ## enter the comma separated target nodes name - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-io-stress - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/node-io-stress/node-io-stress.chartserviceversion.yaml b/experiments/generic/node-io-stress/node-io-stress.chartserviceversion.yaml deleted file mode 100644 index 2f990bc..0000000 --- a/experiments/generic/node-io-stress/node-io-stress.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-09-12T10:28:08Z - name: node-io-stress - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-io-stress - categoryDescription: | - This experiment causes disk stress on the Kubernetes node. The experiment aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes.. - - Disk stress on a particular node filesystem where the application deployment is available. - - The amount of disk stress can be either specifed as the size in percentage of the total free space on the file system or simply in Gigabytes(GB) - keywords: - - Kubernetes - - K8S - - Disk - - IO - - Filesystem - - Node - platforms: - - GKE - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-io-stress - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-io-stress/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-io-stress/experiment.yaml diff --git a/experiments/generic/node-io-stress/rbac-psp.yaml b/experiments/generic/node-io-stress/rbac-psp.yaml deleted file mode 100644 index ab12913..0000000 --- a/experiments/generic/node-io-stress/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-io-stress-sa - namespace: default - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-io-stress-sa -subjects: -- kind: ServiceAccount - name: node-io-stress-sa - namespace: default diff --git a/experiments/generic/node-io-stress/rbac.yaml b/experiments/generic/node-io-stress/rbac.yaml deleted file mode 100644 index a6858e7..0000000 --- a/experiments/generic/node-io-stress/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-io-stress-sa - namespace: default - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-io-stress-sa - labels: - name: node-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-io-stress-sa -subjects: -- kind: ServiceAccount - name: node-io-stress-sa - namespace: default diff --git a/experiments/generic/node-memory-hog/engine.yaml b/experiments/generic/node-memory-hog/engine.yaml deleted file mode 100644 index 8e6b01c..0000000 --- a/experiments/generic/node-memory-hog/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-memory-hog-sa - experiments: - - name: node-memory-hog - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - # provide the comma separated target node names - - name: TARGET_NODES - value: '' - - ## Specify the size as percent of total node capacity Ex: '30' - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - - name: MEMORY_CONSUMPTION_PERCENTAGE - value: '0' - - ## Specify the amount of memory to be consumed in mebibytes - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - - name: MEMORY_CONSUMPTION_MEBIBYTES - value: '0' diff --git a/experiments/generic/node-memory-hog/experiment.yaml b/experiments/generic/node-memory-hog/experiment.yaml deleted file mode 100644 index f5f7b59..0000000 --- a/experiments/generic/node-memory-hog/experiment.yaml +++ /dev/null @@ -1,107 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Give a memory hog on a node belonging to a deployment -kind: ChaosExperiment -metadata: - name: node-memory-hog - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-memory-hog - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## Specify the size as percent of total node capacity Ex: '30' - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - - name: MEMORY_CONSUMPTION_PERCENTAGE - value: '' - - ## Specify the amount of memory to be consumed in mebibytes - ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - - name: MEMORY_CONSUMPTION_MEBIBYTES - value: '' - - - name: NUMBER_OF_WORKERS - value: '1' - - # ENTER THE COMMA SEPARATED TARGET NODES NAME - - name: TARGET_NODES - value: '' - - - name: NODE_LABEL - value: '' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # Provide the LIB here - # Only litmus supported - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## percentage of total nodes to target - - name: NODES_AFFECTED_PERC - value: '' - - ## it defines the sequence of chaos execution for multiple target nodes - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: node-memory-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml b/experiments/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml deleted file mode 100644 index f6d7cf1..0000000 --- a/experiments/generic/node-memory-hog/node-memory-hog.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-28T10:28:08Z - name: node-memory-hog - version: 0.1.5 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-memory-hog - categoryDescription: | - Kubernetes Node memory hog contains chaos to disrupt the state of Kubernetes resources. Experiments can inject a memory spike on a node where the application pod is scheduled. - - Memory hog on a particular node where the application deployment is available. - - After the test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. - keywords: - - Kubernetes - - K8S - - Memory - - Node - platforms: - - GKE - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-memory-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-memory-hog/ - - name: Video - url: https://www.youtube.com/watch?v=ECxlWgQ8F5w - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-memory-hog/experiment.yaml diff --git a/experiments/generic/node-memory-hog/rbac-psp.yaml b/experiments/generic/node-memory-hog/rbac-psp.yaml deleted file mode 100644 index a6002c5..0000000 --- a/experiments/generic/node-memory-hog/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-memory-hog-sa - namespace: default - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-memory-hog-sa -subjects: -- kind: ServiceAccount - name: node-memory-hog-sa - namespace: default diff --git a/experiments/generic/node-memory-hog/rbac.yaml b/experiments/generic/node-memory-hog/rbac.yaml deleted file mode 100644 index 74cd3eb..0000000 --- a/experiments/generic/node-memory-hog/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-memory-hog-sa - namespace: default - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-memory-hog-sa - labels: - name: node-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-memory-hog-sa -subjects: -- kind: ServiceAccount - name: node-memory-hog-sa - namespace: default diff --git a/experiments/generic/node-poweroff/experiment.yaml b/experiments/generic/node-poweroff/experiment.yaml deleted file mode 100644 index d598147..0000000 --- a/experiments/generic/node-poweroff/experiment.yaml +++ /dev/null @@ -1,97 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - poweroff node -kind: ChaosExperiment -metadata: - name: node-poweroff - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: REBOOT_COMMAND - value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ diff --git a/experiments/generic/node-poweroff/node-poweroff.chartserviceversion.yaml b/experiments/generic/node-poweroff/node-poweroff.chartserviceversion.yaml deleted file mode 100644 index 566ca14..0000000 --- a/experiments/generic/node-poweroff/node-poweroff.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-poweroff - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-poweroff - categoryDescription: | - Node poweroff contains chaos experiment to poweroff a node via SSH. - keywords: - - Kubernetes - - K8S - - Poweroff - - Node - platforms: - - KVM/LibVirt based K8s - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: jordigilh - email: jordi.gil@gmail.com - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-restart - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-restart - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-poweroff/experiment.yaml diff --git a/experiments/generic/node-poweroff/rbac-psp.yaml b/experiments/generic/node-poweroff/rbac-psp.yaml deleted file mode 100644 index 93abac3..0000000 --- a/experiments/generic/node-poweroff/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-poweroff-sa - namespace: default - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-poweroff-sa -subjects: -- kind: ServiceAccount - name: node-poweroff-sa - namespace: default diff --git a/experiments/generic/node-poweroff/rbac.yaml b/experiments/generic/node-poweroff/rbac.yaml deleted file mode 100644 index 16898df..0000000 --- a/experiments/generic/node-poweroff/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-poweroff-sa - namespace: default - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-poweroff-sa - labels: - name: node-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-poweroff-sa -subjects: -- kind: ServiceAccount - name: node-poweroff-sa - namespace: default diff --git a/experiments/generic/node-restart/experiment.yaml b/experiments/generic/node-restart/experiment.yaml deleted file mode 100644 index f36bf82..0000000 --- a/experiments/generic/node-restart/experiment.yaml +++ /dev/null @@ -1,94 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Restart node -kind: ChaosExperiment -metadata: - name: node-restart - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-restart - command: - - /bin/bash - env: - - name: SSH_USER - value: 'root' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' - - - name: NODE_LABEL - value: '' - - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' - - labels: - name: node-restart - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: id-rsa - mountPath: /mnt/ diff --git a/experiments/generic/node-restart/node-restart.chartserviceversion.yaml b/experiments/generic/node-restart/node-restart.chartserviceversion.yaml deleted file mode 100644 index 4eceec8..0000000 --- a/experiments/generic/node-restart/node-restart.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-28T10:28:08Z - name: node-restart - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: node-restart - categoryDescription: | - Node restart contains chaos to restart the node via SSH. - keywords: - - Kubernetes - - K8S - - Restart - - Node - platforms: - - KVM/LibVirt based K8s - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: machacekondra - email: machacek.ondra@gmail.com - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-restart - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-restart - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-restart/experiment.yaml diff --git a/experiments/generic/node-restart/rbac-psp.yaml b/experiments/generic/node-restart/rbac-psp.yaml deleted file mode 100644 index b21b60b..0000000 --- a/experiments/generic/node-restart/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-restart-sa - namespace: default - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-restart-sa -subjects: -- kind: ServiceAccount - name: node-restart-sa - namespace: default diff --git a/experiments/generic/node-restart/rbac.yaml b/experiments/generic/node-restart/rbac.yaml deleted file mode 100644 index 9b48dd1..0000000 --- a/experiments/generic/node-restart/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-restart-sa - namespace: default - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-restart-sa - labels: - name: node-restart-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-restart-sa -subjects: -- kind: ServiceAccount - name: node-restart-sa - namespace: default diff --git a/experiments/generic/node-taint/engine.yaml b/experiments/generic/node-taint/engine.yaml deleted file mode 100644 index 44cfc24..0000000 --- a/experiments/generic/node-taint/engine.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: node-taint-sa - experiments: - - name: node-taint - spec: - components: - # nodeSelector: - # # provide the node labels - # kubernetes.io/hostname: 'node02' - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - # set target node name - - name: TARGET_NODE - value: '' - - # set taint label & effect - # key=value:effect or key:effect - - name: TAINTS - value: 'node.kubernetes.io/unreachable:NoExecute' - \ No newline at end of file diff --git a/experiments/generic/node-taint/experiment.yaml b/experiments/generic/node-taint/experiment.yaml deleted file mode 100644 index 6845d02..0000000 --- a/experiments/generic/node-taint/experiment.yaml +++ /dev/null @@ -1,90 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Taint the node where application pod is scheduled -kind: ChaosExperiment -metadata: - name: node-taint - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name node-taint - 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: '' - - # set taint label & effect - # key=value:effect or key:effect - - name: TAINTS - value: '' - - labels: - name: node-taint - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/node-taint/node-taint.chartserviceversion.yaml b/experiments/generic/node-taint/node-taint.chartserviceversion.yaml deleted file mode 100644 index 6e19973..0000000 --- a/experiments/generic/node-taint/node-taint.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-01-13T10:28:08Z - name: node-taint - version: 0.1.2 - annotations: - categories: Kubernetes - vendor: Mayadata - repository: https://github.com/litmuschaos/chaos-charts - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: node-taint - categoryDescription: > - Taint the node where application pod is scheduled - keywords: - - Kubernetes - - K8S - - Node - - Taint - platforms: - - GKE - - AWS(KOPS) - - Packet(Kubeadm) - - Konvoy - - EKS - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/node-taint - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/nodes/node-taint/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/node-taint/experiment.yaml diff --git a/experiments/generic/node-taint/rbac-psp.yaml b/experiments/generic/node-taint/rbac-psp.yaml deleted file mode 100644 index 1188ec7..0000000 --- a/experiments/generic/node-taint/rbac-psp.yaml +++ /dev/null @@ -1,75 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-taint-sa - namespace: default - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-taint-sa -subjects: -- kind: ServiceAccount - name: node-taint-sa - namespace: default diff --git a/experiments/generic/node-taint/rbac.yaml b/experiments/generic/node-taint/rbac.yaml deleted file mode 100644 index 8981a55..0000000 --- a/experiments/generic/node-taint/rbac.yaml +++ /dev/null @@ -1,70 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-taint-sa - namespace: default - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] - # ignore daemonsets while draining the node - - apiGroups: ["apps"] - resources: ["daemonsets"] - verbs: ["list","get","delete"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch","update"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: node-taint-sa - labels: - name: node-taint-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: node-taint-sa -subjects: -- kind: ServiceAccount - name: node-taint-sa - namespace: default diff --git a/experiments/generic/pod-autoscaler/engine.yaml b/experiments/generic/pod-autoscaler/engine.yaml deleted file mode 100644 index 65dfbf1..0000000 --- a/experiments/generic/pod-autoscaler/engine.yaml +++ /dev/null @@ -1,28 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-autoscaler-sa - experiments: - - name: pod-autoscaler - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' - - # number of replicas to scale - - name: REPLICA_COUNT - value: '5' - \ No newline at end of file diff --git a/experiments/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml b/experiments/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml deleted file mode 100644 index a22bc4c..0000000 --- a/experiments/generic/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-08-08T10:28:08Z - name: pod-autoscaler - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-autoscaler - categoryDescription: | - The experiment aims to check the ability of nodes to accommodate the number of replicas a given application pod. - This experiment can be used for other scenarios as well, such as for checking the Node auto-scaling feature. For example, check if the pods are successfully rescheduled within a specified period in cases where the existing nodes are already running at the specified limits. - keywords: - - Kubernetes - - K8S - - Scale - - Pod - platforms: - - GKE - - EKS - - Minikube - - AKS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-autoscaler - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-autoscaler/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-autoscaler/experiment.yaml diff --git a/experiments/generic/pod-autoscaler/rbac-psp.yaml b/experiments/generic/pod-autoscaler/rbac-psp.yaml deleted file mode 100644 index 49a03ac..0000000 --- a/experiments/generic/pod-autoscaler/rbac-psp.yaml +++ /dev/null @@ -1,71 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-autoscaler-sa - namespace: default - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-autoscaler-sa -subjects: -- kind: ServiceAccount - name: pod-autoscaler-sa - namespace: default diff --git a/experiments/generic/pod-autoscaler/rbac.yaml b/experiments/generic/pod-autoscaler/rbac.yaml deleted file mode 100644 index 19114f1..0000000 --- a/experiments/generic/pod-autoscaler/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-autoscaler-sa - namespace: default - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # performs CRUD operations on the deployments and statefulsets - - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-autoscaler-sa - labels: - name: pod-autoscaler-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-autoscaler-sa -subjects: -- kind: ServiceAccount - name: pod-autoscaler-sa - namespace: default diff --git a/experiments/generic/pod-cpu-hog-exec/experiment.yaml b/experiments/generic/pod-cpu-hog-exec/experiment.yaml deleted file mode 100644 index a04eda9..0000000 --- a/experiments/generic/pod-cpu-hog-exec/experiment.yaml +++ /dev/null @@ -1,105 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog-exec - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog-exec - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus - - name: LIB - value: 'litmus' - - # The command to kill the chaos process - - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/md5sum' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}')" - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog-exec - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml b/experiments/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml deleted file mode 100644 index 65ef4e8..0000000 --- a/experiments/generic/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-cpu-hog-exec - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-cpu-hog-exec - categoryDescription: | - pod-cpu-hog-exec contains chaos to consume CPU resouces of specified containers in Kubernetes pods. - - Causes high CPU resource consumption utilizing one or more cores by triggering md5sum commands - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - CPU - - Pod - - Exec - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - maturity: alpha - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-cpu-hog-exec - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-cpu-hog-exec/ - - name: Video - url: https://www.youtube.com/watch?v=MBGSPmZKb2I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-cpu-hog-exec/experiment.yaml diff --git a/experiments/generic/pod-cpu-hog-exec/rbac-psp.yaml b/experiments/generic/pod-cpu-hog-exec/rbac-psp.yaml deleted file mode 100644 index f1733be..0000000 --- a/experiments/generic/pod-cpu-hog-exec/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-exec-sa - namespace: default diff --git a/experiments/generic/pod-cpu-hog-exec/rbac.yaml b/experiments/generic/pod-cpu-hog-exec/rbac.yaml deleted file mode 100644 index 9e80151..0000000 --- a/experiments/generic/pod-cpu-hog-exec/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-exec-sa - namespace: default - labels: - name: pod-cpu-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-exec-sa - namespace: default diff --git a/experiments/generic/pod-cpu-hog/experiment.yaml b/experiments/generic/pod-cpu-hog/experiment.yaml deleted file mode 100644 index e49ce0b..0000000 --- a/experiments/generic/pod-cpu-hog/experiment.yaml +++ /dev/null @@ -1,127 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects cpu consumption on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-cpu-hog - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-cpu-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - ## Number of CPU cores to stress - - name: CPU_CORES - value: '1' - - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. - ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - - name: CPU_LOAD - value: '100' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, pumba - - name: LIB - value: 'litmus' - - ## It is used in pumba lib only - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - ## It is used in pumba lib only - - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-cpu-hog - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml b/experiments/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml deleted file mode 100644 index 5206115..0000000 --- a/experiments/generic/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml +++ /dev/null @@ -1,53 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-cpu-hog - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-cpu-hog - categoryDescription: | - Pod-CPU-Hog contains chaos to consume CPU resouces of specified containers in Kubernetes pods. - - Causes CPU resource consumption on specified application containers using cgroups and litmus nsutil which consume CPU resources of the given target containers. - - It Can test the application's resilience to potential slowness/unavailability of some replicas due to high CPU load - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - CPU - - Pod - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - maturity: alpha - maintainers: - - name: ksatchit - email: karthik@chaosnative.com - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-cpu-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-cpu-hog/ - - name: Video - url: https://www.youtube.com/watch?v=MBGSPmZKb2I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-cpu-hog/experiment.yaml diff --git a/experiments/generic/pod-cpu-hog/rbac-psp.yaml b/experiments/generic/pod-cpu-hog/rbac-psp.yaml deleted file mode 100644 index 8952968..0000000 --- a/experiments/generic/pod-cpu-hog/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-sa - namespace: default diff --git a/experiments/generic/pod-cpu-hog/rbac.yaml b/experiments/generic/pod-cpu-hog/rbac.yaml deleted file mode 100644 index f045de3..0000000 --- a/experiments/generic/pod-cpu-hog/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-cpu-hog-sa - namespace: default - labels: - name: pod-cpu-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-cpu-hog-sa -subjects: -- kind: ServiceAccount - name: pod-cpu-hog-sa - namespace: default diff --git a/experiments/generic/pod-delete/ansible/engine.yaml b/experiments/generic/pod-delete/ansible/engine.yaml deleted file mode 100644 index 871f8f2..0000000 --- a/experiments/generic/pod-delete/ansible/engine.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: pod-delete-sa - 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' diff --git a/experiments/generic/pod-delete/ansible/experiment.yaml b/experiments/generic/pod-delete/ansible/experiment.yaml deleted file mode 100644 index 86a289a..0000000 --- a/experiments/generic/pod-delete/ansible/experiment.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/generic/pod_delete/pod_delete_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - - name: LIB_IMAGE - value: 'litmuschaos/pod-delete-helper:latest' - - - name: LIB - value: 'litmus' - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-delete/ansible/powerfulseal_rbac.yaml b/experiments/generic/pod-delete/ansible/powerfulseal_rbac.yaml deleted file mode 100644 index f53e37b..0000000 --- a/experiments/generic/pod-delete/ansible/powerfulseal_rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pod-delete-sa - labels: - name: pod-delete-sa -rules: -- apiGroups: ["","litmuschaos.io","batch","apps"] - resources: ["pods","deployments","pods/log","events","jobs","configmaps","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pod-delete-sa - labels: - name: pod-delete-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/experiments/generic/pod-delete/ansible/rbac.yaml b/experiments/generic/pod-delete/ansible/rbac.yaml deleted file mode 100644 index 6a1535b..0000000 --- a/experiments/generic/pod-delete/ansible/rbac.yaml +++ /dev/null @@ -1,40 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","litmuschaos.io","batch","apps"] - resources: ["pods","deployments","pods/log","events","jobs","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/experiments/generic/pod-delete/engine.yaml b/experiments/generic/pod-delete/engine.yaml deleted file mode 100644 index c211c73..0000000 --- a/experiments/generic/pod-delete/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - chaosServiceAccount: pod-delete-sa - 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/experiments/generic/pod-delete/engine_nginx_getstarted.yaml b/experiments/generic/pod-delete/engine_nginx_getstarted.yaml deleted file mode 100644 index 043113f..0000000 --- a/experiments/generic/pod-delete/engine_nginx_getstarted.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: nginx -spec: - appinfo: - appns: 'nginx' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: pod-delete-sa - # 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/experiments/generic/pod-delete/experiment.yaml b/experiments/generic/pod-delete/experiment.yaml deleted file mode 100644 index 46b9162..0000000 --- a/experiments/generic/pod-delete/experiment.yaml +++ /dev/null @@ -1,106 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-delete - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-delete/pod-delete.chartserviceversion.yaml b/experiments/generic/pod-delete/pod-delete.chartserviceversion.yaml deleted file mode 100644 index b5e42b6..0000000 --- a/experiments/generic/pod-delete/pod-delete.chartserviceversion.yaml +++ /dev/null @@ -1,52 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-15T10:28:08Z - name: pod-delete - version: 0.1.13 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-delete - categoryDescription: | - Pod delete contains chaos to disrupt state of kubernetes resources. Experiments can inject random pod delete failures against specified application. - - Causes (forced/graceful) pod failure of random replicas of an application deployment. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. - - keywords: - - Kubernetes - - K8S - - Pod - platforms: - - GKE - - Konvoy - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - Kind - - Rancher - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-delete - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-delete/ - - name: Video - url: https://www.youtube.com/watch?v=X3JvY_58V9A - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-delete/experiment.yaml diff --git a/experiments/generic/pod-delete/python/engine.yaml b/experiments/generic/pod-delete/python/engine.yaml deleted file mode 100644 index c211c73..0000000 --- a/experiments/generic/pod-delete/python/engine.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - # It can be active/stop - engineState: 'active' - chaosServiceAccount: pod-delete-sa - 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' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/experiments/generic/pod-delete/python/experiment.yaml b/experiments/generic/pod-delete/python/experiment.yaml deleted file mode 100644 index d80a29d..0000000 --- a/experiments/generic/pod-delete/python/experiment.yaml +++ /dev/null @@ -1,90 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - name: pod-delete - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "apps.openshift.io" - - "argoproj.io" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "replicationcontrollers" - - "deployments" - - "statefulsets" - - "daemonsets" - - "replicasets" - - "deploymentconfigs" - - "rollouts" - - "pods/exec" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - "deletecollection" - image: "litmuschaos/py-runner:latest" - imagePullPolicy: Always - args: - - -c - - python3 -u experiment - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-delete - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-delete/python/rbac.yaml b/experiments/generic/pod-delete/python/rbac.yaml deleted file mode 100644 index 350173d..0000000 --- a/experiments/generic/pod-delete/python/rbac.yaml +++ /dev/null @@ -1,58 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: [""] - resources: ["pods","events"] - verbs: ["create","list","get","patch","update","delete","deletecollection"] -- apiGroups: [""] - resources: ["pods/exec","pods/log","replicationcontrollers"] - verbs: ["create","list","get"] -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -- apiGroups: ["apps"] - resources: ["deployments","statefulsets","daemonsets","replicasets"] - verbs: ["list","get"] -- apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] -- apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/experiments/generic/pod-delete/rbac-psp.yaml b/experiments/generic/pod-delete/rbac-psp.yaml deleted file mode 100644 index e494e6b..0000000 --- a/experiments/generic/pod-delete/rbac-psp.yaml +++ /dev/null @@ -1,86 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/experiments/generic/pod-delete/rbac.yaml b/experiments/generic/pod-delete/rbac.yaml deleted file mode 100644 index a3f4f5c..0000000 --- a/experiments/generic/pod-delete/rbac.yaml +++ /dev/null @@ -1,81 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: default - labels: - name: pod-delete-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: default - diff --git a/experiments/generic/pod-delete/rbac_nginx_getstarted.yaml b/experiments/generic/pod-delete/rbac_nginx_getstarted.yaml deleted file mode 100644 index 5ff2c83..0000000 --- a/experiments/generic/pod-delete/rbac_nginx_getstarted.yaml +++ /dev/null @@ -1,77 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-delete-sa - namespace: nginx - labels: - name: pod-delete-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-delete-sa -subjects: -- kind: ServiceAccount - name: pod-delete-sa - namespace: nginx \ No newline at end of file diff --git a/experiments/generic/pod-dns-error/engine.yaml b/experiments/generic/pod-dns-error/engine.yaml deleted file mode 100644 index 83fd6bb..0000000 --- a/experiments/generic/pod-dns-error/engine.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos -spec: - appinfo: - appns: "default" - applabel: "app=nginx" - appkind: "deployment" - # It can be active/stop - engineState: "active" - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: "" - chaosServiceAccount: pod-dns-error-sa - experiments: - - name: pod-dns-error - 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: "" - - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring - - name: MATCH_SCHEME - value: "exact" - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" diff --git a/experiments/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml b/experiments/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml deleted file mode 100644 index 4ece88e..0000000 --- a/experiments/generic/pod-dns-error/pod-dns-error.chartserviceversion.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-dns-error - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-dns-error - categoryDescription: > - Pod DNS Error injects dns failure/error in target pod containers - keywords: - - "Pod" - - K8S - - "Kubernetes" - - "DNS" - maturity: alpha - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - maintainers: - - name: gdsoumya - email: gdsoumya@chaosnative.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-dns-error - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/getstarted/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-dns-error/experiment.yaml diff --git a/experiments/generic/pod-dns-error/rbac-psp.yaml b/experiments/generic/pod-dns-error/rbac-psp.yaml deleted file mode 100644 index 1e8bbfd..0000000 --- a/experiments/generic/pod-dns-error/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-error-sa -subjects: - - kind: ServiceAccount - name: pod-dns-error-sa - namespace: default diff --git a/experiments/generic/pod-dns-error/rbac.yaml b/experiments/generic/pod-dns-error/rbac.yaml deleted file mode 100644 index 84dc894..0000000 --- a/experiments/generic/pod-dns-error/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-error-sa - namespace: default - labels: - name: pod-dns-error-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-error-sa -subjects: - - kind: ServiceAccount - name: pod-dns-error-sa - namespace: default diff --git a/experiments/generic/pod-dns-spoof/engine.yaml b/experiments/generic/pod-dns-spoof/engine.yaml deleted file mode 100644 index a468d88..0000000 --- a/experiments/generic/pod-dns-spoof/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos -spec: - appinfo: - appns: "default" - applabel: "app=nginx" - appkind: "deployment" - # It can be active/stop - engineState: "active" - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: "" - chaosServiceAccount: pod-dns-spoof-sa - experiments: - - name: pod-dns-spoof - 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"}' - - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" diff --git a/experiments/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml b/experiments/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml deleted file mode 100644 index b179d30..0000000 --- a/experiments/generic/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-dns-spoof - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-dns-spoof - categoryDescription: > - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames - keywords: - - "Pod" - - K8S - - "Kubernetes" - - "DNS" - maturity: alpha - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - maintainers: - - name: gdsoumya - email: gdsoumya@chaosnative.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-dns-spoof - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/getstarted/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-dns-spoof/experiment.yaml diff --git a/experiments/generic/pod-dns-spoof/rbac-psp.yaml b/experiments/generic/pod-dns-spoof/rbac-psp.yaml deleted file mode 100644 index 106c044..0000000 --- a/experiments/generic/pod-dns-spoof/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-spoof-sa -subjects: - - kind: ServiceAccount - name: pod-dns-spoof-sa - namespace: default diff --git a/experiments/generic/pod-dns-spoof/rbac.yaml b/experiments/generic/pod-dns-spoof/rbac.yaml deleted file mode 100644 index 6d2c76d..0000000 --- a/experiments/generic/pod-dns-spoof/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-dns-spoof-sa - namespace: default - labels: - name: pod-dns-spoof-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-dns-spoof-sa -subjects: - - kind: ServiceAccount - name: pod-dns-spoof-sa - namespace: default diff --git a/experiments/generic/pod-http-latency/experiment.yaml b/experiments/generic/pod-http-latency/experiment.yaml deleted file mode 100644 index f7ae573..0000000 --- a/experiments/generic/pod-http-latency/experiment.yaml +++ /dev/null @@ -1,140 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects http request latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-http-latency - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: LATENCY - value: '2000' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # toxicity is the probability of the request to be affected - # provide the percentage value in the range of 0-100 - # 0 means no request will be affected and 100 means all request will be affected - - name: TOXICITY - value: "100" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml b/experiments/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml deleted file mode 100644 index d39adc4..0000000 --- a/experiments/generic/pod-http-latency/pod-http-latency.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2022-05-21T10:28:08Z - name: pod-http-latency - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-http-latency - categoryDescription: | - Pod-http-latency contains chaos to disrupt http requests of kubernetes pods. This experiment can inject random http response delays on the app replica pods. - - Causes flaky access to application replica by injecting http response delay using toxiproxy. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - HTTP - - Pod - - Latency - platforms: - - GKE - - Minikube - - EKS - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-latency - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-latency/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-latency/experiment.yaml diff --git a/experiments/generic/pod-http-latency/rbac-psp.yaml b/experiments/generic/pod-http-latency/rbac-psp.yaml deleted file mode 100644 index 3b472ee..0000000 --- a/experiments/generic/pod-http-latency/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-latency-sa -subjects: -- kind: ServiceAccount - name: pod-http-latency-sa - namespace: default diff --git a/experiments/generic/pod-http-latency/rbac.yaml b/experiments/generic/pod-http-latency/rbac.yaml deleted file mode 100644 index 6c46d88..0000000 --- a/experiments/generic/pod-http-latency/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-latency-sa - namespace: default - labels: - name: pod-http-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-latency-sa -subjects: -- kind: ServiceAccount - name: pod-http-latency-sa - namespace: default diff --git a/experiments/generic/pod-http-modify-body/experiment.yaml b/experiments/generic/pod-http-modify-body/experiment.yaml deleted file mode 100644 index 13cd635..0000000 --- a/experiments/generic/pod-http-modify-body/experiment.yaml +++ /dev/null @@ -1,151 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the body of the response from the provided application server to the body string provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-body - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-body - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the body string to overwrite the response body - # if no value is provided, response will be an empty body. - - name: RESPONSE_BODY - value: '' - - # provide the encoding type for the response body - # currently supported value are gzip, deflate - # if empty no encoding will be applied - - name: CONTENT_ENCODING - value: '' - - # provide the content type for the response body - - name: CONTENT_TYPE - value: 'text/plain' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # toxicity is the probability of the request to be affected - # provide the percentage value in the range of 0-100 - # 0 means no request will be affected and 100 means all request will be affected - - name: TOXICITY - value: "100" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-body - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml b/experiments/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml deleted file mode 100644 index 0cf4247..0000000 --- a/experiments/generic/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-modify-body - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-modify-body - categoryDescription: > - Pod-http-modify-body contains chaos to disrupt http requests of kubernetes pods. This experiment can modify the body of the response from the service targetted. - - Causes modification of response body of the HTTP request. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "response body" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-modify-body - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-modify-body/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-modify-body/experiment.yaml \ No newline at end of file diff --git a/experiments/generic/pod-http-modify-body/rbac-psp.yaml b/experiments/generic/pod-http-modify-body/rbac-psp.yaml deleted file mode 100644 index d871fd9..0000000 --- a/experiments/generic/pod-http-modify-body/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-body-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-body-sa - namespace: default diff --git a/experiments/generic/pod-http-modify-body/rbac.yaml b/experiments/generic/pod-http-modify-body/rbac.yaml deleted file mode 100644 index 16ec269..0000000 --- a/experiments/generic/pod-http-modify-body/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-body-sa - namespace: default - labels: - name: pod-http-modify-body-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-body-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-body-sa - namespace: default diff --git a/experiments/generic/pod-http-modify-header/experiment.yaml b/experiments/generic/pod-http-modify-header/experiment.yaml deleted file mode 100644 index 77dd74d..0000000 --- a/experiments/generic/pod-http-modify-header/experiment.yaml +++ /dev/null @@ -1,146 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects the chaos inside the pod which modifies the header of the request/response from the provided application server to the headers provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-modify-header - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-modify-header - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} - # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} - - name: HEADERS_MAP - value: '{}' - - # whether to modify response headers or request headers. Accepted values: request, response - - name: HEADER_MODE - value: 'response' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # toxicity is the probability of the request to be affected - # provide the percentage value in the range of 0-100 - # 0 means no request will be affected and 100 means all request will be affected - - name: TOXICITY - value: "100" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-modify-header - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml b/experiments/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml deleted file mode 100644 index c34601a..0000000 --- a/experiments/generic/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2022-07-13T2:14:08Z - name: pod-http-modify-header - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-http-modify-header - categoryDescription: | - Pod-http-modify-header contains chaos to disrupt http requests of kubernetes pods. This experiment can modify headers of incoming requests or the response from the service targetted. - - Causes modification of request/response headers of the HTTP request. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - HTTP - - Pod - - Headers - platforms: - - GKE - - Minikube - - EKS - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-modify-header - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-modify-header/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-modify-header/experiment.yaml diff --git a/experiments/generic/pod-http-modify-header/rbac-psp.yaml b/experiments/generic/pod-http-modify-header/rbac-psp.yaml deleted file mode 100644 index fb35617..0000000 --- a/experiments/generic/pod-http-modify-header/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-header-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-header-sa - namespace: default diff --git a/experiments/generic/pod-http-modify-header/rbac.yaml b/experiments/generic/pod-http-modify-header/rbac.yaml deleted file mode 100644 index 5f9208f..0000000 --- a/experiments/generic/pod-http-modify-header/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-modify-header-sa - namespace: default - labels: - name: pod-http-modify-header-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-modify-header-sa -subjects: -- kind: ServiceAccount - name: pod-http-modify-header-sa - namespace: default diff --git a/experiments/generic/pod-http-reset-peer/engine.yaml b/experiments/generic/pod-http-reset-peer/engine.yaml deleted file mode 100644 index a052368..0000000 --- a/experiments/generic/pod-http-reset-peer/engine.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-http-reset-peer-sa - experiments: - - name: pod-http-reset-peer - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # reset timeout specifies after how much duration to reset the connection - - name: RESET_TIMEOUT - value: '0' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/experiments/generic/pod-http-reset-peer/experiment.yaml b/experiments/generic/pod-http-reset-peer/experiment.yaml deleted file mode 100644 index f497c53..0000000 --- a/experiments/generic/pod-http-reset-peer/experiment.yaml +++ /dev/null @@ -1,140 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - it injects chaos into the pod which stops outgoing http requests by resetting the TCP connection and then reverts back to the original state after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-reset-peer - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-reset-peer - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # reset timeout specifies after how much duration to reset the connection - - name: RESET_TIMEOUT - value: '0' #in ms - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # toxicity is the probability of the request to be affected - # provide the percentage value in the range of 0-100 - # 0 means no request will be affected and 100 means all request will be affected - - name: TOXICITY - value: "100" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-reset-peer - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml b/experiments/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml deleted file mode 100644 index fcf3b56..0000000 --- a/experiments/generic/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml +++ /dev/null @@ -1,41 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-reset-peer - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-reset-peer - categoryDescription: > - pod-http-reset-peer contains chaos to disrupt http requests of kubernetes pods. This experiment can stop outgoing http requests by resetting the TCP connection on the service targetted. - - Causes connection failure (connection reset by peer) of the HTTP request. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "loss" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-reset-peer - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-reset-peer/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-reset-peer/experiment.yaml \ No newline at end of file diff --git a/experiments/generic/pod-http-reset-peer/rbac-psp.yaml b/experiments/generic/pod-http-reset-peer/rbac-psp.yaml deleted file mode 100644 index 5c22b38..0000000 --- a/experiments/generic/pod-http-reset-peer/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-reset-peer-sa -subjects: -- kind: ServiceAccount - name: pod-http-reset-peer-sa - namespace: default diff --git a/experiments/generic/pod-http-reset-peer/rbac.yaml b/experiments/generic/pod-http-reset-peer/rbac.yaml deleted file mode 100644 index 0c71681..0000000 --- a/experiments/generic/pod-http-reset-peer/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-reset-peer-sa - namespace: default - labels: - name: pod-http-reset-peer-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-reset-peer-sa -subjects: -- kind: ServiceAccount - name: pod-http-reset-peer-sa - namespace: default diff --git a/experiments/generic/pod-http-status-code/engine.yaml b/experiments/generic/pod-http-status-code/engine.yaml deleted file mode 100644 index 1aa1218..0000000 --- a/experiments/generic/pod-http-status-code/engine.yaml +++ /dev/null @@ -1,56 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-http-status-code-sa - experiments: - - name: pod-http-status-code - 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' - - # modified status code for the http response - # if no value is provided, a random status code from the supported code list will selected - # if an invalid status code is provided, the experiment will fail - # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504 - - name: STATUS_CODE - value: '' - - # whether to modify the body as per the status code provided - - name: "MODIFY_RESPONSE_BODY" - value: "true" - - # provide the body string to overwrite the response body. This will be used only if MODIFY_RESPONSE_BODY is set to true - - name: RESPONSE_BODY - value: '' - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # provide the name of container runtime - # it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - diff --git a/experiments/generic/pod-http-status-code/experiment.yaml b/experiments/generic/pod-http-status-code/experiment.yaml deleted file mode 100644 index d649d92..0000000 --- a/experiments/generic/pod-http-status-code/experiment.yaml +++ /dev/null @@ -1,162 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - It injects chaos inside the pod which modifies the status code of the response from the provided application server to desired status code provided by the user and reverts after a specified duration -kind: ChaosExperiment -metadata: - name: pod-http-status-code - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-http-status-code - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # modified status code for the http response - # if no value is provided, a random status code from the supported code list will selected - # if an invalid status code is provided, the experiment will fail - # if multiple comma separated values are provided, then a random value from the provided list will be selected - # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504] - - name: STATUS_CODE - value: '' - - # whether to modify the body as per the status code provided - - name: "MODIFY_RESPONSE_BODY" - value: "true" - - # provide the body string to overwrite the response body. This will be used only if MODIFY_RESPONSE_BODY is set to true - - name: RESPONSE_BODY - value: '' - - # provide the encoding type for the response body - # currently supported value are gzip, deflate - # if empty no encoding will be applied - - name: CONTENT_ENCODING - value: '' - - # provide the content type for the response body - - name: CONTENT_TYPE - value: 'text/plain' - - # port of the target service - - name: TARGET_SERVICE_PORT - value: "80" - - # port on which the proxy will listen - - name: PROXY_PORT - value: "20000" - - # toxicity is the probability of the request to be affected - # provide the percentage value in the range of 0-100 - # 0 means no request will be affected and 100 means all request will be affected - - name: TOXICITY - value: "100" - - # network interface on which the proxy will listen - - name: NETWORK_INTERFACE - value: "eth0" - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - # percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-http-status-code - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml b/experiments/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml deleted file mode 100644 index fad76f3..0000000 --- a/experiments/generic/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: pod-http-status-code - version: 0.1.0 - annotations: - categories: generic -spec: - displayName: pod-http-status-code - categoryDescription: > - pod-http-status-code contains chaos to disrupt http requests of kubernetes pods. This experiment can modify the status code of the response on the service targetted. - - Causes modification of status code of the HTTP request. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - "pods" - - "kubernetes" - - "generic" - - "exec" - - "http" - - "status code" - - "response code" - platforms: - - "Minikube" - maturity: alpha - maintainers: - - name: Akash Shrivastava - email: akash.shrivastava@harness.io - minKubeVersion: 1.12.0 - provider: - name: Harness - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-http-status-code - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-http-status-code/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-http-status-code/experiment.yaml \ No newline at end of file diff --git a/experiments/generic/pod-http-status-code/rbac-psp.yaml b/experiments/generic/pod-http-status-code/rbac-psp.yaml deleted file mode 100644 index 58d13cd..0000000 --- a/experiments/generic/pod-http-status-code/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-status-code-sa -subjects: -- kind: ServiceAccount - name: pod-http-status-code-sa - namespace: default diff --git a/experiments/generic/pod-http-status-code/rbac.yaml b/experiments/generic/pod-http-status-code/rbac.yaml deleted file mode 100644 index 8716759..0000000 --- a/experiments/generic/pod-http-status-code/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-http-status-code-sa - namespace: default - labels: - name: pod-http-status-code-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-http-status-code-sa -subjects: -- kind: ServiceAccount - name: pod-http-status-code-sa - namespace: default diff --git a/experiments/generic/pod-io-stress/engine.yaml b/experiments/generic/pod-io-stress/engine.yaml deleted file mode 100644 index 4b49e1d..0000000 --- a/experiments/generic/pod-io-stress/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-io-stress-sa - experiments: - - name: pod-io-stress - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '120' - - ## specify the size as percentage of free space on the file system - - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' - - ## Percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## provide the cluster runtime - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' diff --git a/experiments/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml b/experiments/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml deleted file mode 100644 index 8f7a010..0000000 --- a/experiments/generic/pod-io-stress/pod-io-stress.chartserviceversion.yaml +++ /dev/null @@ -1,50 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-09-13T10:28:08Z - name: pod-io-stress - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-io-stress - categoryDescription: | - This experiment causes disk stress on the application pod. The experiment aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes. - - Consumes the disk available by executing filesystem IO stress as available memory or by providing the value in GB - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - IO - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-io-stress - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-io-stress/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-io-stress/experiment.yaml diff --git a/experiments/generic/pod-io-stress/rbac-psp.yaml b/experiments/generic/pod-io-stress/rbac-psp.yaml deleted file mode 100644 index 755512a..0000000 --- a/experiments/generic/pod-io-stress/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-io-stress-sa -subjects: -- kind: ServiceAccount - name: pod-io-stress-sa - namespace: default diff --git a/experiments/generic/pod-io-stress/rbac.yaml b/experiments/generic/pod-io-stress/rbac.yaml deleted file mode 100644 index e80025d..0000000 --- a/experiments/generic/pod-io-stress/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-io-stress-sa - namespace: default - labels: - name: pod-io-stress-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-io-stress-sa -subjects: -- kind: ServiceAccount - name: pod-io-stress-sa - namespace: default diff --git a/experiments/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml b/experiments/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml deleted file mode 100644 index 2e37699..0000000 --- a/experiments/generic/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-04-10T10:28:08Z - name: pod-memory-hog-exec - version: 0.1.4 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-memory-hog-exec - categoryDescription: | - pod-memory-hog-exec contains chaos to consume Memory resouces of specified containers in Kubernetes pods. - - Consumes the memory specified by executing a dd command against special files /dev/zero(input) and /dev/null(output) - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - Exec - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-memory-hog-exec - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-memory-hog-exec/ - - name: Video - url: https://www.youtube.com/watch?v=HuAXg8W5Tzo - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-memory-hog-exec/experiment.yaml diff --git a/experiments/generic/pod-memory-hog-exec/rbac-psp.yaml b/experiments/generic/pod-memory-hog-exec/rbac-psp.yaml deleted file mode 100644 index eb39cec..0000000 --- a/experiments/generic/pod-memory-hog-exec/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-exec-sa - namespace: default diff --git a/experiments/generic/pod-memory-hog-exec/rbac.yaml b/experiments/generic/pod-memory-hog-exec/rbac.yaml deleted file mode 100644 index d4da0ca..0000000 --- a/experiments/generic/pod-memory-hog-exec/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-exec-sa - namespace: default - labels: - name: pod-memory-hog-exec-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-exec-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-exec-sa - namespace: default diff --git a/experiments/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml b/experiments/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml deleted file mode 100644 index 958f9e4..0000000 --- a/experiments/generic/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-06-16T10:28:08Z - name: pod-memory-hog - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-memory-hog - categoryDescription: | - Pod-Memory-Hog contains chaos to consume memory resouces of specified containers in Kubernetes pods. - - Causes memory resource consumption on specified application containers using cgroups and litmus nsutil that consume memory resources of the given target containers. - - It Can test the application's resilience to potential slowness/unavailability of some replicas due to high memory load - - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Memory - - Pod - - Stress - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - - OpenShift(OKD) - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-memory-hog - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-memory-hog/ - - name: Video - url: https://www.youtube.com/watch?v=HuAXg8W5Tzo - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-memory-hog/experiment.yaml diff --git a/experiments/generic/pod-memory-hog/rbac-psp.yaml b/experiments/generic/pod-memory-hog/rbac-psp.yaml deleted file mode 100644 index 3ad222d..0000000 --- a/experiments/generic/pod-memory-hog/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-sa - namespace: default diff --git a/experiments/generic/pod-memory-hog/rbac.yaml b/experiments/generic/pod-memory-hog/rbac.yaml deleted file mode 100644 index 61445c9..0000000 --- a/experiments/generic/pod-memory-hog/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-memory-hog-sa - namespace: default - labels: - name: pod-memory-hog-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-memory-hog-sa -subjects: -- kind: ServiceAccount - name: pod-memory-hog-sa - namespace: default diff --git a/experiments/generic/pod-network-corruption/engine.yaml b/experiments/generic/pod-network-corruption/engine.yaml deleted file mode 100644 index 63570ea..0000000 --- a/experiments/generic/pod-network-corruption/engine.yaml +++ /dev/null @@ -1,38 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-network-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-corruption-sa - experiments: - - name: pod-network-corruption - spec: - components: - env: - - 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 - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE - value: '100' #in PERCENTAGE - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/experiments/generic/pod-network-corruption/experiment.yaml b/experiments/generic/pod-network-corruption/experiment.yaml deleted file mode 100644 index 9285a54..0000000 --- a/experiments/generic/pod-network-corruption/experiment.yaml +++ /dev/null @@ -1,148 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Inject network packet corruption into application pod -kind: ChaosExperiment -metadata: - name: pod-network-corruption - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-corruption - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the comma seperated source ports - # chaos injection will be triggered for these source ports - - name: SOURCE_PORTS - value: '' - - # provide the comma seperated destination ports - # chaos injection will be triggered for these destination ports - - name: DESTINATION_PORTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-corruption - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml b/experiments/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml deleted file mode 100644 index c4991a9..0000000 --- a/experiments/generic/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-01-07T10:28:08Z - name: pod-network-corruption - version: 0.1.10 - 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 - - K8S - - Network - - Pod - - Corruption - platforms: - - GKE - - Packet(Kubeadm) - - Minikube - - EKS - - AKS - maturity: alpha - maintainers: - - name: LaumiH - email: laura-marie.henning@stud.h-da.de - minKubeVersion: 1.12.0 - provider: - name: Laura-Marie Henning - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-corruption - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-corruption/ - - name: Video - url: https://www.youtube.com/watch?v=kSiLrIaILvs - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-corruption/experiment.yaml diff --git a/experiments/generic/pod-network-corruption/rbac-psp.yaml b/experiments/generic/pod-network-corruption/rbac-psp.yaml deleted file mode 100644 index 685855b..0000000 --- a/experiments/generic/pod-network-corruption/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-corruption-sa -subjects: -- kind: ServiceAccount - name: pod-network-corruption-sa - namespace: default diff --git a/experiments/generic/pod-network-corruption/rbac.yaml b/experiments/generic/pod-network-corruption/rbac.yaml deleted file mode 100644 index f0319df..0000000 --- a/experiments/generic/pod-network-corruption/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-corruption-sa - namespace: default - labels: - name: pod-network-corruption-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-corruption-sa -subjects: -- kind: ServiceAccount - name: pod-network-corruption-sa - namespace: default diff --git a/experiments/generic/pod-network-duplication/engine.yaml b/experiments/generic/pod-network-duplication/engine.yaml deleted file mode 100644 index 7c1faed..0000000 --- a/experiments/generic/pod-network-duplication/engine.yaml +++ /dev/null @@ -1,39 +0,0 @@ -# chaosengine.yaml -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-network-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-duplication-sa - experiments: - - name: pod-network-duplication - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE - value: '100' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' diff --git a/experiments/generic/pod-network-duplication/experiment.yaml b/experiments/generic/pod-network-duplication/experiment.yaml deleted file mode 100644 index 8ca79e3..0000000 --- a/experiments/generic/pod-network-duplication/experiment.yaml +++ /dev/null @@ -1,145 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet duplication on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-duplication - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-duplication - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: RAMP_TIME - value: '' - - - name: TARGET_CONTAINER - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE - value: '100' # in percentage - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the comma seperated source ports - # chaos injection will be triggered for these source ports - - name: SOURCE_PORTS - value: '' - - # provide the comma seperated destination ports - # chaos injection will be triggered for these destination ports - - name: DESTINATION_PORTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-duplication - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml b/experiments/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml deleted file mode 100644 index cec3785..0000000 --- a/experiments/generic/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-07-01T10:28:08Z - name: pod-network-duplication - version: 0.1.2 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-duplication - categoryDescription: | - Pod-network-duplication contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject percentage packet duplication on the app replica pods. - - Causes lossy access to application replica by injecting packet duplication 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 - - K8S - - Network - - Pod - - Duplication - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: Udit Gaurav - email: udit.gaurav@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-duplication - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-duplication/ - - name: Video - url: - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-duplication/experiment.yaml diff --git a/experiments/generic/pod-network-duplication/rbac-psp.yaml b/experiments/generic/pod-network-duplication/rbac-psp.yaml deleted file mode 100644 index 01acf1a..0000000 --- a/experiments/generic/pod-network-duplication/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-duplication-sa -subjects: -- kind: ServiceAccount - name: pod-network-duplication-sa - namespace: default diff --git a/experiments/generic/pod-network-duplication/rbac.yaml b/experiments/generic/pod-network-duplication/rbac.yaml deleted file mode 100644 index d225750..0000000 --- a/experiments/generic/pod-network-duplication/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-duplication-sa - namespace: default - labels: - name: pod-network-duplication-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-duplication-sa -subjects: -- kind: ServiceAccount - name: pod-network-duplication-sa - namespace: default diff --git a/experiments/generic/pod-network-latency/experiment.yaml b/experiments/generic/pod-network-latency/experiment.yaml deleted file mode 100644 index 4b62332..0000000 --- a/experiments/generic/pod-network-latency/experiment.yaml +++ /dev/null @@ -1,151 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network latency on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-latency - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-latency - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - - name: NETWORK_INTERFACE - value: 'eth0' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_LATENCY - value: '2000' #in ms - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # Time period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: JITTER - value: '0' - - # lib can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the comma seperated source ports - # chaos injection will be triggered for these source ports - - name: SOURCE_PORTS - value: '' - - # provide the comma seperated destination ports - # chaos injection will be triggered for these destination ports - - name: DESTINATION_PORTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-latency - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml b/experiments/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml deleted file mode 100644 index 8e40c7a..0000000 --- a/experiments/generic/pod-network-latency/pod-network-latency.chartserviceversion.yaml +++ /dev/null @@ -1,49 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-11T10:28:08Z - name: pod-network-latency - version: 0.1.13 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-latency - categoryDescription: | - Pod-network-latency contains chaos to disrupt network connectivity of kubernetes pods. Experiments can inject random network delays on the app replica pods. - - Causes flaky access to application replica by injecting network delay using pumba. - - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. - keywords: - - Kubernetes - - K8S - - Network - - Pod - - Latency - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-latency - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-latency/ - - name: Video - url: https://www.youtube.com/watch?v=QsQZyXVCcCw - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-latency/experiment.yaml diff --git a/experiments/generic/pod-network-latency/rbac-psp.yaml b/experiments/generic/pod-network-latency/rbac-psp.yaml deleted file mode 100644 index ee147c7..0000000 --- a/experiments/generic/pod-network-latency/rbac-psp.yaml +++ /dev/null @@ -1,85 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-latency-sa -subjects: -- kind: ServiceAccount - name: pod-network-latency-sa - namespace: default diff --git a/experiments/generic/pod-network-latency/rbac.yaml b/experiments/generic/pod-network-latency/rbac.yaml deleted file mode 100644 index 4b65e6b..0000000 --- a/experiments/generic/pod-network-latency/rbac.yaml +++ /dev/null @@ -1,80 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-latency-sa - namespace: default - labels: - name: pod-network-latency-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-latency-sa -subjects: -- kind: ServiceAccount - name: pod-network-latency-sa - namespace: default diff --git a/experiments/generic/pod-network-loss/engine.yaml b/experiments/generic/pod-network-loss/engine.yaml deleted file mode 100644 index 96599ae..0000000 --- a/experiments/generic/pod-network-loss/engine.yaml +++ /dev/null @@ -1,40 +0,0 @@ -# chaosengine.yaml -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-network-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-loss-sa - experiments: - - name: pod-network-loss - spec: - components: - env: - - 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 - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/experiments/generic/pod-network-loss/experiment.yaml b/experiments/generic/pod-network-loss/experiment.yaml deleted file mode 100644 index 1a3da51..0000000 --- a/experiments/generic/pod-network-loss/experiment.yaml +++ /dev/null @@ -1,148 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-loss - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-loss - command: - - /bin/bash - env: - - - name: TARGET_CONTAINER - value: '' - - # provide lib image - - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' - - - name: NETWORK_INTERFACE - value: 'eth0' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' #in PERCENTAGE - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # it can be litmus or pumba - - name: LIB - value: 'litmus' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - - name: TARGET_PODS - value: '' - - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' - - # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only - - name: CONTAINER_RUNTIME - value: 'containerd' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide the comma seperated source ports - # chaos injection will be triggered for these source ports - - name: SOURCE_PORTS - value: '' - - # provide the comma seperated destination ports - # chaos injection will be triggered for these destination ports - - name: DESTINATION_PORTS - value: '' - - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - - labels: - name: pod-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml b/experiments/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml deleted file mode 100644 index 71ae971..0000000 --- a/experiments/generic/pod-network-loss/pod-network-loss.chartserviceversion.yaml +++ /dev/null @@ -1,48 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-11T10:28:08Z - name: pod-network-loss - version: 0.1.12 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-loss - categoryDescription: | - Pod-network-loss contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject percentage packet loss on the app replica pods. - - Causes loss of access to application replica by injecting packet loss 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 - - K8S - - Network - - Pod - - Loss - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - maturity: alpha - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-loss - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-loss/ - - name: Video - url: https://www.youtube.com/watch?v=jqvYy-nWc_I - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-loss/experiment.yaml diff --git a/experiments/generic/pod-network-loss/rbac-psp.yaml b/experiments/generic/pod-network-loss/rbac-psp.yaml deleted file mode 100644 index d3af1b8..0000000 --- a/experiments/generic/pod-network-loss/rbac-psp.yaml +++ /dev/null @@ -1,84 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-loss-sa -subjects: -- kind: ServiceAccount - name: pod-network-loss-sa - namespace: default diff --git a/experiments/generic/pod-network-loss/rbac.yaml b/experiments/generic/pod-network-loss/rbac.yaml deleted file mode 100644 index caa0918..0000000 --- a/experiments/generic/pod-network-loss/rbac.yaml +++ /dev/null @@ -1,79 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: ["apps.openshift.io"] - resources: ["deploymentconfigs"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) - - apiGroups: [""] - resources: ["replicationcontrollers"] - verbs: ["get","list"] - # deriving the parent/owner details of the pod(if parent is argo-rollouts) - - apiGroups: ["argoproj.io"] - resources: ["rollouts"] - verbs: ["list","get"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-loss-sa - namespace: default - labels: - name: pod-network-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-loss-sa -subjects: -- kind: ServiceAccount - name: pod-network-loss-sa - namespace: default diff --git a/experiments/generic/pod-network-partition/engine.yaml b/experiments/generic/pod-network-partition/engine.yaml deleted file mode 100644 index ef656e1..0000000 --- a/experiments/generic/pod-network-partition/engine.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-network-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-partition-sa - experiments: - - name: pod-network-partition - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds diff --git a/experiments/generic/pod-network-partition/experiment.yaml b/experiments/generic/pod-network-partition/experiment.yaml deleted file mode 100644 index 7c2cde2..0000000 --- a/experiments/generic/pod-network-partition/experiment.yaml +++ /dev/null @@ -1,100 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Injects 100% network packet loss on pods belonging to an app deployment -kind: ChaosExperiment -metadata: - name: pod-network-partition - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-network-partition - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - # ime period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # it should be litmus - - name: LIB - value: 'litmus' - - # provide the destination ips - # chaos injection will be triggered for these destination ips - - name: DESTINATION_IPS - value: '' - - # provide the destination hosts - # chaos injection will be triggered for these destination hosts - - name: DESTINATION_HOSTS - value: '' - - # provide network policy type - # support ingress, egress, all values - - name: POLICY_TYPES - value: 'all' - - # provide labels of the destination pods - - name: POD_SELECTOR - value: '' - - # provide labels the destination namespaces - - name: NAMESPACE_SELECTOR - value: '' - - # provide comma separated ports - - name: PORTS - value: '' - - labels: - name: pod-network-partition - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml b/experiments/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml deleted file mode 100644 index 89b3957..0000000 --- a/experiments/generic/pod-network-partition/pod-network-partition.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-08-25T10:28:08Z - name: pod-network-partition - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: pod-network-partition - categoryDescription: | - pod-network-partition contains chaos to disrupt network connectivity to kubernetes pods. Experiments can inject complete egress/ingress network loss based on label and namespace selectors. - - The application pod should be healthy once chaos is stopped. Service-requests should be served (say, via alternate replicas) despite chaos. - keywords: - - Kubernetes - - K8S - - Pod - - Network - - Partition - platforms: - - Minikube - - Packet(Kubeadm) - maturity: alpha - maintainers: - - name: ispeakc0de - email: shubham@chaosnative.com - minKubeVersion: 1.12.0 - provider: - name: ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/pod-network-partition - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/pod-network-partition/ - icon: - - base64data: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/pod-network-partition/experiment.yaml diff --git a/experiments/generic/pod-network-partition/rbac-psp.yaml b/experiments/generic/pod-network-partition/rbac-psp.yaml deleted file mode 100644 index 9335123..0000000 --- a/experiments/generic/pod-network-partition/rbac-psp.yaml +++ /dev/null @@ -1,72 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # use litmus psp - - apiGroups: ["policy"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: ["litmus"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-partition-sa -subjects: -- kind: ServiceAccount - name: pod-network-partition-sa - namespace: default diff --git a/experiments/generic/pod-network-partition/rbac.yaml b/experiments/generic/pod-network-partition/rbac.yaml deleted file mode 100644 index e2a0ae7..0000000 --- a/experiments/generic/pod-network-partition/rbac.yaml +++ /dev/null @@ -1,67 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # performs CRUD operations on the network policies - - apiGroups: ["networking.k8s.io"] - resources: ["networkpolicies"] - verbs: ["create","delete","list","get"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: pod-network-partition-sa - namespace: default - labels: - name: pod-network-partition-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: pod-network-partition-sa -subjects: -- kind: ServiceAccount - name: pod-network-partition-sa - namespace: default diff --git a/scenarios/icons/bank-of-anthos.png b/experiments/icons/bank-of-anthos.png similarity index 100% rename from scenarios/icons/bank-of-anthos.png rename to experiments/icons/bank-of-anthos.png diff --git a/scenarios/icons/podtato-head.png b/experiments/icons/podtato-head.png similarity index 100% rename from scenarios/icons/podtato-head.png rename to experiments/icons/podtato-head.png diff --git a/scenarios/icons/sock-shop-promProbe.png b/experiments/icons/sock-shop-promProbe.png similarity index 100% rename from scenarios/icons/sock-shop-promProbe.png rename to experiments/icons/sock-shop-promProbe.png diff --git a/scenarios/icons/sock-shop.png b/experiments/icons/sock-shop.png similarity index 100% rename from scenarios/icons/sock-shop.png rename to experiments/icons/sock-shop.png diff --git a/experiments/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml b/experiments/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml deleted file mode 100755 index 1632138..0000000 --- a/experiments/kube-aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: aws-az-chaos - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: aws-az-chaos - categoryDescription: > - Execute aws-az chaos to detach the target zones from the load balancer - keywords: - - "zone" - - "load-balancer" - - "aws" - platforms: - - "AWS" - maturity: alpha - maintainers: - - name: oumkale - email: imkaleoum@gmail.com - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-python/tree/master/experiments/aws_az - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/aws-az-chaos/ - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/aws-az-chaos/experiment.yaml diff --git a/experiments/kube-aws/aws-az-chaos/engine.yaml b/experiments/kube-aws/aws-az-chaos/engine.yaml deleted file mode 100755 index a7afbbc..0000000 --- a/experiments/kube-aws/aws-az-chaos/engine.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: aws-az-chaos -spec: - # It can be active/stop - engineState: 'active' - chaosServiceAccount: aws-az-chaos-sa - experiments: - - name: aws-az-chaos - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - name: CHAOS_INTERVAL - value: '30' - #LOAD_BALANCER_NAME name of the load balancer - - name: LOAD_BALANCER_NAME - value: "" - #LOAD_BALANCER_ZONES can be multiple, provide it by comma separated - - name: LOAD_BALANCER_ZONES - value: "" - - name: LOAD_BALANCERNAME_ARN - value: "na" - - name: AWS_SHARED_CREDENTIALS_FILE - value: "/tmp/cloud_config.yml" diff --git a/experiments/kube-aws/aws-az-chaos/experiment.yaml b/experiments/kube-aws/aws-az-chaos/experiment.yaml deleted file mode 100755 index 921723b..0000000 --- a/experiments/kube-aws/aws-az-chaos/experiment.yaml +++ /dev/null @@ -1,76 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute aws-az chaos to detach the target zones from the load balancer -kind: ChaosExperiment -metadata: - name: aws-az-chaos - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/py-runner:latest" - imagePullPolicy: Always - args: - - -c - - python3 -u experiment -name aws-az-chaos - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - name: CHAOS_INTERVAL - value: '30' - - name: LIB - value: 'litmus' - - name: LOAD_BALANCER_NAME - value: '' - - name: LOAD_BALANCER_ZONES - value: '' - - name: LOAD_BALANCERNAME_ARN - value: 'na' - - name: AWS_SHARED_CREDENTIALS_FILE - value: "/tmp/cloud_config.yml" - - name: RAMP_TIME - value: '' - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/kube-aws/aws-az-chaos/rbac.yaml b/experiments/kube-aws/aws-az-chaos/rbac.yaml deleted file mode 100755 index 3d2284c..0000000 --- a/experiments/kube-aws/aws-az-chaos/rbac.yaml +++ /dev/null @@ -1,60 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1beta1 -kind: Role -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus -rules: -# Create and monitor the experiment & helper pods -- apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] -# Performs CRUD operations on the events inside chaosengine and chaosresult -- apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] -# Fetch configmaps & secrets details and mount it to the experiment pod (if specified) -- apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] -# Track and get the runner, experiment, and helper pods log -- apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] -# for configuring and monitor the experiment job by the chaos-runner pod -- apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] -# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow -- apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1beta1 -kind: RoleBinding -metadata: - name: aws-az-chaos-sa - namespace: default - labels: - name: aws-az-chaos-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: aws-az-chaos-sa -subjects: -- kind: ServiceAccount - name: aws-az-chaos-sa - namespace: default \ No newline at end of file diff --git a/experiments/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml b/experiments/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml deleted file mode 100644 index 9946442..0000000 --- a/experiments/kube-aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-10-28T10:28:08Z - name: ebs-loss-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: ebs-loss-by-id - categoryDescription: | - EBS Loss By ID contains chaos to disrupt state of infra resources. The experiment can induce ebs volume loss against specified application for the give EBS Volume(s). - - Causes ebs volume loss from node or ec2 instance for a certain chaos interval from total chaos duration. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod - keywords: - - EBS - - Volume - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ebs-loss-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ebs-loss-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ebs-loss-by-id/experiment.yaml diff --git a/experiments/kube-aws/ebs-loss-by-id/engine.yaml b/experiments/kube-aws/ebs-loss-by-id/engine.yaml deleted file mode 100644 index cdb3010..0000000 --- a/experiments/kube-aws/ebs-loss-by-id/engine.yaml +++ /dev/null @@ -1,28 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: ebs-loss-by-id-sa - experiments: - - name: ebs-loss-by-id - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - # set target ebs volume ID - - name: EBS_VOLUME_ID - value: '' - - # provide the region name of the instance - - name: REGION - value: '' diff --git a/experiments/kube-aws/ebs-loss-by-id/experiment.yaml b/experiments/kube-aws/ebs-loss-by-id/experiment.yaml deleted file mode 100644 index 143caf4..0000000 --- a/experiments/kube-aws/ebs-loss-by-id/experiment.yaml +++ /dev/null @@ -1,88 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-id - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/kube-aws/ebs-loss-by-id/rbac.yaml b/experiments/kube-aws/ebs-loss-by-id/rbac.yaml deleted file mode 100644 index 52a1c57..0000000 --- a/experiments/kube-aws/ebs-loss-by-id/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ebs-loss-by-id-sa - namespace: default - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ebs-loss-by-id-sa - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ebs-loss-by-id-sa - labels: - name: ebs-loss-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ebs-loss-by-id-sa -subjects: -- kind: ServiceAccount - name: ebs-loss-by-id-sa - namespace: default diff --git a/experiments/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml b/experiments/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml deleted file mode 100644 index 95eca97..0000000 --- a/experiments/kube-aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-15T10:28:08Z - name: ebs-loss-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: ebs-loss-by-tag - categoryDescription: | - EBS Loss By Tag contains chaos to disrupt state of infra resources. The experiment can induce ebs volume loss against specified application for given volume tag. - - Causes ebs volume loss by tag from node or ec2 instance for certain chaos interval from total chaos duration. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod - keywords: - - EBS - - Volume - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ebs-loss-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ebs-loss-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ebs-loss-by-tag/experiment.yaml diff --git a/experiments/kube-aws/ebs-loss-by-tag/engine.yaml b/experiments/kube-aws/ebs-loss-by-tag/engine.yaml deleted file mode 100644 index a9212ef..0000000 --- a/experiments/kube-aws/ebs-loss-by-tag/engine.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: ebs-loss-by-tag-sa - experiments: - - name: ebs-loss-by-tag - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # provide EBS volume tag attached to the given instance - # it'll be in form of key:value (ex: 'team:devops') - - name: EBS_VOLUME_TAG - value: '' - - # provide the region name of the instance - - name: REGION - value: '' - - - name: VOLUME_AFFECTED_PERC - value: '' - \ No newline at end of file diff --git a/experiments/kube-aws/ebs-loss-by-tag/experiment.yaml b/experiments/kube-aws/ebs-loss-by-tag/experiment.yaml deleted file mode 100644 index 54a4710..0000000 --- a/experiments/kube-aws/ebs-loss-by-tag/experiment.yaml +++ /dev/null @@ -1,90 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-tag - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_TAG - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - - name: VOLUME_AFFECTED_PERC - value: '' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/kube-aws/ebs-loss-by-tag/rbac.yaml b/experiments/kube-aws/ebs-loss-by-tag/rbac.yaml deleted file mode 100644 index 52ad320..0000000 --- a/experiments/kube-aws/ebs-loss-by-tag/rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ebs-loss-by-tag-sa - namespace: default - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ebs-loss-by-tag-sa - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ebs-loss-by-tag-sa - labels: - name: ebs-loss-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ebs-loss-by-tag-sa -subjects: -- kind: ServiceAccount - name: ebs-loss-by-tag-sa - namespace: default diff --git a/experiments/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml b/experiments/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml deleted file mode 100644 index b8de45f..0000000 --- a/experiments/kube-aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-10-28T10:28:08Z - name: ec2-terminate-by-id - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: Mayadata - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: ec2-terminate-by-id - categoryDescription: | - This experiment causes termination of an EC2 instance for a certain chaos duration. - - Causes termination of an EC2 instance provided by instance ID before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the ec2 instance. - keywords: - - EC2 - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ec2-terminate-by-id - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ec2-terminate-by-id/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ec2-terminate-by-id/experiment.yaml diff --git a/experiments/kube-aws/ec2-terminate-by-id/experiment.yaml b/experiments/kube-aws/ec2-terminate-by-id/experiment.yaml deleted file mode 100644 index 003f18d..0000000 --- a/experiments/kube-aws/ec2-terminate-by-id/experiment.yaml +++ /dev/null @@ -1,98 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by ID. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-id - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/kube-aws/ec2-terminate-by-id/rbac.yaml b/experiments/kube-aws/ec2-terminate-by-id/rbac.yaml deleted file mode 100644 index 0f7fb1c..0000000 --- a/experiments/kube-aws/ec2-terminate-by-id/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ec2-terminate-by-id-sa - namespace: default - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ec2-terminate-by-id-sa - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ec2-terminate-by-id-sa - labels: - name: ec2-terminate-by-id-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ec2-terminate-by-id-sa -subjects: -- kind: ServiceAccount - name: ec2-terminate-by-id-sa - namespace: default \ No newline at end of file diff --git a/experiments/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml b/experiments/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml deleted file mode 100644 index 1caf610..0000000 --- a/experiments/kube-aws/ec2-terminate-by-tag/ec2-terminate-by-tag.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-15T10:28:08Z - name: ec2-terminate-by-tag - version: 0.1.0 - annotations: - categories: Kubernetes - vendor: Mayadata - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: ec2-terminate-by-tag - categoryDescription: | - This experiment causes termination of an EC2 instance for a certain chaos duration. - - Causes termination of an EC2 instance using instance tags before bringing it back to running state after the specified chaos duration. - - It helps to check the performance of the application on the ec2 instance. - keywords: - - EC2 - - AWS - platforms: - - AWS - maturity: alpha - chaosType: infra - maintainers: - - name: Udit Gaurav - email: uditgaurav@mayadata.io - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws/ec2-terminate-by-tag - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/aws/ec2-terminate-by-tag/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/ec2-terminate-by-tag/experiment.yaml diff --git a/experiments/kube-aws/ec2-terminate-by-tag/engine.yaml b/experiments/kube-aws/ec2-terminate-by-tag/engine.yaml deleted file mode 100644 index 6ed309d..0000000 --- a/experiments/kube-aws/ec2-terminate-by-tag/engine.yaml +++ /dev/null @@ -1,37 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nginx-chaos - namespace: default -spec: - engineState: 'active' - chaosServiceAccount: ec2-terminate-by-tag-sa - experiments: - - name: ec2-terminate-by-tag - spec: - components: - env: - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set interval duration (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - # Instance Tag of the target ec2 instances - # ex: team:devops (key:value) - - name: INSTANCE_TAG - value: '' - - # provide the region name of the instance - - name: REGION - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - # Target the percentage of instance filtered from tag - - name: INSTANCE_AFFECTED_PERC - value: '' diff --git a/experiments/kube-aws/ec2-terminate-by-tag/experiment.yaml b/experiments/kube-aws/ec2-terminate-by-tag/experiment.yaml deleted file mode 100644 index 4356893..0000000 --- a/experiments/kube-aws/ec2-terminate-by-tag/experiment.yaml +++ /dev/null @@ -1,100 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by tag. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-tag - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: INSTANCE_TAG - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - - name: REGION - value: '' - - # Target the percentage of instance filtered from tag - - name: INSTANCE_AFFECTED_PERC - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/kube-aws/ec2-terminate-by-tag/rbac.yaml b/experiments/kube-aws/ec2-terminate-by-tag/rbac.yaml deleted file mode 100644 index e03101d..0000000 --- a/experiments/kube-aws/ec2-terminate-by-tag/rbac.yaml +++ /dev/null @@ -1,66 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: ec2-terminate-by-tag-sa - namespace: default - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: ec2-terminate-by-tag-sa - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: ec2-terminate-by-tag-sa - labels: - name: ec2-terminate-by-tag-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: ec2-terminate-by-tag-sa -subjects: -- kind: ServiceAccount - name: ec2-terminate-by-tag-sa - namespace: default \ No newline at end of file diff --git a/experiments/kube-aws/experiments.yaml b/experiments/kube-aws/experiments.yaml deleted file mode 100644 index 22918b0..0000000 --- a/experiments/kube-aws/experiments.yaml +++ /dev/null @@ -1,462 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by ID. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-id - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - # Instance ID of the target ec2 instance - # Multiple IDs can also be provided as comma separated values ex: id1,id2 - - name: EC2_INSTANCE_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ec2-terminate-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stopping an EC2 instance identified by tag. -kind: ChaosExperiment -metadata: - name: ec2-terminate-by-tag - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - # for experiment to perform node status checks - - apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ec2-terminate-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: INSTANCE_TAG - value: '' - - # enable it if the target instance is a part of self-managed nodegroup. - - name: MANAGED_NODEGROUP - value: 'disable' - - - name: REGION - value: '' - - # Target the percentage of instance filtered from tag - - name: INSTANCE_AFFECTED_PERC - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ec2-terminate-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Execute aws-az chaos to detach the target zones from the load balancer -kind: ChaosExperiment -metadata: - name: aws-az-chaos - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Namespaced - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/py-runner:latest" - imagePullPolicy: Always - args: - - -c - - python3 -u experiment -name aws-az-chaos - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - name: CHAOS_INTERVAL - value: '30' - - name: LIB - value: 'litmus' - - name: LOAD_BALANCER_NAME - value: '' - - name: LOAD_BALANCER_ZONES - value: '' - - name: LOAD_BALANCERNAME_ARN - value: 'na' - - name: AWS_SHARED_CREDENTIALS_FILE - value: "/tmp/cloud_config.yml" - - name: RAMP_TIME - value: '' - labels: - name: aws-az-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-id - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-id - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_ID - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ebs-loss-by-id - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Detaching an ebs volume from ec2 instance. -kind: ChaosExperiment -metadata: - name: ebs-loss-by-tag - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name ebs-loss-by-tag - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '30' - - - name: RAMP_TIME - value: '' - - - name: EBS_VOLUME_TAG - value: '' - - - name: REGION - value: '' - - - name: SEQUENCE - value: 'parallel' - - - name: VOLUME_AFFECTED_PERC - value: '' - - # Provide the path of aws credentials mounted from secret - - name: AWS_SHARED_CREDENTIALS_FILE - value: '/tmp/cloud_config.yml' - - # provide the LIB - # only litmus supported - - name: LIB - value: 'litmus' - - labels: - name: ebs-loss-by-tag - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/experiments/kube-aws/icons/aws-az-chaos.png b/experiments/kube-aws/icons/aws-az-chaos.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/aws-az-chaos.png and /dev/null differ diff --git a/experiments/kube-aws/icons/ebs-loss-by-id.png b/experiments/kube-aws/icons/ebs-loss-by-id.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/ebs-loss-by-id.png and /dev/null differ diff --git a/experiments/kube-aws/icons/ebs-loss-by-tag.png b/experiments/kube-aws/icons/ebs-loss-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/ebs-loss-by-tag.png and /dev/null differ diff --git a/experiments/kube-aws/icons/ec2-terminate-by-id.png b/experiments/kube-aws/icons/ec2-terminate-by-id.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/ec2-terminate-by-id.png and /dev/null differ diff --git a/experiments/kube-aws/icons/ec2-terminate-by-tag.png b/experiments/kube-aws/icons/ec2-terminate-by-tag.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/ec2-terminate-by-tag.png and /dev/null differ diff --git a/experiments/kube-aws/icons/k8-aws-ec2-terminate.png b/experiments/kube-aws/icons/k8-aws-ec2-terminate.png deleted file mode 100644 index cb58737..0000000 Binary files a/experiments/kube-aws/icons/k8-aws-ec2-terminate.png and /dev/null differ diff --git a/experiments/kube-aws/icons/kube-aws.png b/experiments/kube-aws/icons/kube-aws.png deleted file mode 100644 index fd09e34..0000000 Binary files a/experiments/kube-aws/icons/kube-aws.png and /dev/null differ diff --git a/experiments/kube-aws/kube-aws.chartserviceversion.yaml b/experiments/kube-aws/kube-aws.chartserviceversion.yaml deleted file mode 100644 index b686a5a..0000000 --- a/experiments/kube-aws/kube-aws.chartserviceversion.yaml +++ /dev/null @@ -1,47 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-09-26T10:28:08Z - name: kube-aws - version: 0.1.16 - annotations: - categories: Kubernetes - chartDescription: Injects kube-aws kubernetes chaos -spec: - displayName: Kube AWS - categoryDescription: > - kube-aws contains chaos to disrupt state of aws resources running part of kubernetes cluster - experiments: - - name: ec2-terminate-by-id - description: "" - - name: ec2-terminate-by-tag - description: "" - - name: ebs-loss-by-id - description: "" - - name: ebs-loss-by-tag - description: "" - - name: aws-az-chaos - description: "" - keywords: - - AWS - - EC2 - - EBS - - AZ - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - - name: oumkale - email: imkaleoum@gmail.com - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/kube-aws - - name: Source Code - url: https://github.com/litmuschaos/litmus-python/tree/master/experiments/aws_az - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - icon: - - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/icons/kube-aws.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/kube-aws/experiments.yaml diff --git a/experiments/kube-aws/kube-aws.package.yaml b/experiments/kube-aws/kube-aws.package.yaml deleted file mode 100644 index db03f2e..0000000 --- a/experiments/kube-aws/kube-aws.package.yaml +++ /dev/null @@ -1,17 +0,0 @@ -packageName: kube-aws -experiments: - - name: ec2-terminate-by-id - CSV: ec2-terminate-by-id.chartserviceversion.yaml - desc: "ec2-terminate-by-id" - - name: ec2-terminate-by-tag - CSV: ec2-terminate-by-tag.chartserviceversion.yaml - desc: "ec2-terminate-by-tag" - - name: ebs-loss-by-id - CSV: ebs-loss-by-id.chartserviceversion.yaml - desc: "ebs-loss-by-id" - - name: ebs-loss-by-tag - CSV: ebs-loss-by-tag.chartserviceversion.yaml - desc: "ebs-loss-by-tag" - - name: aws-az-chaos - CSV: aws-az-chaos.chartserviceversion.yaml - desc: "aws-az-chaos" diff --git a/experiments/kube-aws/rbac-admin.yaml b/experiments/kube-aws/rbac-admin.yaml deleted file mode 100644 index f386c6c..0000000 --- a/experiments/kube-aws/rbac-admin.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: chaos-admin - labels: - name: chaos-admin ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: chaos-admin - labels: - name: chaos-admin -rules: -- apiGroups: ["","apps","batch","extensions","litmuschaos.io","openebs.io","storage.k8s.io"] - resources: ["chaosengines","chaosexperiments","chaosresults","configmaps","cstorpools","cstorvolumereplicas","events","jobs","persistentvolumeclaims","persistentvolumes","pods","pods/exec","pods/log","secrets","storageclasses","chaosengines","chaosexperiments","chaosresults","configmaps","cstorpools","cstorvolumereplicas","daemonsets","deployments","events","jobs","persistentvolumeclaims","persistentvolumes","pods","pods/eviction","pods/exec","pods/log","replicasets","secrets","services","statefulsets","storageclasses"] - verbs: ["create","delete","get","list","patch","update"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list","patch"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: chaos-admin - labels: - name: chaos-admin -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: chaos-admin -subjects: -- kind: ServiceAccount - name: chaos-admin - namespace: default diff --git a/experiments/longhorn/experiments.yaml b/experiments/longhorn/experiments.yaml deleted file mode 100644 index e69de29..0000000 diff --git a/experiments/longhorn/icons/longhorn.png b/experiments/longhorn/icons/longhorn.png deleted file mode 100644 index d4fd9c1..0000000 Binary files a/experiments/longhorn/icons/longhorn.png and /dev/null differ diff --git a/experiments/longhorn/longhorn.chartserviceversion.yaml b/experiments/longhorn/longhorn.chartserviceversion.yaml deleted file mode 100644 index c1ae23b..0000000 --- a/experiments/longhorn/longhorn.chartserviceversion.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-17T10:28:08Z - name: longhorn - version: 0.0.2 - annotations: - categories: longhorn - chartDescription: Injects chaos on longhorn components -spec: - displayName: Longhorn Chaos - categoryDescription: > - Longhorn is a distributed block storage system for Kubernetes - experiments: - keywords: - - Kubernetes - - Longhorn - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: Longhorn - url: https://rancher.com/project-longhorn-now-available-kubernetes/ - - name: Documentation - url: https://docs.rancher.cn/longhorn/#current-status - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/longhorn/experiments.yaml diff --git a/experiments/longhorn/longhorn.package.yaml b/experiments/longhorn/longhorn.package.yaml deleted file mode 100644 index e37fbdb..0000000 --- a/experiments/longhorn/longhorn.package.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packageName: longhorn -experiments: \ No newline at end of file diff --git a/experiments/mongodb/experiments.yaml b/experiments/mongodb/experiments.yaml deleted file mode 100644 index e69de29..0000000 diff --git a/experiments/mongodb/icons/mongodb.png b/experiments/mongodb/icons/mongodb.png deleted file mode 100644 index ab6378f..0000000 Binary files a/experiments/mongodb/icons/mongodb.png and /dev/null differ diff --git a/experiments/mongodb/mongodb.chartserviceversion.yaml b/experiments/mongodb/mongodb.chartserviceversion.yaml deleted file mode 100644 index 2849aab..0000000 --- a/experiments/mongodb/mongodb.chartserviceversion.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-17T10:28:08Z - name: mongodb - version: 0.0.2 - annotations: - categories: mongodb - chartDescription: Injects chaos on mongodb components -spec: - displayName: MongoDB Chaos - categoryDescription: > - MongoDB is a general purpose, document-based, distributed database built for modern application developers and for the cloud era. - experiments: - keywords: - - Kubernetes - - MongoDB - maintainers: - - name: Sanjay1611 - email: sanjay.nathani@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: MongoDB Website - url: https://www.mongodb.com/ - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/mongodb/experiments.yaml diff --git a/experiments/mongodb/mongodb.package.yaml b/experiments/mongodb/mongodb.package.yaml deleted file mode 100644 index 1ad30e8..0000000 --- a/experiments/mongodb/mongodb.package.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packageName: mongodb -experiments: diff --git a/experiments/mysql/experiments.yaml b/experiments/mysql/experiments.yaml deleted file mode 100644 index e69de29..0000000 diff --git a/experiments/mysql/icons/mysql.png b/experiments/mysql/icons/mysql.png deleted file mode 100644 index ee7382c..0000000 Binary files a/experiments/mysql/icons/mysql.png and /dev/null differ diff --git a/experiments/mysql/mysql.chartserviceversion.yaml b/experiments/mysql/mysql.chartserviceversion.yaml deleted file mode 100644 index 540382a..0000000 --- a/experiments/mysql/mysql.chartserviceversion.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-17T10:28:08Z - name: mysql - version: 0.0.2 - annotations: - categories: mysql - chartDescription: Injects chaos on mysql components -spec: - displayName: MySQL Chaos - categoryDescription: > - MySQL is an open-source relational database management system. - experiments: - keywords: - - Kubernetes - - MySQL - maintainers: - - name: atulabhi - email: atul.abhishek@openebs.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: mysql Website - url: https://www.mysql.com/ - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/mysql/experiments.yaml diff --git a/experiments/mysql/mysql.package.yaml b/experiments/mysql/mysql.package.yaml deleted file mode 100644 index d844b9a..0000000 --- a/experiments/mysql/mysql.package.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packageName: mysql -experiments: diff --git a/workflows/namespaced-scope-chaos/workflow.yaml b/experiments/namespaced-scope-chaos/experiment.yaml similarity index 94% rename from workflows/namespaced-scope-chaos/workflow.yaml rename to experiments/namespaced-scope-chaos/experiment.yaml index 129273c..73273d9 100644 --- a/workflows/namespaced-scope-chaos/workflow.yaml +++ b/experiments/namespaced-scope-chaos/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-hello-world-pod-delete- + name: argowf-chaos-hello-world-pod-delete- labels: subject: "{{workflow.parameters.adminModeNamespace}}_hello-world" spec: @@ -17,17 +17,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-delete.yaml raw: data: | @@ -96,7 +96,7 @@ spec: - name: CHAOS_INTERVAL value: '5' - + labels: name: pod-delete container: @@ -161,7 +161,7 @@ spec: - -file=/tmp/chaosengine.yaml - -saveName=/tmp/engine-name - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest resources: diff --git a/workflows/namespaced-scope-chaos/workflow_cron.yaml b/experiments/namespaced-scope-chaos/experiment_cron.yaml similarity index 95% rename from workflows/namespaced-scope-chaos/workflow_cron.yaml rename to experiments/namespaced-scope-chaos/experiment_cron.yaml index 1f44c80..5f4fde0 100644 --- a/workflows/namespaced-scope-chaos/workflow_cron.yaml +++ b/experiments/namespaced-scope-chaos/experiment_cron.yaml @@ -21,17 +21,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-delete.yaml raw: data: | @@ -100,7 +100,7 @@ spec: - name: CHAOS_INTERVAL value: '5' - + labels: name: pod-delete container: @@ -165,7 +165,7 @@ spec: - -file=/tmp/chaosengine.yaml - -saveName=/tmp/engine-name - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest resources: diff --git a/experiments/namespaced-scope-chaos/namespaced-scope-chaos.chartserviceversion.yaml b/experiments/namespaced-scope-chaos/namespaced-scope-chaos.chartserviceversion.yaml new file mode 100644 index 0000000..9dc9778 --- /dev/null +++ b/experiments/namespaced-scope-chaos/namespaced-scope-chaos.chartserviceversion.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: namespaced-scope-chaos + version: 0.1.0 + annotations: + categories: namespaced-scope-chaos + chartDescription: Performs the pod delete chaos experiment in namespaced scope mode +spec: + displayName: Namespaced Scope Chaos + categoryDescription: > + Performs the pod delete chaos experiment in namespaced scope mode + faults: + - name: pod-delete + description: Deletes a pod belonging to a deployment/statefulset/daemonset + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + icon: + - url: + mediatype: "" diff --git a/workflows/node-cpu-hog/workflow.yaml b/experiments/node-cpu-hog/experiment.yaml similarity index 91% rename from workflows/node-cpu-hog/workflow.yaml rename to experiments/node-cpu-hog/experiment.yaml index 53cfa75..4a63807 100644 --- a/workflows/node-cpu-hog/workflow.yaml +++ b/experiments/node-cpu-hog/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-node-cpu-hog- + name: argowf-chaos-node-cpu-hog- namespace: litmus labels: subject: "{{workflow.parameters.context}}" @@ -16,21 +16,21 @@ spec: - name: adminModeNamespace value: "litmus" - name: context - value: "node-cpu-hog_infra" + value: "node-cpu-hog_infra" templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/node-cpu-hog.yaml raw: data: | @@ -137,9 +137,9 @@ spec: value: '60' # in seconds container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/node-cpu-hog/workflow_cron.yaml b/experiments/node-cpu-hog/experiment_cron.yaml similarity index 92% rename from workflows/node-cpu-hog/workflow_cron.yaml rename to experiments/node-cpu-hog/experiment_cron.yaml index a626185..d8b574b 100644 --- a/workflows/node-cpu-hog/workflow_cron.yaml +++ b/experiments/node-cpu-hog/experiment_cron.yaml @@ -20,21 +20,21 @@ spec: - name: adminModeNamespace value: "litmus" - name: context - value: "node-cpu-hog_infra" + value: "node-cpu-hog_infra" templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/node-cpu-hog.yaml raw: data: | @@ -141,13 +141,13 @@ spec: value: '60' # in seconds container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] args: [ "kubectl delete chaosengine kube-proxy-node-cpu-hog-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] \ No newline at end of file + ] diff --git a/experiments/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml b/experiments/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml new file mode 100644 index 0000000..303180d --- /dev/null +++ b/experiments/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-cpu-hog + version: 0.1.0 + annotations: + categories: node-cpu-hog + chartDescription: Node CPU hog injects a CPU spike on a node where the application pod is scheduled. +spec: + displayName: Node CPU Hog + categoryDescription: > + Node CPU hog fault disrupts the state of Kubernetes resources. This fault injects a CPU spike on a node where the application pod is scheduled. + - CPU hog on a particular node where the application deployment is available. + - After test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. + faults: + - name: node-cpu-hog + description: Node CPU hog injects a CPU spike on a node where the application pod is scheduled. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/workflows/node-memory-hog/workflow.yaml b/experiments/node-memory-hog/experiment.yaml similarity index 91% rename from workflows/node-memory-hog/workflow.yaml rename to experiments/node-memory-hog/experiment.yaml index 8bb7db8..1003d46 100644 --- a/workflows/node-memory-hog/workflow.yaml +++ b/experiments/node-memory-hog/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-node-memory-hog- + name: argowf-chaos-node-memory-hog- namespace: litmus labels: subject: "{{workflow.parameters.context}}" @@ -16,21 +16,21 @@ spec: - name: adminModeNamespace value: "litmus" - name: context - value: "node-memory-hog_infra" + value: "node-memory-hog_infra" templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/node-memory-hog.yaml raw: data: | @@ -137,9 +137,9 @@ spec: value: '60' # in seconds container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/node-memory-hog/workflow_cron.yaml b/experiments/node-memory-hog/experiment_cron.yaml similarity index 92% rename from workflows/node-memory-hog/workflow_cron.yaml rename to experiments/node-memory-hog/experiment_cron.yaml index 9dfc80e..67ce99d 100644 --- a/workflows/node-memory-hog/workflow_cron.yaml +++ b/experiments/node-memory-hog/experiment_cron.yaml @@ -24,16 +24,16 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos - - name: install-experiment + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/node-memory-hog.yaml raw: data: | @@ -133,12 +133,12 @@ spec: value: '60' # in seconds container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - name: revert-chaos + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] args: [ "kubectl delete chaosengine kube-proxy-node-memory-hog-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] \ No newline at end of file + ] diff --git a/experiments/node-memory-hog/node-memory-hog.chartserviceversion.yaml b/experiments/node-memory-hog/node-memory-hog.chartserviceversion.yaml new file mode 100644 index 0000000..0003413 --- /dev/null +++ b/experiments/node-memory-hog/node-memory-hog.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-memory-hog + version: 0.1.0 + annotations: + categories: node-memory-hog + chartDescription: Node memory hog injects a memory spike on a node where the application pod is scheduled. +spec: + displayName: Node Memory Hog + categoryDescription: > + Node memory hog fault disrupts the state of Kubernetes resources. This fault injects a memory spike on a node where the application pod is scheduled. + - Memory hog on a particular node where the application deployment is available. + - After the test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. + faults: + - name: node-memory-hog + description: Node memory hog injects a memory spike on a node where the application pod is scheduled. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/experiments/openebs/experiments.yaml b/experiments/openebs/experiments.yaml deleted file mode 100644 index fa6f3c3..0000000 --- a/experiments/openebs/experiments.yaml +++ /dev/null @@ -1,1097 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network loss to target pod belonging to a OpenEBS PVC -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-network-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "events" - - "services" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-network-loss/openebs_target_network_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' # in percentage - - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-target-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-network-loss - # mountPath: /mnt - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill all openebs control plane pod and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-control-plane-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-control-plane-chaos -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "litmuschaos.io" - - "batch" - - "apps" - resources: - - "pods" - - "pods/log" - - "deployments" - - "events" - - "jobs" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-control-plane-chaos/openebs_control_plane_chaos_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - ## Period to wait before injection of chaos - - name: RAMP_TIME - value: '' - - - name: FORCE - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, powerfulseal - - name: LIB - value: 'litmus' - - labels: - name: openebs-control-plane-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network loss to pool pod belonging to a OpenEBS PVC -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-network-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "pods/log" - - "pods/exec" - - "events" - - "jobs" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumeclaims" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "cstorpools" - - "cstorvolumereplicas" - - "replicasets" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-network-loss/openebs_pool_network_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' # in percentage - - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network delay to pool pod belonging to a OpenEBS PVC - This experiment is using pumba lib for network chaos -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-network-delay -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "pods/exec" - - "jobs" - - "pods/log" - - "events" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "cstorpools" - - "cstorvolumereplicas" - - "replicasets" - verbs: - - "create" - - "get" - - "list" - - "patch" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-network-delay/openebs_pool_network_delay_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # in milliseconds - - name: NETWORK_DELAY - value: '60000' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the OpenEBS NFS provisioner container and check if pods consuming the NFS PVs continue to be available and volumes are writable (RWM mode) -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-nfs-provisioner-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-nfs-provisioner-kill -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - resources: - - "pods" - - "pods/exec" - - "pods/log" - - "deployments" - - "events" - - "jobs" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosexperiments" - - "chaosresults" - - "chaosengines" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-nfs-provisioner-kill/openebs_nfs_provisioner_kill_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - # NFS default container - - name: TARGET_CONTAINER - value: 'nfs-provisioner' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # It supports pumba and containerd - - name: LIB - value: 'pumba' - - # LIB_IMAGE can be - gaiaadm/pumba:0.6.5, gprasath/crictl:ci - # For pumba image use: gaiaadm/pumba:0.6.5 - # For containerd image use: gprasath/crictl:ci - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - labels: - name: openebs-nfs-provisioner-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - configmaps: - - name: openebs-nfs-provisioner-kill - mountPath: /mnt/ - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the cstor target/Jiva controller pod and check if gets created again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-pod-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "deployments" - - "jobs" - - "events" - - "pods" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "services" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-pod-failure/openebs_target_pod_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: FORCE - value: 'true' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: CHAOS_INTERVAL - value: '15' - - - name: DEPLOY_TYPE - value: 'deployment' - - labels: - name: openebs-target-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-pod-failure - # mountPath: /mnt - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the pool pod and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-pod-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "openebs.io" - - "storage.k8s.io" - resources: - - "deployments" - - "replicasets" - - "jobs" - - "pods/log" - - "events" - - "pods" - - "configmaps" - - "secrets" - - "storageclasses" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-pod-failure/openebs_pool_pod_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: default - - - name: OPENEBS_NS - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: CHAOS_ITERATIONS - value: '2' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-pool-pod-failure - # mountPath: /mnt - - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the pool container and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-container-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "openebs.io" - - "storage.k8s.io" - resources: - - "replicasets" - - "events" - - "jobs" - - "pods" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-container-failure/openebs_pool_container_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NS - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: DATA_PERSISTENCE - value: '' - - - name: CHAOS_ITERATIONS - value: '2' - - labels: - name: openebs-pool-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-pool-container-failure - # mountPath: /mnt - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the cstor target/Jiva controller container and check if gets created again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-container-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "events" - - "pods/exec" - - "pods/log" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "delete" - - "get" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-container-failure/openebs_target_container_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - # LIB_IMAGE can be - gaiaadm/pumba:0.6.5, gprasath/crictl:ci - # For pumba image use : gaiaadm/pumba:0.6.5 - # For containerd image use : gprasath/crictl:ci - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # Specify the container runtime used , to pick the relevant chaos util - - name: CONTAINER_RUNTIME - value: 'docker' - - # TARGET_CONTAINER values: cstor-volume-mgmt , cstor-istgt - # For cstor-volume-istgt container kill use : cstor-istgt - # For volume-mgmt-kill container use : cstor-volume-mgmt - - - name: TARGET_CONTAINER - value: 'cstor-volume-mgmt' - - - name: FORCE - value: 'true' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: DEPLOY_TYPE - value: 'deployment' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: SOAK_TIME - value: '60' - - labels: - name: openebs-target-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-container-failure - # mountPath: /mnt - ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network delay to target pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-network-delay -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "services" - - "events" - - "pods/exec" - - "pods/log" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-network-delay/openebs_target_network_delay_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: NETWORK_DELAY - value: '60000' # in milliseconds - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-target-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-network-delay - # mountPath: /mnt - ---- ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - OpenEBS Pool Disk Loss contains chaos to disrupt state of infra resources. Experiments can inject disk loss against openEBS pool. -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-disk-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "jobs" - - "pods/log" - - "events" - - "pods/exec" - - "cstorpools" - - "configmaps" - - "secrets" - - "storageclasses" - - "persistentvolumes" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosexperiments" - - "chaosresults" - - "chaosengines" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-disk-loss/openebs_pool_disk_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # GKE and AWS supported - - name: CLOUD_PLATFORM - value: 'GKE' - - - name: PROJECT_ID - value: '' - - - name: NODE_NAME - value: '' - - - name: DISK_NAME - value: '' - - - name: ZONE_NAME - value: '' - - - name: DEVICE_NAME - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - labels: - name: openebs-pool-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - configmaps: - - name: openebs-pool-disk-loss - mountPath: /mnt/ - - secrets: - - name: cloud-secret - mountPath: /tmp/ - ---- diff --git a/experiments/openebs/icons/openebs-control-plane-chaos.png b/experiments/openebs/icons/openebs-control-plane-chaos.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-control-plane-chaos.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-nfs-provisioner-kill.png b/experiments/openebs/icons/openebs-nfs-provisioner-kill.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-nfs-provisioner-kill.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-pool-container-failure.png b/experiments/openebs/icons/openebs-pool-container-failure.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-pool-container-failure.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-pool-disk-loss.png b/experiments/openebs/icons/openebs-pool-disk-loss.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-pool-disk-loss.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-pool-network-delay.png b/experiments/openebs/icons/openebs-pool-network-delay.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-pool-network-delay.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-pool-network-loss.png b/experiments/openebs/icons/openebs-pool-network-loss.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs-pool-network-loss.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-pool-pod-failure.png b/experiments/openebs/icons/openebs-pool-pod-failure.png deleted file mode 100644 index fdb3cd9..0000000 Binary files a/experiments/openebs/icons/openebs-pool-pod-failure.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-target-container-failure.png b/experiments/openebs/icons/openebs-target-container-failure.png deleted file mode 100644 index bdd874d..0000000 Binary files a/experiments/openebs/icons/openebs-target-container-failure.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-target-network-delay.png b/experiments/openebs/icons/openebs-target-network-delay.png deleted file mode 100644 index 0ce92ba..0000000 Binary files a/experiments/openebs/icons/openebs-target-network-delay.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-target-network-loss.png b/experiments/openebs/icons/openebs-target-network-loss.png deleted file mode 100644 index 5826e28..0000000 Binary files a/experiments/openebs/icons/openebs-target-network-loss.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs-target-pod-failure.png b/experiments/openebs/icons/openebs-target-pod-failure.png deleted file mode 100644 index 344632a..0000000 Binary files a/experiments/openebs/icons/openebs-target-pod-failure.png and /dev/null differ diff --git a/experiments/openebs/icons/openebs.png b/experiments/openebs/icons/openebs.png deleted file mode 100644 index db1d3e7..0000000 Binary files a/experiments/openebs/icons/openebs.png and /dev/null differ diff --git a/experiments/openebs/openebs-control-plane-chaos/engine.yaml b/experiments/openebs/openebs-control-plane-chaos/engine.yaml deleted file mode 100644 index 308982d..0000000 --- a/experiments/openebs/openebs-control-plane-chaos/engine.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: control-plane-chaos - namespace: openebs -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'openebs' - applabel: 'name=maya-apiserver' - appkind: 'deployment' - chaosServiceAccount: control-plane-sa - experiments: - - name: openebs-control-plane-chaos - spec: - components: - env: - - name: FORCE - value: '' \ No newline at end of file diff --git a/experiments/openebs/openebs-control-plane-chaos/experiment.yaml b/experiments/openebs/openebs-control-plane-chaos/experiment.yaml deleted file mode 100644 index 805f39b..0000000 --- a/experiments/openebs/openebs-control-plane-chaos/experiment.yaml +++ /dev/null @@ -1,79 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill all openebs control plane pod and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-control-plane-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-control-plane-chaos -spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "litmuschaos.io" - - "batch" - - "apps" - resources: - - "pods" - - "pods/log" - - "deployments" - - "events" - - "jobs" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-control-plane-chaos/openebs_control_plane_chaos_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - ## Period to wait before injection of chaos - - name: RAMP_TIME - value: '' - - - name: FORCE - value: '' - - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, powerfulseal - - name: LIB - value: 'litmus' - - labels: - name: openebs-control-plane-chaos - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/openebs/openebs-control-plane-chaos/openebs-control-plane-chaos.chartserviceversion.yaml b/experiments/openebs/openebs-control-plane-chaos/openebs-control-plane-chaos.chartserviceversion.yaml deleted file mode 100644 index 418f481..0000000 --- a/experiments/openebs/openebs-control-plane-chaos/openebs-control-plane-chaos.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: openebs-control-plane-chaos - version: 0.1.4 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-control-plane-chaos - categoryDescription: > - Kill all openebs control plane pods and check if gets scheduled again. - keywords: - - Kubernetes - - K8S - - OpenEBS - platforms: - - GKE - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-control-plane-chaos - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-control-plane-chaos/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-control-plane-chaos/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-control-plane-chaos/rbac.yaml b/experiments/openebs/openebs-control-plane-chaos/rbac.yaml deleted file mode 100644 index 6663ee0..0000000 --- a/experiments/openebs/openebs-control-plane-chaos/rbac.yaml +++ /dev/null @@ -1,42 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: control-plane-sa - namespace: openebs - labels: - name: control-plane-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: control-plane-sa - namespace: openebs - labels: - name: control-plane-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","litmuschaos.io","batch","apps"] - resources: ["pods","deployments","pods/log","events","jobs","configmaps","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: control-plane-sa - namespace: openebs - labels: - name: control-plane-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: control-plane-sa -subjects: -- kind: ServiceAccount - name: control-plane-sa - namespace: openebs diff --git a/experiments/openebs/openebs-nfs-provisioner-kill/engine.yaml b/experiments/openebs/openebs-nfs-provisioner-kill/engine.yaml deleted file mode 100644 index 012e6f9..0000000 --- a/experiments/openebs/openebs-nfs-provisioner-kill/engine.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: nfs-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'minio' - applabel: 'app=minio' - appkind: 'deployment' - chaosServiceAccount: nfs-chaos-sa - experiments: - - name: openebs-nfs-provisioner-kill - spec: - components: - env: - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: NFS_PROVISIONER_NAMESPACE - value: 'app-nfs-ns' - - - name: NFS_PROVISIONER_LABEL - value: 'app=nfs' - - - name: NFS_PVC - value: 'nfs-pvc-claim' - - - name: NFS_SVC - value: 'nfs-provisioner' - - - name: TARGET_CONTAINER - value: 'nfs-provisioner' - - # EXTERNAL_APP_CHECK can be true/false - - name: EXTERNAL_APP_CHECK - value: 'true' \ No newline at end of file diff --git a/experiments/openebs/openebs-nfs-provisioner-kill/experiment.yaml b/experiments/openebs/openebs-nfs-provisioner-kill/experiment.yaml deleted file mode 100644 index 99b2afb..0000000 --- a/experiments/openebs/openebs-nfs-provisioner-kill/experiment.yaml +++ /dev/null @@ -1,100 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the OpenEBS NFS provisioner container and check if pods consuming the NFS PVs continue to be available and volumes are writable (RWM mode) -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-nfs-provisioner-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-nfs-provisioner-kill -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - resources: - - "pods" - - "pods/exec" - - "pods/log" - - "deployments" - - "events" - - "jobs" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosexperiments" - - "chaosresults" - - "chaosengines" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-nfs-provisioner-kill/openebs_nfs_provisioner_kill_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - # NFS default container - - name: TARGET_CONTAINER - value: 'nfs-provisioner' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # It supports pumba and containerd - - name: LIB - value: 'pumba' - - # LIB_IMAGE can be - gaiaadm/pumba:0.6.5, gprasath/crictl:ci - # For pumba image use: gaiaadm/pumba:0.6.5 - # For containerd image use: gprasath/crictl:ci - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - labels: - name: openebs-nfs-provisioner-kill - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - configmaps: - - name: openebs-nfs-provisioner-kill - mountPath: /mnt/ diff --git a/experiments/openebs/openebs-nfs-provisioner-kill/openebs-nfs-provisioner-kill.chartserviceversion.yaml b/experiments/openebs/openebs-nfs-provisioner-kill/openebs-nfs-provisioner-kill.chartserviceversion.yaml deleted file mode 100644 index db7b923..0000000 --- a/experiments/openebs/openebs-nfs-provisioner-kill/openebs-nfs-provisioner-kill.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: openebs-nfs-provisioner-kill - version: 0.1.3 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-nfs-kill-chaos - categoryDescription: > - Kill the OpenEBS NFS provisioner container and check if pods consuming the NFS PVs continue to be available and volumes are writable (RWM mode) - keywords: - - Kubernetes - - K8S - - OpenEBS - - NFS - platforms: - - GKE - maturity: alpha - chaosType: infra - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-nfs-provisioner-kill - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-nfs-provisioner-kill/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-nfs-provisioner-kill/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-nfs-provisioner-kill/rbac.yaml b/experiments/openebs/openebs-nfs-provisioner-kill/rbac.yaml deleted file mode 100644 index e8710ef..0000000 --- a/experiments/openebs/openebs-nfs-provisioner-kill/rbac.yaml +++ /dev/null @@ -1,37 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: nfs-chaos-sa - namespace: default - labels: - name: nfs-chaos-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: nfs-chaos-sa - labels: - name: nfs-chaos-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io"] - resources: ["pods","pods/exec","pods/log", "deployments","events","jobs","configmaps","services","persistentvolumeclaims","storageclasses","persistentvolumes","chaosexperiments","chaosresults","chaosengines"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: nfs-chaos-sa - labels: - name: nfs-chaos-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: nfs-chaos-sa -subjects: -- kind: ServiceAccount - name: nfs-chaos-sa - namespace: default diff --git a/experiments/openebs/openebs-pool-container-failure/engine.yaml b/experiments/openebs/openebs-pool-container-failure/engine.yaml deleted file mode 100644 index 7fe9a33..0000000 --- a/experiments/openebs/openebs-pool-container-failure/engine.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: pool-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pool-container-failure-sa - experiments: - - name: openebs-pool-container-failure - spec: - components: - env: - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-container-failure/experiment.yaml b/experiments/openebs/openebs-pool-container-failure/experiment.yaml deleted file mode 100644 index 66f5bf9..0000000 --- a/experiments/openebs/openebs-pool-container-failure/experiment.yaml +++ /dev/null @@ -1,97 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the pool container and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-container-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "openebs.io" - - "storage.k8s.io" - resources: - - "replicasets" - - "events" - - "jobs" - - "pods" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-container-failure/openebs_pool_container_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NS - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: DATA_PERSISTENCE - value: '' - - - name: CHAOS_ITERATIONS - value: '2' - - labels: - name: openebs-pool-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-pool-container-failure - # mountPath: /mnt diff --git a/experiments/openebs/openebs-pool-container-failure/openebs-pool-container-failure.chartserviceversion.yaml b/experiments/openebs/openebs-pool-container-failure/openebs-pool-container-failure.chartserviceversion.yaml deleted file mode 100644 index f8616d3..0000000 --- a/experiments/openebs/openebs-pool-container-failure/openebs-pool-container-failure.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-11-13T10:28:08Z - name: openebs-pool-container-failure - version: 0.1.13 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-pool-container-failure - categoryDescription: > - Kill the pool container and check if gets scheduled again. - keywords: - - Kubernetes - - K8S - - Storage Pool - - OpenEBS - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-pool-container-failure - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-pool-container-failure/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-pool-container-failure/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-container-failure/rbac.yaml b/experiments/openebs/openebs-pool-container-failure/rbac.yaml deleted file mode 100644 index a8427af..0000000 --- a/experiments/openebs/openebs-pool-container-failure/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pool-container-failure-sa - namespace: default - labels: - name: pool-container-failure-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pool-container-failure-sa - labels: - name: pool-container-failure-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io","openebs.io"] - resources: ["pods","jobs","events","pods/log","replicasets","pods/exec","configmaps","secrets","persistentvolumeclaims","cstorvolumereplicas","chaosexperiments","chaosresults","chaosengines"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pool-container-failure-sa - labels: - name: pool-container-failure-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pool-container-failure-sa -subjects: -- kind: ServiceAccount - name: pool-container-failure-sa - namespace: default diff --git a/experiments/openebs/openebs-pool-disk-loss/engine.yaml b/experiments/openebs/openebs-pool-disk-loss/engine.yaml deleted file mode 100644 index 39c7ef8..0000000 --- a/experiments/openebs/openebs-pool-disk-loss/engine.yaml +++ /dev/null @@ -1,51 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: pool-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=busybox - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pool-disk-loss-sa - experiments: - - name: openebs-pool-disk-loss - spec: - components: - env: - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: APP_PVC - value: 'demo-nginx-claim' - - # GKE and AWS supported - - name: CLOUD_PLATFORM - value: 'GKE' - - # Enter the project id for gcp only - - name: PROJECT_ID - value: 'litmus-demo-123' - - # Enter the node name - - name: NODE_NAME - value: 'demo-node-123' - - # Enter the disk name - - name: DISK_NAME - value: 'demo-disk-123 ' - - # Enter the device name - - name: DEVICE_NAME - value: '/dev/sdb' - - # Enter the zone name - - name: ZONE_NAME - value: 'us-central1-a' - \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-disk-loss/experiment.yaml b/experiments/openebs/openebs-pool-disk-loss/experiment.yaml deleted file mode 100644 index 622583e..0000000 --- a/experiments/openebs/openebs-pool-disk-loss/experiment.yaml +++ /dev/null @@ -1,111 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - OpenEBS Pool Disk Loss contains chaos to disrupt state of infra resources. Experiments can inject disk loss against openEBS pool. -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-disk-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "jobs" - - "pods/log" - - "events" - - "pods/exec" - - "cstorpools" - - "configmaps" - - "secrets" - - "storageclasses" - - "persistentvolumes" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosexperiments" - - "chaosresults" - - "chaosengines" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-disk-loss/openebs_pool_disk_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' - - # GKE and AWS supported - - name: CLOUD_PLATFORM - value: 'GKE' - - - name: PROJECT_ID - value: '' - - - name: NODE_NAME - value: '' - - - name: DISK_NAME - value: '' - - - name: ZONE_NAME - value: '' - - - name: DEVICE_NAME - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - labels: - name: openebs-pool-disk-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - - configmaps: - - name: openebs-pool-disk-loss - mountPath: /mnt/ - - secrets: - - name: cloud-secret - mountPath: /tmp/ diff --git a/experiments/openebs/openebs-pool-disk-loss/openebs-pool-disk-loss.chartserviceversion.yaml b/experiments/openebs/openebs-pool-disk-loss/openebs-pool-disk-loss.chartserviceversion.yaml deleted file mode 100644 index 33e310d..0000000 --- a/experiments/openebs/openebs-pool-disk-loss/openebs-pool-disk-loss.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2020-03-13T10:28:08Z - name: openebs-pool-disk-loss - version: 0.1.3 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-pool-disk-loss - categoryDescription: > - OpenEBS Pool Disk Loss contains chaos to disrupt state of infra resources. Experiments can inject disk loss against openEBS pool. - - Causes (forced/graceful) disk loss from the node disk pool. - - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. - keywords: - - Kubernetes - - K8S - - Storage Pool - - OpenEBS - platforms: - - GKE - maturity: alpha - chaosType: infra - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-pool-disk-loss - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-pool-disk-loss/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-pool-disk-loss/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-disk-loss/rbac.yaml b/experiments/openebs/openebs-pool-disk-loss/rbac.yaml deleted file mode 100644 index a7ce983..0000000 --- a/experiments/openebs/openebs-pool-disk-loss/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pool-disk-loss-sa - namespace: default - labels: - name: pool-disk-loss-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pool-disk-loss-sa - labels: - name: pool-disk-loss-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io","openebs.io"] - resources: ["pods", "pods/log", "jobs", "events", "pods/exec", "cstorpools", "configmaps", "secrets", "storageclasses", "persistentvolumes", "persistentvolumeclaims", "cstorvolumereplicas", "chaosexperiments", "chaosresults", "chaosengines"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pool-disk-loss-sa - labels: - name: pool-disk-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pool-disk-loss-sa -subjects: -- kind: ServiceAccount - name: pool-disk-loss-sa - namespace: default diff --git a/experiments/openebs/openebs-pool-network-delay/engine.yaml b/experiments/openebs/openebs-pool-network-delay/engine.yaml deleted file mode 100644 index 72aec3d..0000000 --- a/experiments/openebs/openebs-pool-network-delay/engine.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: pool-chaos - namespace: default -spec: - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pool-network-delay-sa - experiments: - - name: openebs-pool-network-delay - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: APP_PVC - value: 'demo-nginx-claim' - - # in milliseconds - - name: NETWORK_DELAY - value: '60000' diff --git a/experiments/openebs/openebs-pool-network-delay/experiment.yaml b/experiments/openebs/openebs-pool-network-delay/experiment.yaml deleted file mode 100644 index f37baf4..0000000 --- a/experiments/openebs/openebs-pool-network-delay/experiment.yaml +++ /dev/null @@ -1,93 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network delay to pool pod belonging to a OpenEBS PVC - This experiment is using pumba lib for network chaos -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-network-delay -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "pods/exec" - - "jobs" - - "pods/log" - - "events" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "cstorpools" - - "cstorvolumereplicas" - - "replicasets" - verbs: - - "create" - - "get" - - "list" - - "patch" - - "update" - - "delete" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-network-delay/openebs_pool_network_delay_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # in milliseconds - - name: NETWORK_DELAY - value: '60000' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/openebs/openebs-pool-network-delay/openebs-pool-network-delay.chartserviceversion.yaml b/experiments/openebs/openebs-pool-network-delay/openebs-pool-network-delay.chartserviceversion.yaml deleted file mode 100644 index 631b6e3..0000000 --- a/experiments/openebs/openebs-pool-network-delay/openebs-pool-network-delay.chartserviceversion.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: openebs-pool-network-delay - version: 0.1.4 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-pool-network-delay - categoryDescription: > - Network delay to pool pod belonging to a OpenEBS PVC - keywords: - - Kubernetes - - K8S - - Storage Pool - - OpenEBS - - Network - platforms: - - GKE - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-pool-network-delay - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-pool-network-delay/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-pool-network-delay/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-network-delay/rbac.yaml b/experiments/openebs/openebs-pool-network-delay/rbac.yaml deleted file mode 100644 index 8db3c74..0000000 --- a/experiments/openebs/openebs-pool-network-delay/rbac.yaml +++ /dev/null @@ -1,34 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pool-network-delay-sa - namespace: default - labels: - name: pool-network-delay-sa ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pool-network-delay-sa - labels: - name: pool-network-delay-sa -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io","openebs.io"] - resources: ["pods","pods/exec","pods/log","events","jobs","configmaps","services","persistentvolumeclaims","storageclasses","persistentvolumes","chaosengines","chaosexperiments","chaosresults","cstorpools","cstorvolumereplicas","replicasets"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pool-network-delay-sa - labels: - name: pool-network-delay-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pool-network-delay-sa -subjects: -- kind: ServiceAccount - name: pool-network-delay-sa - namespace: default \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-network-loss/engine.yaml b/experiments/openebs/openebs-pool-network-loss/engine.yaml deleted file mode 100644 index 8843b98..0000000 --- a/experiments/openebs/openebs-pool-network-loss/engine.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: pool-chaos - namespace: default -spec: - auxiliaryAppInfo: '' - # It can be active/stop - engineState: 'active' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pool-network-loss-sa - experiments: - - name: openebs-pool-network-loss - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' diff --git a/experiments/openebs/openebs-pool-network-loss/experiment.yaml b/experiments/openebs/openebs-pool-network-loss/experiment.yaml deleted file mode 100644 index 6d896dd..0000000 --- a/experiments/openebs/openebs-pool-network-loss/experiment.yaml +++ /dev/null @@ -1,92 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network loss to pool pod belonging to a OpenEBS PVC -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-network-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "litmuschaos.io" - - "batch" - - "extensions" - - "storage.k8s.io" - - "openebs.io" - resources: - - "pods" - - "pods/log" - - "pods/exec" - - "events" - - "jobs" - - "configmaps" - - "services" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumeclaims" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "cstorpools" - - "cstorvolumereplicas" - - "replicasets" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-network-loss/openebs_pool_network_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' # in percentage - - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/openebs/openebs-pool-network-loss/openebs-pool-network-loss.chartserviceversion.yaml b/experiments/openebs/openebs-pool-network-loss/openebs-pool-network-loss.chartserviceversion.yaml deleted file mode 100644 index e1fe3ae..0000000 --- a/experiments/openebs/openebs-pool-network-loss/openebs-pool-network-loss.chartserviceversion.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - name: openebs-pool-network-loss - version: 0.1.3 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-pool-network-loss - categoryDescription: > - Network loss to pool pod belonging to a OpenEBS PVC - keywords: - - Kubernetes - - K8S - - Storage Pool - - OpenEBS - - Network - platforms: - - GKE - - EKS - maturity: alpha - chaosType: infra - maintainers: - - name: Raj Babu Das - email: raj.das@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-pool-network-loss - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-pool-network-loss/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-pool-network-loss/experiment.yaml \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-network-loss/rbac.yaml b/experiments/openebs/openebs-pool-network-loss/rbac.yaml deleted file mode 100644 index 20dcfc4..0000000 --- a/experiments/openebs/openebs-pool-network-loss/rbac.yaml +++ /dev/null @@ -1,35 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pool-network-loss-sa - namespace: default - labels: - name: pool-network-loss-sa ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pool-network-loss-sa - labels: - name: pool-network-loss-sa -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io","openebs.io"] - resources: ["pods","pods/exec","pods/log","events","jobs","configmaps","services","persistentvolumeclaims","storageclasses","persistentvolumes","chaosengines","chaosexperiments","chaosresults","cstorpools","cstorvolumereplicas","replicasets"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pool-network-loss-sa - labels: - name: pool-network-loss-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pool-network-loss-sa -subjects: -- kind: ServiceAccount - name: pool-network-loss-sa - namespace: default diff --git a/experiments/openebs/openebs-pool-pod-failure/engine.yaml b/experiments/openebs/openebs-pool-pod-failure/engine.yaml deleted file mode 100644 index cfc1490..0000000 --- a/experiments/openebs/openebs-pool-pod-failure/engine.yaml +++ /dev/null @@ -1,28 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: pool-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pool-pod-failure-sa - experiments: - - name: openebs-pool-pod-failure - spec: - components: - env: - - name: CHAOS_ITERATIONS - value: '2' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' \ No newline at end of file diff --git a/experiments/openebs/openebs-pool-pod-failure/experiment.yaml b/experiments/openebs/openebs-pool-pod-failure/experiment.yaml deleted file mode 100644 index 52b597b..0000000 --- a/experiments/openebs/openebs-pool-pod-failure/experiment.yaml +++ /dev/null @@ -1,97 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the pool pod and check if gets scheduled again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-pool-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-pool-pod-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "openebs.io" - - "storage.k8s.io" - resources: - - "deployments" - - "replicasets" - - "jobs" - - "pods/log" - - "events" - - "pods" - - "configmaps" - - "secrets" - - "storageclasses" - - "persistentvolumeclaims" - - "cstorvolumereplicas" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-pool-pod-failure/openebs_pool_pod_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: default - - - name: OPENEBS_NS - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: CHAOS_ITERATIONS - value: '2' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-pool-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-pool-pod-failure - # mountPath: /mnt - diff --git a/experiments/openebs/openebs-pool-pod-failure/openebs-pool-pod-failure.chartserviceversion.yaml b/experiments/openebs/openebs-pool-pod-failure/openebs-pool-pod-failure.chartserviceversion.yaml deleted file mode 100644 index 6c49ec1..0000000 --- a/experiments/openebs/openebs-pool-pod-failure/openebs-pool-pod-failure.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-11-12T10:28:08Z - name: openebs-pool-pod-failure - version: 0.1.12 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-pool-pod-failure - categoryDescription: > - Kill the pool pod and check if gets scheduled again. - keywords: - - Kubernetes - - K8S - - Storage Pool - - OpenEBS - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-pool-pod-failure - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-pool-pod-failure/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-pool-pod-failure/experiment.yaml diff --git a/experiments/openebs/openebs-pool-pod-failure/rbac.yaml b/experiments/openebs/openebs-pool-pod-failure/rbac.yaml deleted file mode 100644 index 4b6ac65..0000000 --- a/experiments/openebs/openebs-pool-pod-failure/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: pool-pod-failure-sa - namespace: default - labels: - name: pool-pod-failure-sa ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: pool-pod-failure-sa - labels: - name: pool-pod-failure-sa -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io","openebs.io"] - resources: ["pods","jobs","deployments","pods/log","events","configmaps","secrets","replicasets","persistentvolumeclaims","storageclasses","cstorvolumereplicas","chaosexperiments","chaosresults","chaosengines"] - verbs: ["create","list","get","patch","update","delete"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: pool-pod-failure-sa - labels: - name: pool-pod-failure-sa -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: pool-pod-failure-sa -subjects: -- kind: ServiceAccount - name: pool-pod-failure-sa - namespace: default diff --git a/experiments/openebs/openebs-target-container-failure/engine.yaml b/experiments/openebs/openebs-target-container-failure/engine.yaml deleted file mode 100644 index f082c2a..0000000 --- a/experiments/openebs/openebs-target-container-failure/engine.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: target-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: target-container-failure-sa - experiments: - - name: openebs-target-container-failure - spec: - components: - env: - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: TARGET_CONTAINER - value: 'cstor-istgt' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' \ No newline at end of file diff --git a/experiments/openebs/openebs-target-container-failure/experiment.yaml b/experiments/openebs/openebs-target-container-failure/experiment.yaml deleted file mode 100644 index ef432b5..0000000 --- a/experiments/openebs/openebs-target-container-failure/experiment.yaml +++ /dev/null @@ -1,113 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the cstor target/Jiva controller container and check if gets created again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-container-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "events" - - "pods/exec" - - "pods/log" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "delete" - - "get" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-container-failure/openebs_target_container_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - # LIB_IMAGE can be - gaiaadm/pumba:0.6.5, gprasath/crictl:ci - # For pumba image use : gaiaadm/pumba:0.6.5 - # For containerd image use : gprasath/crictl:ci - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - # Specify the container runtime used , to pick the relevant chaos util - - name: CONTAINER_RUNTIME - value: 'docker' - - # TARGET_CONTAINER values: cstor-volume-mgmt , cstor-istgt - # For cstor-volume-istgt container kill use : cstor-istgt - # For volume-mgmt-kill container use : cstor-volume-mgmt - - - name: TARGET_CONTAINER - value: 'cstor-volume-mgmt' - - - name: FORCE - value: 'true' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: DEPLOY_TYPE - value: 'deployment' - - # provide the chaos interval - - name: CHAOS_INTERVAL - value: '10' - - # provide the total chaos duration - - name: TOTAL_CHAOS_DURATION - value: '20' - - - name: SOAK_TIME - value: '60' - - labels: - name: openebs-target-container-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-container-failure - # mountPath: /mnt diff --git a/experiments/openebs/openebs-target-container-failure/openebs-target-container-failure.chartserviceversion.yaml b/experiments/openebs/openebs-target-container-failure/openebs-target-container-failure.chartserviceversion.yaml deleted file mode 100644 index f84c594..0000000 --- a/experiments/openebs/openebs-target-container-failure/openebs-target-container-failure.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-11-11T10:28:08Z - name: openebs-target-container-failure - version: 0.1.12 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-target-container-failure - categoryDescription: > - Kill the cstor target/Jiva controller container and check if gets created again - keywords: - - Kubernetes - - K8S - - Storage Controller - - OpenEBS - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-target-container-failure - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-target-container-failure/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-target-container-failure/experiment.yaml diff --git a/experiments/openebs/openebs-target-container-failure/rbac.yaml b/experiments/openebs/openebs-target-container-failure/rbac.yaml deleted file mode 100644 index d8d38fe..0000000 --- a/experiments/openebs/openebs-target-container-failure/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: target-container-failure-sa - namespace: default - labels: - name: target-container-failure-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: target-container-failure-sa - labels: - name: target-container-failure-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","litmuschaos.io","batch","apps","storage.k8s.io"] - resources: ["pods","jobs","pods/log","pods/exec","events","configmaps","secrets","persistentvolumeclaims","storageclasses","persistentvolumes","chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: target-container-failure-sa - labels: - name: target-container-failure-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: target-container-failure-sa -subjects: -- kind: ServiceAccount - name: target-container-failure-sa - namespace: default diff --git a/experiments/openebs/openebs-target-network-delay/engine.yaml b/experiments/openebs/openebs-target-network-delay/engine.yaml deleted file mode 100644 index 4681601..0000000 --- a/experiments/openebs/openebs-target-network-delay/engine.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: target-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: target-network-delay-sa - experiments: - - name: openebs-target-network-delay - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: TARGET_CONTAINER - value: 'cstor-istgt' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' - - - name: NETWORK_DELAY - value: '30000' - \ No newline at end of file diff --git a/experiments/openebs/openebs-target-network-delay/experiment.yaml b/experiments/openebs/openebs-target-network-delay/experiment.yaml deleted file mode 100644 index 30f554d..0000000 --- a/experiments/openebs/openebs-target-network-delay/experiment.yaml +++ /dev/null @@ -1,94 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network delay to target pod belonging to a deployment/statefulset/daemonset -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-network-delay -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "services" - - "events" - - "pods/exec" - - "pods/log" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-network-delay/openebs_target_network_delay_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: NETWORK_DELAY - value: '60000' # in milliseconds - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-target-network-delay - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-network-delay - # mountPath: /mnt diff --git a/experiments/openebs/openebs-target-network-delay/openebs-target-network-delay.chartserviceversion.yaml b/experiments/openebs/openebs-target-network-delay/openebs-target-network-delay.chartserviceversion.yaml deleted file mode 100644 index 04578ed..0000000 --- a/experiments/openebs/openebs-target-network-delay/openebs-target-network-delay.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-17T10:28:08Z - name: openebs-target-network-delay - version: 0.1.9 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: openebs-target-network-delay - categoryDescription: > - Network delay to Pod belonging to a OpenEBS PVC - keywords: - - OpenEBS - - Kubernetes - - K8S - - Network - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: giri - email: giridhara.prasad@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-target-network-delay - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-target-network-delay/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-target-network-delay/experiment.yaml diff --git a/experiments/openebs/openebs-target-network-delay/rbac.yaml b/experiments/openebs/openebs-target-network-delay/rbac.yaml deleted file mode 100644 index efba945..0000000 --- a/experiments/openebs/openebs-target-network-delay/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: target-network-delay-sa - namespace: default - labels: - name: target-network-delay-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: target-network-delay-sa - labels: - name: target-network-delay-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io"] - resources: ["pods","pods/exec","pods/log","events","jobs","configmaps","secrets","services","persistentvolumeclaims","storageclasses","persistentvolumes","chaosexperiments","chaosresults","chaosengines"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: target-network-delay-sa - labels: - name: target-network-delay-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: target-network-delay-sa -subjects: -- kind: ServiceAccount - name: target-network-delay-sa - namespace: default diff --git a/experiments/openebs/openebs-target-network-loss/engine.yaml b/experiments/openebs/openebs-target-network-loss/engine.yaml deleted file mode 100644 index ba3b3f9..0000000 --- a/experiments/openebs/openebs-target-network-loss/engine.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: target-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: target-network-loss-sa - experiments: - - name: openebs-target-network-loss - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: TARGET_CONTAINER - value: 'cstor-istgt' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' diff --git a/experiments/openebs/openebs-target-network-loss/experiment.yaml b/experiments/openebs/openebs-target-network-loss/experiment.yaml deleted file mode 100644 index 45876c6..0000000 --- a/experiments/openebs/openebs-target-network-loss/experiment.yaml +++ /dev/null @@ -1,94 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Network loss to target pod belonging to a OpenEBS PVC -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-network-loss -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "jobs" - - "pods" - - "events" - - "services" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-network-loss/openebs_target_network_loss_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: TC_IMAGE - value: 'gaiadocker/iproute2' - - # only pumba supported - # For pumba image use : gaiaadm/pumba:0.6.5 - - name: LIB_IMAGE - value: 'gaiaadm/pumba:0.6.5' - - - name: NETWORK_PACKET_LOSS_PERCENTAGE - value: '100' # in percentage - - - name: TOTAL_CHAOS_DURATION - value: '120' # in seconds - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - labels: - name: openebs-target-network-loss - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-network-loss - # mountPath: /mnt diff --git a/experiments/openebs/openebs-target-network-loss/openebs-target-network-loss.chartserviceversion.yaml b/experiments/openebs/openebs-target-network-loss/openebs-target-network-loss.chartserviceversion.yaml deleted file mode 100644 index bb98d32..0000000 --- a/experiments/openebs/openebs-target-network-loss/openebs-target-network-loss.chartserviceversion.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-10-17T10:28:08Z - name: openebs-target-network-loss - version: 0.1.9 - annotations: - categories: Kubernetes - vendor: CNCF - support: https://slack.kubernetes.io/ -spec: - displayName: openebs-target-network-loss - categoryDescription: > - Network loss to the target pod belonging to an OpenEBS PVC - keywords: - - Kubernetes - - K8S - - OpenEBS - - Network - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: giri - email: giridhara.prasad@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-target-network-loss - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-target-network-loss/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-target-network-loss/experiment.yaml diff --git a/experiments/openebs/openebs-target-network-loss/rbac.yaml b/experiments/openebs/openebs-target-network-loss/rbac.yaml deleted file mode 100644 index 1a29e6d..0000000 --- a/experiments/openebs/openebs-target-network-loss/rbac.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: target-network-loss-sa - namespace: default - labels: - name: target-network-loss-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: target-network-loss-sa - labels: - name: target-network-loss-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io"] - resources: ["pods","pods/exec","pods/log","events","jobs","configmaps","secrets","services","persistentvolumeclaims","storageclasses","persistentvolumes","chaosexperiments","chaosresults","chaosengines"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: target-network-loss-sa - labels: - name: target-network-loss-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: target-network-loss-sa -subjects: -- kind: ServiceAccount - name: target-network-loss-sa - namespace: default diff --git a/experiments/openebs/openebs-target-pod-failure/engine.yaml b/experiments/openebs/openebs-target-pod-failure/engine.yaml deleted file mode 100644 index e014e9a..0000000 --- a/experiments/openebs/openebs-target-pod-failure/engine.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: target-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: target-pod-failure-sa - experiments: - - name: openebs-target-pod-failure - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: '60' - - - name: FORCE - value: 'true' - - - name: APP_PVC - value: 'demo-nginx-claim' - - - name: DEPLOY_TYPE - value: 'deployment' \ No newline at end of file diff --git a/experiments/openebs/openebs-target-pod-failure/experiment.yaml b/experiments/openebs/openebs-target-pod-failure/experiment.yaml deleted file mode 100644 index c2ef483..0000000 --- a/experiments/openebs/openebs-target-pod-failure/experiment.yaml +++ /dev/null @@ -1,105 +0,0 @@ ---- -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Kill the cstor target/Jiva controller pod and check if gets created again -kind: ChaosExperiment -metadata: - labels: - litmuschaos.io/name: openebs - name: openebs-target-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest - name: openebs-target-pod-failure -spec: - definition: - scope: Cluster - permissions: - - apiGroups: - - "" - - "extensions" - - "apps" - - "batch" - - "litmuschaos.io" - - "storage.k8s.io" - resources: - - "deployments" - - "jobs" - - "events" - - "pods" - - "pods/log" - - "pods/exec" - - "configmaps" - - "secrets" - - "services" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - - "persistentvolumeclaims" - - "storageclasses" - - "persistentvolumes" - verbs: - - "create" - - "get" - - "delete" - - "list" - - "patch" - - "update" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/ansible-runner:latest" - imagePullPolicy: Always - args: - - -c - - ansible-playbook ./experiments/openebs/openebs-target-pod-failure/openebs_target_pod_failure_ansible_logic.yml -i /etc/ansible/hosts -vv; exit 0 - command: - - /bin/bash - env: - - name: ANSIBLE_STDOUT_CALLBACK - value: 'default' - - - name: OPENEBS_NAMESPACE - value: 'openebs' - - - name: APP_PVC - value: '' - - - name: FORCE - value: 'true' - - - name: LIVENESS_APP_LABEL - value: '' - - - name: LIVENESS_APP_NAMESPACE - value: '' - - - name: DATA_PERSISTENCE - value: '' - - - name: TOTAL_CHAOS_DURATION - value: '60' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: CHAOS_INTERVAL - value: '15' - - - name: DEPLOY_TYPE - value: 'deployment' - - labels: - name: openebs-target-pod-failure - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - #configmaps: - #- name: openebs-target-pod-failure - # mountPath: /mnt diff --git a/experiments/openebs/openebs-target-pod-failure/openebs-target-pod-failure.chartserviceversion.yaml b/experiments/openebs/openebs-target-pod-failure/openebs-target-pod-failure.chartserviceversion.yaml deleted file mode 100644 index c04aef4..0000000 --- a/experiments/openebs/openebs-target-pod-failure/openebs-target-pod-failure.chartserviceversion.yaml +++ /dev/null @@ -1,46 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-11-11T10:28:08Z - name: openebs-target-pod-failure - version: 0.1.11 - annotations: - categories: OpenEBS - vendor: CNCF - support: https://slack.openebs.io/ -spec: - displayName: openebs-target-pod-failure - categoryDescription: > - Kill the cstor target/Jiva controller pod and check if gets created again - keywords: - - Kubernetes - - K8S - - Storage Controller - - OpenEBS - platforms: - - GKE - - EKS - - OpenShift - maturity: alpha - chaosType: infra - maintainers: - - name: shubham chaudhary - email: shubham.chaudhary@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-ansible/tree/master/experiments/openebs/openebs-target-pod-failure - - name: Documentation - url: https://v1-docs.litmuschaos.io/docs/openebs-target-pod-failure/ - - name: Video - url: - icon: - - url: "" - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/openebs-target-pod-failure/experiment.yaml - diff --git a/experiments/openebs/openebs-target-pod-failure/rbac.yaml b/experiments/openebs/openebs-target-pod-failure/rbac.yaml deleted file mode 100644 index 79fa90b..0000000 --- a/experiments/openebs/openebs-target-pod-failure/rbac.yaml +++ /dev/null @@ -1,42 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: target-pod-failure-sa - namespace: default - labels: - name: target-pod-failure-sa - app.kubernetes.io/part-of: litmus ---- -# Source: openebs/templates/clusterrole.yaml -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: target-pod-failure-sa - labels: - name: target-pod-failure-sa - app.kubernetes.io/part-of: litmus -rules: -- apiGroups: ["","apps","litmuschaos.io","batch","extensions","storage.k8s.io"] - resources: ["pods","jobs","pods/log","deployments","pods/exec","events","chaosexperiments","chaosresults","chaosengines","configmaps","secrets","services","persistentvolumeclaims","storageclasses","persistentvolumes"] - verbs: ["create","list","get","patch","update","delete"] -- apiGroups: [""] - resources: ["nodes"] - verbs: ["get","list"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: target-pod-failure-sa - labels: - name: target-pod-failure-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: target-pod-failure-sa -subjects: -- kind: ServiceAccount - name: target-pod-failure-sa - namespace: default - diff --git a/experiments/openebs/openebs.chartserviceversion.yaml b/experiments/openebs/openebs.chartserviceversion.yaml deleted file mode 100644 index 6cdaf94..0000000 --- a/experiments/openebs/openebs.chartserviceversion.yaml +++ /dev/null @@ -1,63 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2019-08-27T10:28:08Z - name: openebs - version: 0.1.8 - annotations: - categories: OpenEBS - vendor: MayaData - support: https://slack.openebs.io/ - chartDescription: Injects generic openebs chaos -spec: - displayName: OpenEBS - categoryDescription: > - OpenEBS is the most active Container Attached Storage project. OpenEBS enables your DevOps teams to have their own storage policies for every workload and it is truly Kubernetes native and 100% in userspace. - - experiments: - - name: openebs-pool-pod-failure - description: "" - - name: openebs-pool-container-failure - description: "" - - name: openebs-target-pod-failure - description: "" - - name: openebs-target-container-failure - description: "" - - name: openebs-target-network-delay - description: "" - - name: openebs-target-network-loss - description: "" - - name: openebs-pool-network-delay - description: "" - - name: openebs-pool-network-loss - description: "" - - name: openebs-control-plane-chaos - description: "" - - name: openebs-pool-disk-loss - description: "" - - name: openebs-nfs-provisioner-kill - description: "" - keywords: - - Kubernetes - - K8S - - OpenEBS - - CAS - - Storage - - Network - - Pod - - Pool - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io - minKubeVersion: 1.12.0 - provider: - name: Mayadata - links: - - name: OpenEBS Website - url: https://openebs.io - - name: Source Code - url: https://github.com/openebs/openebs - icon: - - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/icons/openebs.png - mediatype: image/png - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/openebs/experiments.yaml diff --git a/experiments/openebs/openebs.package.yaml b/experiments/openebs/openebs.package.yaml deleted file mode 100644 index 0f18e73..0000000 --- a/experiments/openebs/openebs.package.yaml +++ /dev/null @@ -1,35 +0,0 @@ -packageName: openebs -experiments: - - name: openebs-pool-pod-failure - CSV: openebs-pool-pod-failure.chartserviceversion.yaml - desc: "openebs-pool-pod-failure" - - name: openebs-pool-container-failure - CSV: openebs-pool-container-failure.chartserviceversion.yaml - desc: "openebs-pool-container-failure" - - name: openebs-target-pod-failure - CSV: openebs-target-pod-failure.chartserviceversion.yaml - desc: "openebs-target-pod-failure" - - name: openebs-target-container-failure - CSV: openebs-target-container-failure.chartserviceversion.yaml - desc: "openebs-target-container-failure" - - name: openebs-target-network-delay - CSV: openebs-target-network-delay.chartserviceversion.yaml - desc: "openebs-target-network-delay" - - name: openebs-target-network-loss - CSV: openebs-target-network-loss.chartserviceversion.yaml - desc: "openebs-target-network-loss" - - name: openebs-control-plane-chaos - CSV: openebs-control-plane-chaos.chartserviceversion.yaml - desc: "openebs-control-plane-chaos" - - name: openebs-pool-network-delay - CSV: openebs-pool-network-delay.chartserviceversion.yaml - desc: "openebs-pool-network-delay" - - name: openebs-pool-network-loss - CSV: openebs-pool-network-loss.chartserviceversion.yaml - desc: "openebs-pool-network-loss" - - name: openebs-pool-disk-loss - CSV: openebs-pool-disk-loss.chartserviceversion.yaml - desc: "openebs-pool-disk-loss" - - name: openebs-nfs-provisioner-kill - CSV: openebs-nfs-provisioner-kill.chartserviceversion.yaml - desc: "openebs-nfs-provisioner-kill" \ No newline at end of file diff --git a/experiments/openebs/sample_openebs_engine_with_data_persistency_enabled.yaml b/experiments/openebs/sample_openebs_engine_with_data_persistency_enabled.yaml deleted file mode 100644 index 7a59e6e..0000000 --- a/experiments/openebs/sample_openebs_engine_with_data_persistency_enabled.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -kind: ChaosEngine -metadata: - name: openebs-chaos - namespace: default -spec: - # It can be active/stop - engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: -sa - experiments: - - name: - spec: - components: - env: - - name: TARGET_CONTAINER - value: 'cstor-istgt' - - name: APP_PVC - value: 'demo-nginx-claim' - configMaps: - - name: map1 - mountPath: '/mnt' - secrets: - - name: secret1 - mountPath: '/tmp' \ No newline at end of file diff --git a/workflows/pod-cpu-hog/workflow.yaml b/experiments/pod-cpu-hog/experiment.yaml similarity index 92% rename from workflows/pod-cpu-hog/workflow.yaml rename to experiments/pod-cpu-hog/experiment.yaml index c7f1638..40e7eb5 100644 --- a/workflows/pod-cpu-hog/workflow.yaml +++ b/experiments/pod-cpu-hog/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-pod-cpu-hog- + name: argowf-chaos-pod-cpu-hog- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_kube-proxy" @@ -20,17 +20,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-cpu-hog.yaml raw: data: | @@ -143,9 +143,9 @@ spec: value: "kill -9 $(ps afx | grep \"[md5sum] /dev/zero\" | awk '{print$1}' | tr '\n' ' ')" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/pod-cpu-hog/workflow_cron.yaml b/experiments/pod-cpu-hog/experiment_cron.yaml similarity index 92% rename from workflows/pod-cpu-hog/workflow_cron.yaml rename to experiments/pod-cpu-hog/experiment_cron.yaml index 1e77fb9..2925ff2 100644 --- a/workflows/pod-cpu-hog/workflow_cron.yaml +++ b/experiments/pod-cpu-hog/experiment_cron.yaml @@ -20,21 +20,21 @@ spec: - name: adminModeNamespace value: "litmus" - name: appNamespace - value: "kube-system" + value: "kube-system" templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-cpu-hog.yaml raw: data: | @@ -147,13 +147,13 @@ spec: value: "kill -9 $(ps afx | grep \"[md5sum] /dev/zero\" | awk '{print$1}' | tr '\n' ' ')" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] args: [ "kubectl delete chaosengine kube-proxy-pod-cpu-hog-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] \ No newline at end of file + ] diff --git a/experiments/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml b/experiments/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml new file mode 100644 index 0000000..19e69f9 --- /dev/null +++ b/experiments/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml @@ -0,0 +1,31 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-cpu-hog + version: 0.1.0 + annotations: + categories: pod-cpu-hog + chartDescription: Pod CPU Hog fault consumes the CPU resources of specified containers in Kubernetes pods. +spec: + displayName: Pod CPU Hog + categoryDescription: > + Pod CPU Hog fault consumes the CPU resources of specified containers in Kubernetes pods. + - Causes CPU resource consumption on specified application containers using cgroups and litmus nsutil which consume CPU resources of the given target containers. + - It can test the application's resilience to potential slowness/unavailability of some replicas due to high CPU load. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + faults: + - name: pod-cpu-hog + description: Pod CPU Hog fault consumes the CPU resources of specified containers in Kubernetes pods. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/workflows/pod-delete/workflow.yaml b/experiments/pod-delete/experiment.yaml similarity index 92% rename from workflows/pod-delete/workflow.yaml rename to experiments/pod-delete/experiment.yaml index 460d0ed..5e38c34 100644 --- a/workflows/pod-delete/workflow.yaml +++ b/experiments/pod-delete/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-pod-delete- + name: argowf-chaos-pod-delete- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_kube-proxy" @@ -20,17 +20,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-delete.yaml raw: data: | @@ -99,7 +99,7 @@ spec: - name: CHAOS_INTERVAL value: '5' - + labels: name: pod-delete container: @@ -145,9 +145,9 @@ spec: value: "false" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/pod-delete/workflow_cron.yaml b/experiments/pod-delete/experiment_cron.yaml similarity index 93% rename from workflows/pod-delete/workflow_cron.yaml rename to experiments/pod-delete/experiment_cron.yaml index 8da977c..9016fee 100644 --- a/workflows/pod-delete/workflow_cron.yaml +++ b/experiments/pod-delete/experiment_cron.yaml @@ -24,17 +24,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-delete.yaml raw: data: | @@ -103,7 +103,7 @@ spec: - name: CHAOS_INTERVAL value: '5' - + labels: name: pod-delete container: @@ -149,9 +149,9 @@ spec: value: "false" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/pod-delete/pod-delete.chartserviceversion.yaml b/experiments/pod-delete/pod-delete.chartserviceversion.yaml new file mode 100644 index 0000000..0b25c77 --- /dev/null +++ b/experiments/pod-delete/pod-delete.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-delete + version: 0.1.0 + annotations: + categories: pod-delete + chartDescription: Pod delete fault disrupts the state of Kubernetes resources. This fault injects random pod delete failures against specified application. +spec: + displayName: Pod Delete + categoryDescription: > + Pod delete fault disrupts the state of Kubernetes resources. This fault injects random pod delete failures against specified application. + - Causes (forced/graceful) pod failure of random replicas of an application deployment. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. + faults: + - name: pod-delete + description: Pod delete fault disrupts the state of Kubernetes resources. This fault injects random pod delete failures against specified application. + keywords: + - Kubernetes + platforms: + - GKE + - Konvoy + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/scenarios/pod-memory-hog/workflow.yaml b/experiments/pod-memory-hog/experiment.yaml similarity index 92% rename from scenarios/pod-memory-hog/workflow.yaml rename to experiments/pod-memory-hog/experiment.yaml index c429b58..35e4d6f 100644 --- a/scenarios/pod-memory-hog/workflow.yaml +++ b/experiments/pod-memory-hog/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-pod-memory-hog- + name: argowf-chaos-pod-memory-hog- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_kube-proxy" @@ -20,17 +20,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-memory-hog.yaml raw: data: | @@ -142,9 +142,9 @@ spec: value: "kill -9 $(ps afx | grep \"[dd] if /dev/zero\" | awk '{print $1}' | tr '\n' ' ')" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/pod-memory-hog/workflow_cron.yaml b/experiments/pod-memory-hog/experiment_cron.yaml similarity index 93% rename from workflows/pod-memory-hog/workflow_cron.yaml rename to experiments/pod-memory-hog/experiment_cron.yaml index 1ba2b18..979365f 100644 --- a/workflows/pod-memory-hog/workflow_cron.yaml +++ b/experiments/pod-memory-hog/experiment_cron.yaml @@ -24,17 +24,17 @@ spec: templates: - name: argowf-chaos steps: - - - name: install-experiment - template: install-experiment + - - name: install-chaos-faults + template: install-chaos-faults - - name: run-chaos template: run-chaos - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - - name: install-experiment + - name: install-chaos-faults inputs: artifacts: - - name: install-experiment + - name: install-chaos-faults path: /tmp/pod-memory-hog.yaml raw: data: | @@ -146,9 +146,9 @@ spec: value: "kill -9 $(ps afx | grep \"[dd] if /dev/zero\" | awk '{print $1}' | tr '\n' ' ')" container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + args: ["-file=/tmp/chaosengine.yaml", "-saveName=/tmp/engine-name"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml b/experiments/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml new file mode 100644 index 0000000..bd32ffb --- /dev/null +++ b/experiments/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml @@ -0,0 +1,31 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-memory-hog + version: 0.1.0 + annotations: + categories: pod-memory-hog + chartDescription: Pod memory hog fault consumes memory resources of specified containers in Kubernetes pods. +spec: + displayName: Pod Memory Hog + categoryDescription: > + Pod memory hog fault consumes memory resources of specified containers in Kubernetes pods. + - Causes memory resource consumption on specified application containers using cgroups and litmus nsutil that consume memory resources of the given target containers. + - It tests the application's resilience to potential slowness/unavailability of some replicas due to high memory load. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + faults: + - name: pod-memory-hog + description: Pod memory hog fault consumes memory resources of specified containers in Kubernetes pods. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/scenarios/podtato-head/workflow.yaml b/experiments/podtato-head/experiment.yaml similarity index 93% rename from scenarios/podtato-head/workflow.yaml rename to experiments/podtato-head/experiment.yaml index b8165d4..21c91e9 100644 --- a/scenarios/podtato-head/workflow.yaml +++ b/experiments/podtato-head/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-podtato-head-chaos- + name: argowf-podtato-head-chaos- namespace: litmus labels: subject : "{{workflow.parameters.adminModeNamespace}}_podtato-main" @@ -20,12 +20,12 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - - name: pod-delete template: pod-delete - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - name: delete-application template: delete-application @@ -34,7 +34,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=apply","-timeout=400", "-app=podtato-head","-scope=namespace"] - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -104,7 +104,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=delete","-app=podtato-head"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/podtato-head/workflow_cron.yaml b/experiments/podtato-head/experiment_cron.yaml similarity index 94% rename from workflows/podtato-head/workflow_cron.yaml rename to experiments/podtato-head/experiment_cron.yaml index 099a050..cdd470c 100644 --- a/workflows/podtato-head/workflow_cron.yaml +++ b/experiments/podtato-head/experiment_cron.yaml @@ -24,12 +24,12 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - - name: pod-delete template: pod-delete - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - name: delete-application template: delete-application @@ -38,7 +38,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=apply","-timeout=400", "-app=podtato-head","-scope=namespace"] - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -108,7 +108,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=delete","-app=podtato-head"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/podtato-head/podtato-head.chartserviceversion.yaml b/experiments/podtato-head/podtato-head.chartserviceversion.yaml new file mode 100644 index 0000000..3df7dbf --- /dev/null +++ b/experiments/podtato-head/podtato-head.chartserviceversion.yaml @@ -0,0 +1,28 @@ +apiVersion: litmuchaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: podtato-head + version: 0.1.0 + annotations: + categories: podtato-head + chartDescription: Injects chaos on podtato-head application +spec: + displayName: Podtato-head Chaos + categoryDescription: > + It installs podtato-head application, inject chaos on the application, uninstall the application, and reverts the chaos + faults: + - name: pod-delete + description: Pod delete fault disrupts the state of Kubernetes resources. This fault injects random pod delete failures against specified application. + keywords: + - Kubernetes + - Podtato-head + - Pod + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + icon: + - url: + mediatype: "" diff --git a/workflows/sock-shop-promProbe/workflow.yaml b/experiments/sock-shop-promProbe/experiment.yaml similarity index 95% rename from workflows/sock-shop-promProbe/workflow.yaml rename to experiments/sock-shop-promProbe/experiment.yaml index f407dda..6c6f74e 100644 --- a/workflows/sock-shop-promProbe/workflow.yaml +++ b/experiments/sock-shop-promProbe/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-sock-shop-resiliency- + name: argowf-chaos-sock-shop-resiliency- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_sock-shop" @@ -22,10 +22,10 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - name: load-test - template: load-test + template: load-test - - name: pod-cpu-hog template: pod-cpu-hog - - name: pod-delete @@ -35,9 +35,9 @@ spec: - - name: pod-memory-hog template: pod-memory-hog - - name: disk-fill - template: disk-fill - - - name: revert-chaos - template: revert-chaos + template: disk-fill + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources # - name: delete-application # template: delete-application - name: delete-loadtest @@ -48,14 +48,14 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=sock-shop","-typeName=resilient","-operation=apply","-timeout=400", "-app=sock-shop","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] args: - "kubectl apply -f https://hub.litmuschaos.io/api/chaos/master?file=charts/generic/experiments.yaml -n {{workflow.parameters.adminModeNamespace}} ; sleep 30" - + - name: pod-cpu-hog inputs: artifacts: @@ -107,7 +107,7 @@ spec: criteria: ">=" #supports >=,<=,>,<,==,!= comparision value: "100" mode: "Edge" - runProperties: + runProperties: probeTimeout: 1s interval: 100ms attempt: 2 @@ -121,7 +121,7 @@ spec: value: '30' # in seconds - name: CHAOS_KILL_COMMAND value: "kill -9 $(ps afx | grep \"[md5sum] /dev/zero\" | awk '{print$1}' | tr '\n' ' ')" - + container: image: litmuschaos/litmus-checker:latest args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] @@ -177,7 +177,7 @@ spec: criteria: ">=" #supports >=,<=,>,<,==,!= comparision value: "100" mode: "Edge" - runProperties: + runProperties: probeTimeout: 1s interval: 100ms attempt: 2 @@ -189,7 +189,7 @@ spec: value: '30' # in seconds - name: CHAOS_KILL_COMMAND value: "kill -9 $(ps afx | grep \"[dd] if /dev/zero\" | awk '{print $1}' | tr '\n' ' ')" - + container: image: litmuschaos/litmus-checker:latest args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] @@ -248,7 +248,7 @@ spec: criteria: ">=" #supports >=,<=,>,<,==,!= comparision value: "100" mode: "Edge" - runProperties: + runProperties: probeTimeout: 1s interval: 100ms attempt: 2 @@ -264,8 +264,8 @@ spec: value: 'false' container: image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - + args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] + - name: pod-network-loss inputs: artifacts: @@ -321,26 +321,26 @@ spec: criteria: ">=" #supports >=,<=,>,<,==,!= comparision value: "100" mode: "Edge" - runProperties: + runProperties: probeTimeout: 1s interval: 100ms attempt: 2 components: env: - name: TOTAL_CHAOS_DURATION - value: '30' + value: '30' - name: NETWORK_INTERFACE value: 'eth0' - name: NETWORK_PACKET_LOSS_PERCENTAGE value: '100' - name: CONTAINER_RUNTIME - value: 'containerd' + value: 'containerd' - name: SOCKET_PATH value: '/run/containerd/containerd.sock' container: image: litmuschaos/litmus-checker:latest args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - + - name: disk-fill inputs: artifacts: @@ -395,7 +395,7 @@ spec: criteria: ">=" #supports >=,<=,>,<,==,!= comparision value: "100" mode: "Edge" - runProperties: + runProperties: probeTimeout: 1s interval: 100ms attempt: 2 @@ -406,11 +406,11 @@ spec: - name: TARGET_CONTAINER value: '' - name: TOTAL_CHAOS_DURATION - value: '30' + value: '30' container: image: litmuschaos/litmus-checker:latest args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - + - name: delete-application container: image: litmuschaos/litmus-app-deployer:latest @@ -425,12 +425,12 @@ spec: container: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=loadtest","-operation=delete", "-app=loadtest"] - - - name: revert-chaos + + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] - args: - [ + args: + [ "kubectl delete chaosengine pod-memory-hog-chaos pod-cpu-hog-chaos catalogue-pod-delete-chaos pod-network-loss-chaos -n {{workflow.parameters.adminModeNamespace}}", ] \ No newline at end of file diff --git a/workflows/sock-shop-promProbe/workflow_cron.yaml b/experiments/sock-shop-promProbe/experiment_cron.yaml similarity index 98% rename from workflows/sock-shop-promProbe/workflow_cron.yaml rename to experiments/sock-shop-promProbe/experiment_cron.yaml index ff24599..ab218e3 100644 --- a/workflows/sock-shop-promProbe/workflow_cron.yaml +++ b/experiments/sock-shop-promProbe/experiment_cron.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: CronWorkflow metadata: - generateName: argowf-chaos-sock-shop-resiliency-cron-wf- + name: argowf-chaos-sock-shop-resiliency-cron-wf- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_sock-shop" @@ -26,8 +26,8 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - name: load-test template: load-test - - name: pod-cpu-hog @@ -40,8 +40,8 @@ spec: template: pod-memory-hog - - name: disk-fill template: disk-fill - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources # - name: delete-application # template: delete-application - name: delete-loadtest @@ -52,7 +52,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=sock-shop","-typeName=resilient","-operation=apply","-timeout=400", "-app=sock-shop","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -430,7 +430,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=loadtest","-operation=delete", "-app=loadtest"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/sock-shop-promProbe/sock-shop-promProbe.chartserviceversion.yaml b/experiments/sock-shop-promProbe/sock-shop-promProbe.chartserviceversion.yaml new file mode 100644 index 0000000..2e72593 --- /dev/null +++ b/experiments/sock-shop-promProbe/sock-shop-promProbe.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: sock-shop-promProbe + version: 0.1.0 + annotations: + categories: sock-shop-promProbe + chartDescription: Injects chaos on Sock Shop application and uses a prom probe to validate frontend API endpoint availability. +spec: + displayName: Sock Shop PromProbe + categoryDescription: > + It installs Sock Shop application, injects chaos on the application, uninstalls the application, and reverts the chaos + faults: + - name: sock-shop + description: Injects chaos on Sock Shop application and uses a prom probe to validate frontend API endpoint availability. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/workflows/sock-shop/workflow.yaml b/experiments/sock-shop/experiment.yaml similarity index 98% rename from workflows/sock-shop/workflow.yaml rename to experiments/sock-shop/experiment.yaml index 24076ce..4a3c544 100644 --- a/workflows/sock-shop/workflow.yaml +++ b/experiments/sock-shop/experiment.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos-sock-shop-resiliency- + name: argowf-chaos-sock-shop-resiliency- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_sock-shop" @@ -22,8 +22,8 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - name: load-test template: load-test - - name: pod-cpu-hog @@ -36,8 +36,8 @@ spec: template: pod-memory-hog - - name: disk-fill template: disk-fill - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources # - name: delete-application # template: delete-application - name: delete-loadtest @@ -48,7 +48,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=sock-shop","-typeName=resilient","-operation=apply","-timeout=400", "-app=sock-shop","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -430,7 +430,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=loadtest","-operation=delete", "-app=loadtest"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/workflows/sock-shop/workflow_cron.yaml b/experiments/sock-shop/experiment_cron.yaml similarity index 98% rename from workflows/sock-shop/workflow_cron.yaml rename to experiments/sock-shop/experiment_cron.yaml index 48417d9..0966740 100644 --- a/workflows/sock-shop/workflow_cron.yaml +++ b/experiments/sock-shop/experiment_cron.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: CronWorkflow metadata: - generateName: argowf-chaos-sock-shop-resiliency-cron-wf- + name: argowf-chaos-sock-shop-resiliency-cron-wf- namespace: litmus labels: subject: "{{workflow.parameters.appNamespace}}_sock-shop" @@ -26,8 +26,8 @@ spec: steps: - - name: install-application template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments + - - name: install-chaos-faults + template: install-chaos-faults - name: load-test template: load-test - - name: pod-cpu-hog @@ -40,8 +40,8 @@ spec: template: pod-memory-hog - - name: disk-fill template: disk-fill - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources # - name: delete-application # template: delete-application - name: delete-loadtest @@ -52,7 +52,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=sock-shop","-typeName=resilient","-operation=apply","-timeout=400", "-app=sock-shop","-scope=cluster"] #for weak provide type flagName as resilient(-typeName=weak) - - name: install-chaos-experiments + - name: install-chaos-faults container: image: litmuschaos/k8s:latest command: [sh, -c] @@ -434,7 +434,7 @@ spec: image: litmuschaos/litmus-app-deployer:latest args: ["-namespace=loadtest","-operation=delete", "-app=loadtest"] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: litmuschaos/k8s:latest command: [sh, -c] diff --git a/experiments/sock-shop/sock-shop.chartserviceversion.yaml b/experiments/sock-shop/sock-shop.chartserviceversion.yaml new file mode 100644 index 0000000..f447d17 --- /dev/null +++ b/experiments/sock-shop/sock-shop.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: sock-shop + version: 0.1.0 + annotations: + categories: sock-shop + chartDescription: Injects chaos on Sock Shop application. +spec: + displayName: Sock Shop + categoryDescription: > + It installs Sock Shop application, injects chaos on the application, uninstalls the application, and reverts the chaos + faults: + - name: sock-shop + description: Injects chaos on Sock Shop application. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - OpenShift(OKD) + icon: + - url: + mediatype: "" diff --git a/experiments/vmware/experiments.yaml b/experiments/vmware/experiments.yaml deleted file mode 100644 index 61882e3..0000000 --- a/experiments/vmware/experiments.yaml +++ /dev/null @@ -1,99 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops one or more VMs for a certain chaos duration. -kind: ChaosExperiment -metadata: - name: vm-poweroff - labels: - name: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name vm-poweroff - command: - - /bin/bash - env: - - - name: VCENTERSERVER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERSERVER - - - name: VCENTERUSER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERUSER - - - name: VCENTERPASS - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERPASS - - # provide the VM MOIDs as comma separated values - - name: APP_VM_MOIDS - value: '' - - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos interval (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - - name: RAMP_TIME - value: '' - - # parallel or sequence; the mode of chaos sequence, defaults to parallel - - name: SEQUENCE - value: 'parallel' - - labels: - experiment: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest - ---- diff --git a/experiments/vmware/icons/vm-poweroff.png b/experiments/vmware/icons/vm-poweroff.png deleted file mode 100644 index 50807e5..0000000 Binary files a/experiments/vmware/icons/vm-poweroff.png and /dev/null differ diff --git a/experiments/vmware/icons/vmware.png b/experiments/vmware/icons/vmware.png deleted file mode 100644 index 50807e5..0000000 Binary files a/experiments/vmware/icons/vmware.png and /dev/null differ diff --git a/experiments/vmware/vm-poweroff/experiment.yaml b/experiments/vmware/vm-poweroff/experiment.yaml deleted file mode 100644 index 1562815..0000000 --- a/experiments/vmware/vm-poweroff/experiment.yaml +++ /dev/null @@ -1,97 +0,0 @@ -apiVersion: litmuschaos.io/v1alpha1 -description: - message: | - Stops one or more VMs for a certain chaos duration. -kind: ChaosExperiment -metadata: - name: vm-poweroff - labels: - name: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest -spec: - definition: - scope: Cluster - permissions: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name vm-poweroff - command: - - /bin/bash - env: - - - name: VCENTERSERVER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERSERVER - - - name: VCENTERUSER - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERUSER - - - name: VCENTERPASS - valueFrom: - secretKeyRef: - name: vcenter-secret - key: VCENTERPASS - - # provide the VM MOIDs as comma separated values - - name: APP_VM_MOIDS - value: '' - - # set chaos duration (in sec) as desired - - name: TOTAL_CHAOS_DURATION - value: '30' - - # set chaos interval (in sec) as desired - - name: CHAOS_INTERVAL - value: '30' - - - name: LIB - value: 'litmus' - - - name: RAMP_TIME - value: '' - - # parallel or sequence; the mode of chaos sequence, defaults to parallel - - name: SEQUENCE - value: 'parallel' - - labels: - experiment: vm-poweroff - app.kubernetes.io/part-of: litmus - app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest diff --git a/experiments/vmware/vm-poweroff/rbac.yaml b/experiments/vmware/vm-poweroff/rbac.yaml deleted file mode 100644 index 4bbd8ee..0000000 --- a/experiments/vmware/vm-poweroff/rbac.yaml +++ /dev/null @@ -1,63 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: vm-poweroff-sa - namespace: default - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: vm-poweroff-sa - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus -rules: - # Create and monitor the experiment & helper pods - - apiGroups: [""] - resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] - # Performs CRUD operations on the events inside chaosengine and chaosresult - - apiGroups: [""] - resources: ["events"] - verbs: ["create","get","list","patch","update"] - # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - - apiGroups: [""] - resources: ["secrets","configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log - - apiGroups: [""] - resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container - - apiGroups: [""] - resources: ["pods/exec"] - verbs: ["get","list","create"] - # for configuring and monitor the experiment job by the chaos-runner pod - - apiGroups: ["batch"] - resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] - # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: vm-poweroff-sa - labels: - name: vm-poweroff-sa - app.kubernetes.io/part-of: litmus -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: vm-poweroff-sa -subjects: -- kind: ServiceAccount - name: vm-poweroff-sa - namespace: default - diff --git a/experiments/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml b/experiments/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml deleted file mode 100644 index 0b2ad00..0000000 --- a/experiments/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-29T10:28:08Z - name: vm-poweroff - annotations: - categories: vmware - vendor: Wipro, ChaosNative - support: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN -spec: - displayName: vm-poweroff - categoryDescription: | - This experiment causes power-off of target VMWare VM(s) for a certain chaos duration: - - Causes power-off of the VMWare VM(s) provided by the Moid(s) of the instance. - - It helps to check the performance of the application/services on the instance. - - Currently, the experiment is supported for vsphere version 6.X (Support for 7.X will be added soon). - - keywords: - - Vmware - - VM - platforms: - - vmware - maturity: alpha - maintainers: - - name: Delphine Joyneer, Neelanjan Manna - email: golkonda.joyneer@wipro.com, neelanjan@chaosnative.com - provider: - name: Wipro, ChaosNative - labels: - app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest - links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/vmware/vm-poweroff - - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/vmware/vm-poweroff/ - - name: Video - url: - icon: - - url: - mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/vmware/vm-poweroff/experiment.yaml diff --git a/experiments/vmware/vmware.chartserviceversion.yaml b/experiments/vmware/vmware.chartserviceversion.yaml deleted file mode 100644 index 1d04eab..0000000 --- a/experiments/vmware/vmware.chartserviceversion.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-04-29T10:28:08Z - name: vmware - version: 0.1.0 - annotations: - categories: vmware - chartDescription: Injects chaos on VMWare components -spec: - displayName: VMWare Chaos - categoryDescription: > - Contains chaos to disrupt the state of VMWare resources - experiments: - - name: vm-poweroff - description: "" - keywords: - - vmware - - VM - maintainers: - - name: Delphine Joyneer, Neelanjan Manna - email: golkonda.joyneer@wipro.com, neelanjan@chaosnative.com - provider: - name: Wipro, ChaosNative - links: - - name: Kubernetes Website - url: https://kubernetes.io - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/vmware - - name: Community Slack - url: https://app.slack.com/client/T09NY5SBT/CNXNB0ZTN - icon: - - url: - mediatype: - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/vmware/experiments.yaml diff --git a/experiments/vmware/vmware.package.yaml b/experiments/vmware/vmware.package.yaml deleted file mode 100644 index 3fe0e48..0000000 --- a/experiments/vmware/vmware.package.yaml +++ /dev/null @@ -1,5 +0,0 @@ -packageName: vmware -experiments: - - name: vm-poweroff - CSV: vm-poweroff.chartserviceversion.yaml - desc: "vm-poweroff" diff --git a/faults/aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml b/faults/aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml new file mode 100644 index 0000000..ed08e80 --- /dev/null +++ b/faults/aws/aws-az-chaos/aws-az-chaos.chartserviceversion.yaml @@ -0,0 +1,32 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-26T10:28:08Z + name: aws-az-chaos + version: 0.1.0 + annotations: + categories: Kube AWS + vendor: LitmusChaos +spec: + displayName: AWS AZ Chaos + categoryDescription: | + Execute AWS AZ chaos to detach the target zones from the load balancer for a certain chaos duration. + keywords: + - AWS + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/kube-aws/aws-az-chaos/engine.yaml b/faults/aws/aws-az-chaos/engine.yaml old mode 100755 new mode 100644 similarity index 89% rename from charts/kube-aws/aws-az-chaos/engine.yaml rename to faults/aws/aws-az-chaos/engine.yaml index a7afbbc..c64d288 --- a/charts/kube-aws/aws-az-chaos/engine.yaml +++ b/faults/aws/aws-az-chaos/engine.yaml @@ -1,11 +1,12 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: aws-az-chaos + name: az-chaos-engine + namespace: default spec: - # It can be active/stop engineState: 'active' - chaosServiceAccount: aws-az-chaos-sa + chaosServiceAccount: litmus-admin experiments: - name: aws-az-chaos spec: diff --git a/charts/kube-aws/aws-az-chaos/experiment.yaml b/faults/aws/aws-az-chaos/fault.yaml old mode 100755 new mode 100644 similarity index 73% rename from charts/kube-aws/aws-az-chaos/experiment.yaml rename to faults/aws/aws-az-chaos/fault.yaml index 921723b..aa939b3 --- a/charts/kube-aws/aws-az-chaos/experiment.yaml +++ b/faults/aws/aws-az-chaos/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Execute aws-az chaos to detach the target zones from the load balancer + It injects AZ chaos to detach the target zones from the load balancer. kind: ChaosExperiment metadata: name: aws-az-chaos @@ -9,7 +10,7 @@ metadata: name: aws-az-chaos app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -26,10 +27,10 @@ spec: - apiGroups: [""] resources: ["secrets","configmaps"] verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] + verbs: ["get","list","watch"] # for creating and managing to execute comands inside target container - apiGroups: [""] resources: ["pods/exec"] @@ -45,32 +46,32 @@ spec: image: "litmuschaos/py-runner:latest" imagePullPolicy: Always args: - - -c - - python3 -u experiment -name aws-az-chaos + - -c + - python3 -u experiment -name aws-az-chaos command: - - /bin/bash + - /bin/bash env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - name: CHAOS_INTERVAL - value: '30' - - name: LIB - value: 'litmus' - - name: LOAD_BALANCER_NAME - value: '' - - name: LOAD_BALANCER_ZONES - value: '' - - name: LOAD_BALANCERNAME_ARN - value: 'na' - - name: AWS_SHARED_CREDENTIALS_FILE - value: "/tmp/cloud_config.yml" - - name: RAMP_TIME - value: '' + - name: TOTAL_CHAOS_DURATION + value: '30' + - name: CHAOS_INTERVAL + value: '30' + - name: LIB + value: 'litmus' + - name: LOAD_BALANCER_NAME + value: '' + - name: LOAD_BALANCER_ZONES + value: '' + - name: LOAD_BALANCERNAME_ARN + value: 'na' + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + - name: RAMP_TIME + value: '' labels: name: aws-az-chaos app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job app.kubernetes.io/version: latest secrets: - - name: cloud-secret - mountPath: /tmp/ + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml b/faults/aws/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml new file mode 100644 index 0000000..834ce90 --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-id/aws-ssm-chaos-by-id.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-27T10:28:08Z + name: aws-ssm-chaos-by-id + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: AWS SSM Chaos By ID + categoryDescription: | + AWS SSM Chaos By ID fault disrupts the state of infra resources. The fault induces chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos faults on resources. + - Causes chaos on AWS EC2 instances with given instance ID(s) using SSM docs for total chaos duration with the specified chaos interval. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/faults/aws/aws-ssm-chaos-by-id/engine.yaml b/faults/aws/aws-ssm-chaos-by-id/engine.yaml new file mode 100644 index 0000000..c00f6c9 --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-id/engine.yaml @@ -0,0 +1,39 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChaosEngine +metadata: + name: aws-chaos + namespace: default +spec: + engineState: 'active' + chaosServiceAccount: litmus-admin + experiments: + - name: aws-ssm-chaos-by-id + spec: + components: + env: + # set chaos duration (in sec) as desired + - name: TOTAL_CHAOS_DURATION + value: '60' + + # set chaos duration (in sec) as desired + - name: CHAOS_INTERVAL + value: '60' + + # Instance ID of the target EC2 instance + # Multiple IDs can also be provided as comma separated values ex: id1,id2 + - name: EC2_INSTANCE_ID + value: '' + + # provide the region name of the target instances + - name: REGION + value: '' + + # provide the percentage of available memory to stress + - name: MEMORY_PERCENTAGE + value: '80' + + # provide the CPU chores to be comsumed + # 0 will consume all the available CPU cores + - name: CPU_CORE + value: '0' diff --git a/faults/aws/aws-ssm-chaos-by-id/fault.yaml b/faults/aws/aws-ssm-chaos-by-id/fault.yaml new file mode 100644 index 0000000..429cb6f --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-id/fault.yaml @@ -0,0 +1,137 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Execute AWS SSM Chaos on given EC2 instance IDs +kind: ChaosExperiment +metadata: + name: aws-ssm-chaos-by-id + labels: + name: aws-ssm-chaos-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name aws-ssm-chaos-by-id + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "60" + + - name: CHAOS_INTERVAL + value: "60" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # Instance ID of the target EC2 instance + # Multiple IDs can also be provided as comma separated values ex: id1,id2 + - name: EC2_INSTANCE_ID + value: "" + + - name: REGION + value: "" + + # it defines the sequence of chaos execution for multiple target instances + # supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + # provide the number of workers for memory stress + - name: NUMBER_OF_WORKERS + value: "1" + + # provide the percentage of available memory to stress + - name: MEMORY_PERCENTAGE + value: "80" + + # provide the CPU chores to be consumed + # 0 will consume all the available CPU cores + - name: CPU_CORE + value: "0" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # Provide the name of SSM doc + # if not using the default stress docs + - name: DOCUMENT_NAME + value: "LitmusChaos-AWS-SSM-Doc" + + # Provide the type of SSM doc + # if not using the default stress docs + - name: DOCUMENT_TYPE + value: "Command" + + # Provide the format of SSM doc + # if not using the default stress docs + - name: DOCUMENT_FORMAT + value: "YAML" + + # Provide the path of SSM doc + # if not using the default stress docs + - name: DOCUMENT_PATH + value: "Litmus-AWS-SSM-Docs-For-EC2-CPU-Hog.yml" + + # if you want to install dependencies to run default SSM docs + - name: INSTALL_DEPENDENCIES + value: "True" + + labels: + name: aws-ssm-chaos-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml b/faults/aws/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml new file mode 100644 index 0000000..fda10bb --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-tag/aws-ssm-chaos-by-tag.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-27T10:28:08Z + name: aws-ssm-chaos-by-tag + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: AWS SSM Chaos By Tag + categoryDescription: | + AWS SSM Chaos By Tag fault disrupts the state of infra resources. The fault induces chaos on AWS resources using Amazon SSM Run Command This is carried out by using SSM Docs that defines the actions performed by Systems Manager on your managed instances (having SSM agent installed) which let us perform chaos faults on resources. + - Causes chaos on AWS EC2 instances with given instance tag using SSM docs for total chaos duration with the specified chaos interval. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the target application pod(if provided). + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/faults/aws/aws-ssm-chaos-by-tag/engine.yaml b/faults/aws/aws-ssm-chaos-by-tag/engine.yaml new file mode 100644 index 0000000..d66dd36 --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-tag/engine.yaml @@ -0,0 +1,39 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChaosEngine +metadata: + name: nginx-chaos + namespace: default +spec: + engineState: 'active' + chaosServiceAccount: litmus-admin + experiments: + - name: aws-ssm-chaos-by-tag + spec: + components: + env: + # set chaos duration (in sec) as desired + - name: TOTAL_CHAOS_DURATION + value: '60' + + # set chaos duration (in sec) as desired + - name: CHAOS_INTERVAL + value: '60' + + # provide tag of the target EC2 instances + # ex: team:devops (key:value) + - name: EC2_INSTANCE_TAG + value: '' + + # provide the region name of the target instances + - name: REGION + value: '' + + # provide the percentage of available memory to stress + - name: MEMORY_PERCENTAGE + value: '80' + + # provide the CPU chores to comsumed + # 0 will consume all the available CPU cores + - name: CPU_CORE + value: '0' diff --git a/faults/aws/aws-ssm-chaos-by-tag/fault.yaml b/faults/aws/aws-ssm-chaos-by-tag/fault.yaml new file mode 100644 index 0000000..f258222 --- /dev/null +++ b/faults/aws/aws-ssm-chaos-by-tag/fault.yaml @@ -0,0 +1,141 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Execute AWS SSM Chaos on given EC2 instance Tag +kind: ChaosExperiment +metadata: + name: aws-ssm-chaos-by-tag + labels: + name: aws-ssm-chaos-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name aws-ssm-chaos-by-tag + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "60" + + - name: CHAOS_INTERVAL + value: "60" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide tag of the target EC2 instances + # ex: team:devops (key:value) + - name: EC2_INSTANCE_TAG + value: "" + + - name: REGION + value: "" + + # it defines the sequence of chaos execution for multiple target instances + # supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + # percentage of total instance to target + - name: INSTANCE_AFFECTED_PERC + value: "" + + # provide the number of workers for memory stress + - name: NUMBER_OF_WORKERS + value: "1" + + # provide the percentage of available memory to stress + - name: MEMORY_PERCENTAGE + value: "80" + + # provide the CPU chores to comsumed + # 0 will consume all the available CPU cores + - name: CPU_CORE + value: "0" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # Provide the name of SSM doc + # if not using the default stress docs + - name: DOCUMENT_NAME + value: "LitmusChaos-AWS-SSM-Doc" + + # Provide the type of SSM doc + # if not using the default stress docs + - name: DOCUMENT_TYPE + value: "Command" + + # Provide the format of SSM doc + # if not using the default stress docs + - name: DOCUMENT_FORMAT + value: "YAML" + + # Provide the path of SSM doc + # if not using the default stress docs + - name: DOCUMENT_PATH + value: "Litmus-AWS-SSM-Docs-For-EC2-CPU-Hog.yml" + + # if you want to install dependencies to run default SSM docs + - name: INSTALL_DEPENDENCIES + value: "True" + + labels: + name: aws-ssm-chaos-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/aws.chartserviceversion.yaml b/faults/aws/aws.chartserviceversion.yaml new file mode 100644 index 0000000..0a57129 --- /dev/null +++ b/faults/aws/aws.chartserviceversion.yaml @@ -0,0 +1,51 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: aws + version: 0.1.0 + annotations: + categories: AWS + chartDescription: Injects faults on AWS services + executionPlane: "kubernetes" +spec: + displayName: AWS + categoryDescription: > + AWS chaos contains different faults for AWS cloud provider to test the app/platform service availability. It uses AWS command to carry the fault logic in the instance. It will install all the faults which can be used to inject chaos into the AWS services like EC2, ECS, S3 and so on. + faults: + - name: alb-az-down + description: It injects AZ down chaos on ALB for a certain chaos duration. + displayName: "ALB AZ Down" + - name: aws-ssm-chaos-by-id + description: It allow to perform in-VM chaos using AWS SSM service and EC2 instance ID. + displayName: "AWS SSM Chaos By ID" + - name: aws-ssm-chaos-by-tag + description: It allow to perform in-VM chaos using AWS SSM service and EC2 instance tag. + displayName: "AWS SSM Chaos By Tag" + - name: ec2-terminate-by-id + description: It stops the AWS EC2 instance identified by ID for a certain chaos duration. + displayName: "EC2 Stop By ID" + - name: ec2-terminate-by-tag + description: It stops the AWS EC2 instance identified by Tag for a certain chaos duration. + displayName: "EC2 Stop By Tag" + - name: ebs-loss-by-id + description: It detach the EBS volume from AWS EC2 instance identified by ID for a certain chaos duration. + displayName: "EBS Loss By ID" + - name: ebs-loss-by-tag + description: It detach the EBS volume from AWS EC2 instance identified by Tag for a certain chaos duration. + displayName: "EBS Loss By Tag" + keywords: + - AWS + minKubeVersion: 1.12.0 + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Kubernetes Slack + url: https://slack.kubernetes.io/ + - name: Documentation + url: "https://litmuschaos.github.io/litmus/experiments/categories/contents/#aws" + icon: + - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico + mediatype: image/png diff --git a/faults/aws/aws.package.yaml b/faults/aws/aws.package.yaml new file mode 100644 index 0000000..a063d07 --- /dev/null +++ b/faults/aws/aws.package.yaml @@ -0,0 +1,24 @@ +--- +packageName: aws +faults: + - name: alb-az-down + CSV: alb-az-down.chartserviceversion.yaml + desc: "alb-az-down" + - name: aws-ssm-chaos-by-id + CSV: aws-ssm-chaos-by-id.chartserviceversion.yaml + desc: "aws-ssm-chaos-by-id" + - name: aws-ssm-chaos-by-tag + CSV: aws-ssm-chaos-by-tag.chartserviceversion.yaml + desc: "aws-ssm-chaos-by-tag" + - name: ec2-terminate-by-id + CSV: ec2-terminate-by-id.chartserviceversion.yaml + desc: "ec2-terminate-by-id" + - name: ec2-terminate-by-tag + CSV: ec2-terminate-by-tag.chartserviceversion.yaml + desc: "ec2-terminate-by-tag" + - name: ebs-loss-by-id + CSV: ebs-loss-by-id.chartserviceversion.yaml + desc: "ebs-loss-by-id" + - name: ebs-loss-by-tag + CSV: ebs-loss-by-tag.chartserviceversion.yaml + desc: "ebs-loss-by-tag" diff --git a/faults/aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml b/faults/aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml new file mode 100644 index 0000000..7eae2e5 --- /dev/null +++ b/faults/aws/ebs-loss-by-id/ebs-loss-by-id.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-28T10:28:08Z + name: ebs-loss-by-id + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: EBS Loss By ID + categoryDescription: | + EBS Loss By ID fault disrupts state of infra resources. The fault induces EBS volume loss against specified application for the give EBS Volume(s). + - Causes EBS volume loss from node or EC2 instance for a certain chaos interval from total chaos duration. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/kube-aws/ebs-loss-by-id/engine.yaml b/faults/aws/ebs-loss-by-id/engine.yaml similarity index 78% rename from charts/kube-aws/ebs-loss-by-id/engine.yaml rename to faults/aws/ebs-loss-by-id/engine.yaml index cdb3010..5d96eb0 100644 --- a/charts/kube-aws/ebs-loss-by-id/engine.yaml +++ b/faults/aws/ebs-loss-by-id/engine.yaml @@ -1,25 +1,26 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: nginx-chaos + name: aws-chaos namespace: default spec: engineState: 'active' - chaosServiceAccount: ebs-loss-by-id-sa + chaosServiceAccount: litmus-admin experiments: - name: ebs-loss-by-id spec: components: - env: + env: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '30' # set chaos duration (in sec) as desired - name: CHAOS_INTERVAL - value: '30' + value: '30' - # set target ebs volume ID + # set target EBS volume ID - name: EBS_VOLUME_ID value: '' diff --git a/faults/aws/ebs-loss-by-id/fault.yaml b/faults/aws/ebs-loss-by-id/fault.yaml new file mode 100644 index 0000000..4f9eb73 --- /dev/null +++ b/faults/aws/ebs-loss-by-id/fault.yaml @@ -0,0 +1,96 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Detaching an EBS volume from EC2 instance for a certain chaos duration. +kind: ChaosExperiment +metadata: + name: ebs-loss-by-id + labels: + name: ebs-loss-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name ebs-loss-by-id + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: EBS_VOLUME_ID + value: "" + + - name: REGION + value: "" + + - name: SEQUENCE + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + labels: + name: ebs-loss-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml b/faults/aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml new file mode 100644 index 0000000..cd3bf7d --- /dev/null +++ b/faults/aws/ebs-loss-by-tag/ebs-loss-by-tag.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-28T10:28:08Z + name: ebs-loss-by-tag + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: EBS Loss By Tag + categoryDescription: | + EBS Loss By Tag fault disrupts state of infra resources. The fault induces EBS volume loss against specified application for given volume tag. + - Causes EBS volume loss by tag from node or EC2 instance for certain chaos interval from total chaos duration. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/kube-aws/ebs-loss-by-tag/engine.yaml b/faults/aws/ebs-loss-by-tag/engine.yaml similarity index 79% rename from charts/kube-aws/ebs-loss-by-tag/engine.yaml rename to faults/aws/ebs-loss-by-tag/engine.yaml index a9212ef..43d12bc 100644 --- a/charts/kube-aws/ebs-loss-by-tag/engine.yaml +++ b/faults/aws/ebs-loss-by-tag/engine.yaml @@ -1,16 +1,17 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: nginx-chaos + name: aws-chaos namespace: default spec: engineState: 'active' - chaosServiceAccount: ebs-loss-by-tag-sa + chaosServiceAccount: litmus-admin experiments: - name: ebs-loss-by-tag spec: components: - env: + env: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '30' @@ -21,12 +22,11 @@ spec: # provide EBS volume tag attached to the given instance # it'll be in form of key:value (ex: 'team:devops') - name: EBS_VOLUME_TAG - value: '' - + value: '' + # provide the region name of the instance - name: REGION value: '' - name: VOLUME_AFFECTED_PERC - value: '' - \ No newline at end of file + value: '' diff --git a/faults/aws/ebs-loss-by-tag/fault.yaml b/faults/aws/ebs-loss-by-tag/fault.yaml new file mode 100644 index 0000000..e588343 --- /dev/null +++ b/faults/aws/ebs-loss-by-tag/fault.yaml @@ -0,0 +1,98 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Detaching an EBS volume from EC2 instance. +kind: ChaosExperiment +metadata: + name: ebs-loss-by-tag + labels: + name: ebs-loss-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name ebs-loss-by-tag + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + - name: RAMP_TIME + value: "" + + - name: EBS_VOLUME_TAG + value: "" + + - name: REGION + value: "" + + - name: SEQUENCE + value: "parallel" + + - name: VOLUME_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + labels: + name: ebs-loss-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/ec2-stop-by-tag/ec2-stop-by-tag.chartserviceversion.yaml b/faults/aws/ec2-stop-by-tag/ec2-stop-by-tag.chartserviceversion.yaml new file mode 100644 index 0000000..574364d --- /dev/null +++ b/faults/aws/ec2-stop-by-tag/ec2-stop-by-tag.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-27T10:28:08Z + name: ec2-stop-by-tag + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: EC2 Stop By Tag + categoryDescription: | + This fault causes termination of an EC2 instance for a certain chaos duration. + - Causes termination of an EC2 instance using instance tags before bringing it back to running state after the specified chaos duration. + - It helps to check the performance of the application on the EC2 instance. + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/kube-aws/ec2-terminate-by-tag/engine.yaml b/faults/aws/ec2-stop-by-tag/engine.yaml similarity index 75% rename from charts/kube-aws/ec2-terminate-by-tag/engine.yaml rename to faults/aws/ec2-stop-by-tag/engine.yaml index 6ed309d..909409c 100644 --- a/charts/kube-aws/ec2-terminate-by-tag/engine.yaml +++ b/faults/aws/ec2-stop-by-tag/engine.yaml @@ -1,29 +1,30 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: nginx-chaos + name: aws-chaos namespace: default spec: engineState: 'active' - chaosServiceAccount: ec2-terminate-by-tag-sa + chaosServiceAccount: litmus-admin experiments: - - name: ec2-terminate-by-tag + - name: ec2-stop-by-tag spec: components: - env: + env: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '30' # set interval duration (in sec) as desired - name: CHAOS_INTERVAL - value: '30' + value: '30' - # Instance Tag of the target ec2 instances + # Instance Tag of the target EC2 instances # ex: team:devops (key:value) - - name: INSTANCE_TAG + - name: EC2_INSTANCE_TAG value: '' - + # provide the region name of the instance - name: REGION value: '' @@ -31,7 +32,7 @@ spec: # enable it if the target instance is a part of self-managed nodegroup. - name: MANAGED_NODEGROUP value: 'disable' - + # Target the percentage of instance filtered from tag - name: INSTANCE_AFFECTED_PERC value: '' diff --git a/faults/aws/ec2-stop-by-tag/fault.yaml b/faults/aws/ec2-stop-by-tag/fault.yaml new file mode 100644 index 0000000..68665a0 --- /dev/null +++ b/faults/aws/ec2-stop-by-tag/fault.yaml @@ -0,0 +1,112 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Stopping an EC2 instance identified by tag. +kind: ChaosExperiment +metadata: + name: ec2-stop-by-tag + labels: + name: ec2-stop-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name ec2-stop-by-tag + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # Provide a common tag to target ec2 instances + - name: EC2_INSTANCE_TAG + value: "" + + # enable it if the target instance is a part of self-managed nodegroup. + - name: MANAGED_NODEGROUP + value: "disable" + + - name: REGION + value: "" + + # Target the percentage of instance filtered from tag + - name: INSTANCE_AFFECTED_PERC + value: "" + + - name: SEQUENCE + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + - name: SEQUENCE + value: "parallel" + + labels: + name: ec2-stop-by-tag + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml b/faults/aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml new file mode 100644 index 0000000..c2be4b8 --- /dev/null +++ b/faults/aws/ec2-terminate-by-id/ec2-terminate-by-id.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-27T10:28:08Z + name: ec2-terminate-by-id + version: 0.1.0 + annotations: + categories: AWS + vendor: LitmusChaos +spec: + displayName: EC2 Terminate By ID + categoryDescription: | + This fault causes termination of an EC2 instance for a certain chaos duration. + - Causes termination of an EC2 instance provided by instance ID before bringing it back to running state after the specified chaos duration. + - It helps to check the performance of the application on the EC2 instances. + keywords: + - AWS + platforms: + - AWS + chaosType: infra + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/experiments/kube-aws/ec2-terminate-by-id/engine.yaml b/faults/aws/ec2-terminate-by-id/engine.yaml similarity index 80% rename from experiments/kube-aws/ec2-terminate-by-id/engine.yaml rename to faults/aws/ec2-terminate-by-id/engine.yaml index efceae8..9ae94f2 100644 --- a/experiments/kube-aws/ec2-terminate-by-id/engine.yaml +++ b/faults/aws/ec2-terminate-by-id/engine.yaml @@ -1,16 +1,17 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: nginx-chaos + name: aws-chaos namespace: default spec: engineState: 'active' - chaosServiceAccount: ec2-terminate-by-id-sa + chaosServiceAccount: litmus-admin experiments: - name: ec2-terminate-by-id spec: components: - env: + env: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '30' @@ -19,15 +20,15 @@ spec: - name: CHAOS_INTERVAL value: '30' - # Instance ID of the target ec2 instance + # Instance ID of the target EC2 instance # Multiple IDs can also be provided as comma separated values ex: id1,id2 - name: EC2_INSTANCE_ID value: '' - + # provide the region name of the instance - name: REGION value: '' # enable it if the target instance is a part of self-managed nodegroup. - name: MANAGED_NODEGROUP - value: 'disable' \ No newline at end of file + value: 'disable' diff --git a/faults/aws/ec2-terminate-by-id/fault.yaml b/faults/aws/ec2-terminate-by-id/fault.yaml new file mode 100644 index 0000000..4c6711c --- /dev/null +++ b/faults/aws/ec2-terminate-by-id/fault.yaml @@ -0,0 +1,106 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Stopping an EC2 instance identified by ID. +kind: ChaosExperiment +metadata: + name: ec2-terminate-by-id + labels: + name: ec2-terminate-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name ec2-terminate-by-id + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # enable it if the target instance is a part of self-managed nodegroup. + - name: MANAGED_NODEGROUP + value: "disable" + + # Instance ID of the target EC2 instance + # Multiple IDs can also be provided as comma separated values ex: id1,id2 + - name: EC2_INSTANCE_ID + value: "" + + - name: REGION + value: "" + + - name: SEQUENCE + value: "parallel" + + # Provide the path of AWS credentials mounted from secret + - name: AWS_SHARED_CREDENTIALS_FILE + value: "/tmp/cloud_config.yml" + + labels: + name: ec2-terminate-by-id + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/aws/icons/alb-az-down.png b/faults/aws/icons/alb-az-down.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/alb-az-down.png differ diff --git a/faults/aws/icons/aws-ssm-chaos-by-id.png b/faults/aws/icons/aws-ssm-chaos-by-id.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/aws-ssm-chaos-by-id.png differ diff --git a/faults/aws/icons/aws-ssm-chaos-by-tag.png b/faults/aws/icons/aws-ssm-chaos-by-tag.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/aws-ssm-chaos-by-tag.png differ diff --git a/charts/aws-ssm/icons/aws-ssm-chaos-by-id.png b/faults/aws/icons/aws.png similarity index 100% rename from charts/aws-ssm/icons/aws-ssm-chaos-by-id.png rename to faults/aws/icons/aws.png diff --git a/faults/aws/icons/ebs-loss-by-id.png b/faults/aws/icons/ebs-loss-by-id.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/ebs-loss-by-id.png differ diff --git a/faults/aws/icons/ebs-loss-by-tag.png b/faults/aws/icons/ebs-loss-by-tag.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/ebs-loss-by-tag.png differ diff --git a/faults/aws/icons/ec2-terminate-by-id.png b/faults/aws/icons/ec2-terminate-by-id.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/ec2-terminate-by-id.png differ diff --git a/faults/aws/icons/ec2-terminate-by-tag.png b/faults/aws/icons/ec2-terminate-by-tag.png new file mode 100644 index 0000000..f288523 Binary files /dev/null and b/faults/aws/icons/ec2-terminate-by-tag.png differ diff --git a/faults/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml b/faults/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml new file mode 100644 index 0000000..34e6ae6 --- /dev/null +++ b/faults/azure/azure-disk-loss/azure-disk-loss.chartserviceversion.yaml @@ -0,0 +1,24 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-18T10:28:08Z + name: azure-disk-loss + version: 0.1.0 + annotations: + categories: Azure + vendor: LitmusChaos +spec: + displayName: Azure Disk Loss + categoryDescription: | + This fault causes the detachment of the disk from the VM for a certain chaos duration. + - Causes detachment of the disk from the VM and then re-attachment of the disk to the VM. + - It helps to check the performance of the application on the instance. + keywords: + - Azure + platforms: + - Azure + minKubeVersion: 1.12.0 + icon: + - url: + mediatype: "" diff --git a/experiments/azure/azure-disk-loss/engine.yaml b/faults/azure/azure-disk-loss/engine.yaml similarity index 86% rename from experiments/azure/azure-disk-loss/engine.yaml rename to faults/azure/azure-disk-loss/engine.yaml index 18d029f..f753c17 100644 --- a/experiments/azure/azure-disk-loss/engine.yaml +++ b/faults/azure/azure-disk-loss/engine.yaml @@ -1,11 +1,12 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: nginx-chaos + name: azure-chaos spec: # It can be active/stop engineState: 'active' - chaosServiceAccount: azure-disk-loss-sa + chaosServiceAccount: litmus-admin experiments: - name: azure-disk-loss spec: @@ -18,15 +19,15 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '30' - + # provide the resource group of the instance - name: RESOURCE_GROUP value: '' - + # accepts enable/disable, default is disable - name: SCALE_SET value: '' - + # provide the virtual disk names (comma separated if multiple) - name: VIRTUAL_DISK_NAMES - value: '' \ No newline at end of file + value: '' diff --git a/faults/azure/azure-disk-loss/fault.yaml b/faults/azure/azure-disk-loss/fault.yaml new file mode 100644 index 0000000..9106ea1 --- /dev/null +++ b/faults/azure/azure-disk-loss/fault.yaml @@ -0,0 +1,103 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Detaches disk from the VM and then re-attaches disk to the VM +kind: ChaosExperiment +metadata: + name: azure-disk-loss + labels: + name: azure-disk-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name azure-disk-loss + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide the resource group of the instance + - name: RESOURCE_GROUP + value: "" + + # accepts enable/disable, default is disable + - name: SCALE_SET + value: "" + + # provide the virtual disk names (comma separated if multiple) + - name: VIRTUAL_DISK_NAMES + value: "" + + # provide the sequence type for the run. Options: serial/parallel + - name: SEQUENCE + value: "parallel" + + # provide the path to aks credentials mounted from secret + - name: AZURE_AUTH_LOCATION + value: "/tmp/azure.auth" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + labels: + name: azure-disk-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml b/faults/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml new file mode 100644 index 0000000..e87bbf9 --- /dev/null +++ b/faults/azure/azure-instance-stop/azure-instance-stop.chartserviceversion.yaml @@ -0,0 +1,26 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-18T10:28:08Z + name: azure-instance-stop + version: 0.1.0 + annotations: + categories: Azure + vendor: LitmusChaos +spec: + displayName: Azure Instance Stop + categoryDescription: | + Azure instance stop fault disrupts the state of Azure instance. This fault injects Azure instances stop for a certain chaos duration. + - It helps to check the performance of the application/processes running on the Azure instance when subject to instance stop. + keywords: + - Azure + platforms: + - Azure + minKubeVersion: 1.12.0 + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/azure/azure-instance-stop/engine.yaml b/faults/azure/azure-instance-stop/engine.yaml similarity index 87% rename from charts/azure/azure-instance-stop/engine.yaml rename to faults/azure/azure-instance-stop/engine.yaml index 13d3e49..9370956 100644 --- a/charts/azure/azure-instance-stop/engine.yaml +++ b/faults/azure/azure-instance-stop/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,19 +6,19 @@ metadata: namespace: default spec: engineState: 'active' - chaosServiceAccount: azure-instance-stop-sa + chaosServiceAccount: litmus-admin experiments: - name: azure-instance-stop spec: components: - env: + env: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '30' # set chaos intreval (in sec) as desired - name: CHAOS_INTERVAL - value: '30' + value: '30' # provide the target instance name(s) (comma separated if multiple) - name: AZURE_INSTANCE_NAMES @@ -26,8 +27,7 @@ spec: # provide the resource group of the instance - name: RESOURCE_GROUP value: '' - + # accepts enable/disable, default is disable - name: SCALE_SET value: '' - diff --git a/faults/azure/azure-instance-stop/fault.yaml b/faults/azure/azure-instance-stop/fault.yaml new file mode 100644 index 0000000..86a0b49 --- /dev/null +++ b/faults/azure/azure-instance-stop/fault.yaml @@ -0,0 +1,102 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Stops an Azure instance for a certain chaos duration +kind: ChaosExperiment +metadata: + name: azure-instance-stop + labels: + name: azure-instance-stop + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name azure-instance-stop + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide the target instance name(s) (comma separated if multiple) + - name: AZURE_INSTANCE_NAMES + value: "" + + # provide the resource group of the instance + - name: RESOURCE_GROUP + value: "" + + # accepts enable/disable, default is disable + - name: SCALE_SET + value: "" + + # Provide the path of aks credentials mounted from secret + - name: AZURE_AUTH_LOCATION + value: "/tmp/azure.auth" + + - name: SEQUENCE + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + labels: + name: azure-instance-stop + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/azure/azure.chartserviceversion.yaml b/faults/azure/azure.chartserviceversion.yaml new file mode 100644 index 0000000..6abde3e --- /dev/null +++ b/faults/azure/azure.chartserviceversion.yaml @@ -0,0 +1,36 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: azure + version: 0.1.0 + annotations: + categories: Azure + chartDescription: Injects faults on Azure services + executionPlane: "kubernetes" +spec: + displayName: Azure + categoryDescription: > + Azure chaos contains different chaos experiments for Azure cloud provider to test the app/platform service availability. It uses Azure RunCommand to carry out the fault logic in the instance. It will install all the experiments which can be used to inject chaos into the Azure services like VMs, and so on. + faults: + - name: azure-disk-loss + description: It injects Azure disk loss fault from an Azure VM instance for a certain chaos duration. + displayName: "Azure Disk Loss" + - name: azure-instance-stop + description: It injects the Azure VM instance stop fault for a certain chaos duration. + displayName: "Azure Instance Stop" + keywords: + - Azure + minKubeVersion: 1.12.0 + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Kubernetes Slack + url: https://slack.kubernetes.io/ + - name: Documentation + url: "https://litmuschaos.github.io/litmus/experiments/categories/contents/#azure" + icon: + - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico + mediatype: image/png diff --git a/charts/azure/azure.package.yaml b/faults/azure/azure.package.yaml similarity index 60% rename from charts/azure/azure.package.yaml rename to faults/azure/azure.package.yaml index 904710a..7910f32 100644 --- a/charts/azure/azure.package.yaml +++ b/faults/azure/azure.package.yaml @@ -1,10 +1,9 @@ -packageName: azure -experiments: - - name: azure-instance-stop - CSV: azure-instance-stop.chartserviceversion.yaml - desc: "azure-instance-stop" - +--- +packageName: azure +faults: - name: azure-disk-loss CSV: azure-disk-loss.chartserviceversion.yaml desc: "azure-disk-loss" - + - name: azure-instance-stop + CSV: azure-instance-stop.chartserviceversion.yaml + desc: "azure-instance-stop" \ No newline at end of file diff --git a/charts/azure/icons/azure-disk-loss.png b/faults/azure/icons/azure-disk-loss.png similarity index 100% rename from charts/azure/icons/azure-disk-loss.png rename to faults/azure/icons/azure-disk-loss.png diff --git a/charts/azure/icons/azure-instance-stop.png b/faults/azure/icons/azure-instance-stop.png similarity index 100% rename from charts/azure/icons/azure-instance-stop.png rename to faults/azure/icons/azure-instance-stop.png diff --git a/charts/azure/icons/azure.png b/faults/azure/icons/azure.png similarity index 100% rename from charts/azure/icons/azure.png rename to faults/azure/icons/azure.png diff --git a/charts/gcp/gcp-vm-disk-loss-by-label/engine.yaml b/faults/gcp/gcp-vm-disk-loss-by-label/engine.yaml similarity index 87% rename from charts/gcp/gcp-vm-disk-loss-by-label/engine.yaml rename to faults/gcp/gcp-vm-disk-loss-by-label/engine.yaml index 93854d8..11b9845 100644 --- a/charts/gcp/gcp-vm-disk-loss-by-label/engine.yaml +++ b/faults/gcp/gcp-vm-disk-loss-by-label/engine.yaml @@ -1,10 +1,11 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: gcp-disk-chaos + name: gcp-chaos spec: engineState: 'active' - chaosServiceAccount: gcp-vm-disk-loss-by-label-sa + chaosServiceAccount: litmus-admin experiments: - name: gcp-vm-disk-loss-by-label spec: @@ -17,13 +18,13 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '30' - + # set the GCP project id - name: GCP_PROJECT_ID value: '' # set the zone in which all the disks are created - # all the disks must exist in the same zone + # all the disks must exist in the same zone - name: ZONES value: '' @@ -31,7 +32,7 @@ spec: - name: DISK_VOLUME_LABEL value: '' - # set the percentage value of the disks with the given label + # set the percentage value of the disks with the given label # which should be targeted as part of the chaos injection - name: DISK_AFFECTED_PERC value: '' diff --git a/faults/gcp/gcp-vm-disk-loss-by-label/fault.yaml b/faults/gcp/gcp-vm-disk-loss-by-label/fault.yaml new file mode 100644 index 0000000..59c2220 --- /dev/null +++ b/faults/gcp/gcp-vm-disk-loss-by-label/fault.yaml @@ -0,0 +1,98 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back +kind: ChaosExperiment +metadata: + name: gcp-vm-disk-loss-by-label + labels: + name: gcp-vm-disk-loss-by-label + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name gcp-vm-disk-loss-by-label + command: + - /bin/bash + 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: "30" + + # set the GCP project id + - name: GCP_PROJECT_ID + value: "" + + # set the zone in which all the disks are created + # all the disks must exist in the same zone + - name: ZONES + value: "" + + # set the label of the target disk volumes + - name: DISK_VOLUME_LABEL + value: "" + + # set the percentage value of the disks with the given label + # which should be targeted as part of the chaos injection + - name: DISK_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: SEQUENCE + value: "parallel" + + labels: + name: gcp-vm-disk-loss-by-label + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml b/faults/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml new file mode 100644 index 0000000..f9ef170 --- /dev/null +++ b/faults/gcp/gcp-vm-disk-loss-by-label/gcp-vm-disk-loss-by-label.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: gcp-vm-disk-loss-by-label + version: 0.1.0 + annotations: + categories: GCP + vendor: LitmusChaos + +spec: + displayName: GCP VM Disk Loss By Label + categoryDescription: > + Causes loss of a non-boot storage persistent disk from a GCP VM instance filtered by a label for a specified duration before attaching them back. + keywords: + - GCP + platforms: + - "Minikube" + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/gcp/gcp-vm-disk-loss/engine.yaml b/faults/gcp/gcp-vm-disk-loss/engine.yaml similarity index 87% rename from charts/gcp/gcp-vm-disk-loss/engine.yaml rename to faults/gcp/gcp-vm-disk-loss/engine.yaml index 8b7ca42..4010cb0 100644 --- a/charts/gcp/gcp-vm-disk-loss/engine.yaml +++ b/faults/gcp/gcp-vm-disk-loss/engine.yaml @@ -1,12 +1,13 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: gcp-disk-chaos + name: gcp-chaos namespace: default spec: # It can be active/stop engineState: 'active' - chaosServiceAccount: gcp-vm-disk-loss-sa + chaosServiceAccount: litmus-admin experiments: - name: gcp-vm-disk-loss spec: @@ -24,13 +25,13 @@ spec: - name: GCP_PROJECT_ID value: '' - # set the disk volume name(s) as comma seperated values + # set the disk volume name(s) as comma seperated values # eg. volume1,volume2,... - name: DISK_VOLUME_NAMES value: '' - - # set the disk zone(s) as comma seperated values in the corresponding - # order of DISK_VOLUME_NAME + + # set the disk zone(s) as comma seperated values in the corresponding + # order of DISK_VOLUME_NAME # eg. zone1,zone2,... - name: ZONES value: '' diff --git a/faults/gcp/gcp-vm-disk-loss/fault.yaml b/faults/gcp/gcp-vm-disk-loss/fault.yaml new file mode 100644 index 0000000..53b2d89 --- /dev/null +++ b/faults/gcp/gcp-vm-disk-loss/fault.yaml @@ -0,0 +1,102 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back +kind: ChaosExperiment +metadata: + name: gcp-vm-disk-loss + labels: + name: gcp-vm-disk-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name gcp-vm-disk-loss + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # parallel or serial; determines how chaos is injected + - name: SEQUENCE + value: "parallel" + + # set the GCP project id + - name: GCP_PROJECT_ID + value: "" + + # set the disk volume name(s) as comma seperated values + # eg. volume1,volume2,... + - name: DISK_VOLUME_NAMES + value: "" + + # set the disk zone(s) as comma seperated values in the corresponding + # order of DISK_VOLUME_NAME + # eg. zone1,zone2,... + - name: ZONES + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # parallel or serial; determines how chaos is injected + - name: SEQUENCE + value: "parallel" + + labels: + name: gcp-vm-disk-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml b/faults/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml new file mode 100644 index 0000000..c884909 --- /dev/null +++ b/faults/gcp/gcp-vm-disk-loss/gcp-vm-disk-loss.chartserviceversion.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: gcp-vm-disk-loss + version: 0.1.0 + annotations: + categories: GCP + vendor: LitmusChaos +spec: + displayName: GCP VM Disk Loss + categoryDescription: > + Causes loss of a non-boot storage persistent disk from a GCP VM instance for a specified duration before attaching them back. + keywords: + - GCP + platforms: + - GCP + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/gcp/gcp-vm-instance-stop-by-label/engine.yaml b/faults/gcp/gcp-vm-instance-stop-by-label/engine.yaml similarity index 78% rename from charts/gcp/gcp-vm-instance-stop-by-label/engine.yaml rename to faults/gcp/gcp-vm-instance-stop-by-label/engine.yaml index 1351f93..72b3793 100644 --- a/charts/gcp/gcp-vm-instance-stop-by-label/engine.yaml +++ b/faults/gcp/gcp-vm-instance-stop-by-label/engine.yaml @@ -1,11 +1,12 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: gcp-vm-chaos + name: gcp-chaos spec: # It can be active/stop engineState: 'active' - chaosServiceAccount: gcp-vm-instance-stop-by-label-sa + chaosServiceAccount: litmus-admin # It can be delete/retain experiments: - name: gcp-vm-instance-stop-by-label @@ -19,19 +20,19 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '30' - + - name: SEQUENCE value: 'parallel' - # GCP project ID to which the vm instances belong + # GCP project ID to which the VM instances belong - name: GCP_PROJECT_ID value: '' - # Label of the target vm instance(s) + # Label of the target VM instance(s) - name: INSTANCE_LABEL value: '' - # Zone in which the target vm instance(s) filtered by the label exist + # Zone in which the target VM instance(s) filtered by the label exist # all the instances should lie in a single zone - name: ZONES value: '' @@ -40,7 +41,7 @@ spec: - name: MANAGED_INSTANCE_GROUP value: 'disable' - # set the percentage value of the instances with the given label + # set the percentage value of the instances with the given label # which should be targeted as part of the chaos injection - name: INSTANCE_AFFECTED_PERC - value: '' \ No newline at end of file + value: '' diff --git a/faults/gcp/gcp-vm-instance-stop-by-label/fault.yaml b/faults/gcp/gcp-vm-instance-stop-by-label/fault.yaml new file mode 100644 index 0000000..e8f6f96 --- /dev/null +++ b/faults/gcp/gcp-vm-instance-stop-by-label/fault.yaml @@ -0,0 +1,106 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them +kind: ChaosExperiment +metadata: + name: gcp-vm-instance-stop-by-label + labels: + name: gcp-vm-instance-stop-by-label + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name gcp-vm-instance-stop-by-label + command: + - /bin/bash + 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: "30" + + - name: SEQUENCE + value: "parallel" + + # GCP project ID to which the VM instances belong + - name: GCP_PROJECT_ID + value: "" + + # Label of the target VM instance(s) + - name: INSTANCE_LABEL + value: "" + + # Zone in which the target VM instance(s) filtered by the label exist + # all the instances should lie in a single zone + - name: ZONES + value: "" + + # enable it if the target instance is a part of a managed instance group + - name: MANAGED_INSTANCE_GROUP + value: "disable" + + # set the percentage value of the instances with the given label + # which should be targeted as part of the chaos injection + - name: INSTANCE_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + labels: + name: gcp-vm-instance-stop-by-label + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml b/faults/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml new file mode 100644 index 0000000..be696a1 --- /dev/null +++ b/faults/gcp/gcp-vm-instance-stop-by-label/gcp-vm-instance-stop-by-label.chartserviceversion.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: gcp-vm-instance-stop-by-label + version: 0.1.0 + annotations: + categories: GCP + vendor: LitmusChaos +spec: + displayName: GCP VM Instance Stop By Label + categoryDescription: > + Stops GCP VM instances and GKE nodes filtered by a label for a specified duration and later restarts them. + keywords: + - GCP + platforms: + - "Minikube" + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/gcp/gcp-vm-instance-stop/engine.yaml b/faults/gcp/gcp-vm-instance-stop/engine.yaml similarity index 83% rename from charts/gcp/gcp-vm-instance-stop/engine.yaml rename to faults/gcp/gcp-vm-instance-stop/engine.yaml index a279fa2..6787567 100644 --- a/charts/gcp/gcp-vm-instance-stop/engine.yaml +++ b/faults/gcp/gcp-vm-instance-stop/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -17,18 +18,18 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '30' - - # Instance name of the target vm instance(s) + + # Instance name of the target VM instance(s) # Multiple instance names can be provided as comma separated values ex: instance1,instance2 - name: VM_INSTANCE_NAMES value: '' - - # GCP project ID to which the vm instances belong + + # GCP project ID to which the VM instances belong - name: GCP_PROJECT_ID value: '' - # Instance zone(s) of the target vm instance(s) - # If more than one instance is targetted, provide zone for each in the order of their + # Instance zone(s) of the target VM instance(s) + # If more than one instance is targetted, provide zone for each in the order of their # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 - name: ZONES value: '' diff --git a/faults/gcp/gcp-vm-instance-stop/fault.yaml b/faults/gcp/gcp-vm-instance-stop/fault.yaml new file mode 100644 index 0000000..395cae2 --- /dev/null +++ b/faults/gcp/gcp-vm-instance-stop/fault.yaml @@ -0,0 +1,110 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Stops GCP VM instances and GKE nodes for a specified duration and later restarts them +kind: ChaosExperiment +metadata: + name: gcp-vm-instance-stop + labels: + name: gcp-vm-instance-stop + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["secrets", "configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name gcp-vm-instance-stop + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "30" + + - name: CHAOS_INTERVAL + value: "30" + + # parallel or serial; determines how the VM instances are terminated, all at once or one at a time + - name: SEQUENCE + value: "parallel" + + # period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # enable or disable; shall be set to enable if the target instances are a part of a managed instance group + - name: MANAGED_INSTANCE_GROUP + value: "disable" + + # Instance name of the target VM instance(s) + # Multiple instance names can be provided as comma separated values ex: instance1,instance2 + - name: VM_INSTANCE_NAMES + value: "" + + # GCP project ID to which the VM instances belong + - name: GCP_PROJECT_ID + value: "" + + # Instance zone(s) of the target VM instance(s) + # If more than one instance is targetted, provide zone for each in the order of their + # respective instance name in VM_INSTANCE_NAME as comma separated values ex: zone1,zone2 + - name: ZONES + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # parallel or serial; determines how chaos is injected + - name: SEQUENCE + value: "parallel" + + labels: + name: gcp-vm-instance-stop + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci + secrets: + - name: cloud-secret + mountPath: /tmp/ diff --git a/faults/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml b/faults/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml new file mode 100644 index 0000000..dedbfe4 --- /dev/null +++ b/faults/gcp/gcp-vm-instance-stop/gcp-vm-instance-stop.chartserviceversion.yaml @@ -0,0 +1,26 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: gcp-vm-instance-stop + version: 0.1.0 + annotations: + categories: gcp +spec: + displayName: GCP VM Instance Stop + categoryDescription: > + Stops GCP VM instances and GKE nodes for a specified duration and later restarts them. + keywords: + - GCP + platforms: + - GCP + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/faults/gcp/gcp.chartserviceversion.yaml b/faults/gcp/gcp.chartserviceversion.yaml new file mode 100644 index 0000000..79ed799 --- /dev/null +++ b/faults/gcp/gcp.chartserviceversion.yaml @@ -0,0 +1,42 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: gcp + version: 0.1.0 + annotations: + categories: GCP + chartDescription: Injects faults on GCP services + executionPlane: "kubernetes" +spec: + displayName: GCP + categoryDescription: > + GCP fault disrupts state of GCP resources running part of the GCP services + faults: + - name: gcp-vm-instance-stop + description: It injects gcp-vm-instance-stop fault into GCP VMs. + displayName: "GCP VM Instance Stop" + - name: gcp-vm-instance-stop-by-label + description: It injects gcp-vm-instance-stop-by-label fault into GCP VMs. + displayName: "GCP VM Instance Stop By Label" + - name: gcp-vm-disk-loss-by-label + description: It injects gcp-vm-disk-loss-by-label fault into GCP VMs. + displayName: "GCP VM Disk Loss By Label" + - name: gcp-vm-disk-loss + description: It injects gcp-vm-disk-loss fault into GCP VMs. + displayName: "GCP VM Disk Loss" + keywords: + - GCP + minKubeVersion: 1.12.0 + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Kubernetes Slack + url: https://slack.kubernetes.io/ + - name: Documentation + url: "https://litmuschaos.github.io/litmus/experiments/categories/contents/#gcp" + icon: + - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico + mediatype: image/png diff --git a/charts/gcp/gcp.package.yaml b/faults/gcp/gcp.package.yaml similarity index 97% rename from charts/gcp/gcp.package.yaml rename to faults/gcp/gcp.package.yaml index 28c1b33..abe7781 100644 --- a/charts/gcp/gcp.package.yaml +++ b/faults/gcp/gcp.package.yaml @@ -1,14 +1,15 @@ +--- packageName: gcp -experiments: +faults: - name: gcp-vm-instance-stop CSV: gcp-vm-instance-stop.chartserviceversion.yaml desc: "gcp-vm-instance-stop" - - name: gcp-vm-disk-loss - CSV: gcp-vm-disk-loss.chartserviceversion.yaml - desc: "gcp-vm-disk-loss" - name: gcp-vm-instance-stop-by-label CSV: gcp-vm-instance-stop-by-label.chartserviceversion.yaml desc: "gcp-vm-instance-stop-by-label" - name: gcp-vm-disk-loss-by-label CSV: gcp-vm-disk-loss-by-label.chartserviceversion.yaml desc: "gcp-vm-disk-loss-by-label" + - name: gcp-vm-disk-loss + CSV: gcp-vm-disk-loss.chartserviceversion.yaml + desc: "gcp-vm-disk-loss" diff --git a/charts/gcp/icons/gcp-vm-disk-loss-by-label.png b/faults/gcp/icons/gcp-vm-disk-loss-by-label.png similarity index 100% rename from charts/gcp/icons/gcp-vm-disk-loss-by-label.png rename to faults/gcp/icons/gcp-vm-disk-loss-by-label.png diff --git a/charts/gcp/icons/gcp-vm-disk-loss.png b/faults/gcp/icons/gcp-vm-disk-loss.png similarity index 100% rename from charts/gcp/icons/gcp-vm-disk-loss.png rename to faults/gcp/icons/gcp-vm-disk-loss.png diff --git a/charts/gcp/icons/gcp-vm-instance-stop-by-label.png b/faults/gcp/icons/gcp-vm-instance-stop-by-label.png similarity index 100% rename from charts/gcp/icons/gcp-vm-instance-stop-by-label.png rename to faults/gcp/icons/gcp-vm-instance-stop-by-label.png diff --git a/charts/gcp/icons/gcp-vm-instance-stop.png b/faults/gcp/icons/gcp-vm-instance-stop.png similarity index 100% rename from charts/gcp/icons/gcp-vm-instance-stop.png rename to faults/gcp/icons/gcp-vm-instance-stop.png diff --git a/charts/gcp/icons/gcp.png b/faults/gcp/icons/gcp.png similarity index 100% rename from charts/gcp/icons/gcp.png rename to faults/gcp/icons/gcp.png diff --git a/faults/kubernetes/container-kill/container-kill.chartserviceversion.yaml b/faults/kubernetes/container-kill/container-kill.chartserviceversion.yaml new file mode 100644 index 0000000..26643a3 --- /dev/null +++ b/faults/kubernetes/container-kill/container-kill.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: container-kill + version: 0.1.0 + annotations: + categories: "Kubernetes" + vendor: LitmusChaos +spec: + displayName: Container Kill + categoryDescription: | + Container kill fault disrupts state of kubernetes resources. This fault injects random container delete failures against specified application. + - Executes SIGKILL on containers of random replicas of an application deployment. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/experiments/generic/container-kill/engine.yaml b/faults/kubernetes/container-kill/engine.yaml similarity index 81% rename from experiments/generic/container-kill/engine.yaml rename to faults/kubernetes/container-kill/engine.yaml index 399084c..038051b 100644 --- a/experiments/generic/container-kill/engine.yaml +++ b/faults/kubernetes/container-kill/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: container-kill-sa experiments: - name: container-kill @@ -25,8 +26,7 @@ spec: value: '10' # provide the name of container runtime - # for litmus LIB, it supports docker, containerd, crio - # for pumba LIB, it supports docker only + # it supports docker, containerd, crio - name: CONTAINER_RUNTIME value: 'containerd' @@ -39,4 +39,3 @@ spec: - name: TARGET_CONTAINER value: '' - \ No newline at end of file diff --git a/experiments/generic/pod-dns-error/experiment.yaml b/faults/kubernetes/container-kill/fault.yaml similarity index 57% rename from experiments/generic/pod-dns-error/experiment.yaml rename to faults/kubernetes/container-kill/fault.yaml index fc21808..65333ab 100644 --- a/experiments/generic/pod-dns-error/experiment.yaml +++ b/faults/kubernetes/container-kill/fault.yaml @@ -1,15 +1,15 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: - message: | - Pod DNS Error injects dns failure/error in target pod containers + message: "Kills a container belonging to an application pod \n" kind: ChaosExperiment metadata: - name: pod-dns-error + name: container-kill labels: - name: pod-dns-error + name: container-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -17,99 +17,116 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always args: - -c - - ./experiments -name pod-dns-error + - ./experiments -name container-kill command: - /bin/bash env: - name: TARGET_CONTAINER value: "" - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds - - # Time period to wait before and after injection of chaos in sec + # Period to wait before and after injection of chaos in sec - name: RAMP_TIME value: "" - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: "" - - name: TARGET_PODS value: "" - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' + # provide the chaos interval + - name: CHAOS_INTERVAL + value: "10" + + - name: SIGNAL + value: "SIGKILL" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: "/run/containerd/containerd.sock" + + # provide the name of container runtime + # it supports docker, containerd, crio + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the total chaos duration + - name: TOTAL_CHAOS_DURATION + value: "20" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE value: "parallel" - # list of the target hostnames or kewywords eg. '["litmuschaos","chaosnative.io"]' . If empty all hostnames are targets - - name: TARGET_HOSTNAMES - value: "" - - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring - - name: MATCH_SCHEME - value: "exact" - labels: - experiment: pod-dns-error + name: container-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/charts/generic/disk-fill/disk-fill.chartserviceversion.yaml b/faults/kubernetes/disk-fill/disk-fill.chartserviceversion.yaml similarity index 50% rename from charts/generic/disk-fill/disk-fill.chartserviceversion.yaml rename to faults/kubernetes/disk-fill/disk-fill.chartserviceversion.yaml index e5b202c..4df0db5 100644 --- a/charts/generic/disk-fill/disk-fill.chartserviceversion.yaml +++ b/faults/kubernetes/disk-fill/disk-fill.chartserviceversion.yaml @@ -1,48 +1,37 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2019-11-11T10:28:08Z name: disk-fill - version: 0.0.12 + version: 0.1.0 annotations: categories: Kubernetes - vendor: CNCF + vendor: LitmusChaos support: https://slack.kubernetes.io/ spec: - displayName: disk-fill + displayName: Disk Fill categoryDescription: | - Disk fill contains chaos to disrupt state of kubernetes resources. + Disk fill fault disrupts state of kubernetes resources. - Causes (forced/graceful) Disk Stress by filling up the Ephemeral Storage of the Pod using one of it containers. - Causes Pod to get Evicted if the Pod exceeds it Ephemeral Storage Limit. - Tests the Ephemeral Storage Limits, to ensure those parameters are sufficient. keywords: - Kubernetes - - K8S - - Pod - - Disk platforms: - GKE - EKS - AKS - maturity: alpha + experiments: + - sock-shop + - sock-shop-promProbe chaosType: infra - maintainers: - - name: ksatchit - email: karthik.s@mayadata.io minKubeVersion: 1.12.0 - provider: - name: Mayadata labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/generic/disk-fill - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/pods/disk-fill/ - - name: Video - url: https://www.youtube.com/watch?v=pbok737rUPQ + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/generic/disk-fill/experiment.yaml diff --git a/experiments/generic/disk-fill/engine.yaml b/faults/kubernetes/disk-fill/engine.yaml similarity index 63% rename from experiments/generic/disk-fill/engine.yaml rename to faults/kubernetes/disk-fill/engine.yaml index 5245c86..d4ad97d 100644 --- a/experiments/generic/disk-fill/engine.yaml +++ b/faults/kubernetes/disk-fill/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -9,9 +10,9 @@ spec: #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: disk-fill-sa experiments: - name: disk-fill @@ -28,10 +29,8 @@ spec: - name: PODS_AFFECTED_PERC value: '' - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' + # Provide the container runtime path + # Default set to docker container path + - name: CONTAINER_PATH + value: '/var/lib/docker/containers' - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' diff --git a/faults/kubernetes/disk-fill/fault.yaml b/faults/kubernetes/disk-fill/fault.yaml new file mode 100644 index 0000000..638e480 --- /dev/null +++ b/faults/kubernetes/disk-fill/fault.yaml @@ -0,0 +1,132 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Fillup Ephemeral Storage of a Resource +kind: ChaosExperiment +metadata: + name: disk-fill + labels: + name: disk-fill + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name disk-fill + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + - name: FILL_PERCENTAGE + value: "80" + + - name: TOTAL_CHAOS_DURATION + value: "60" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide the data block size + # supported unit is KB + - name: DATA_BLOCK_SIZE + value: "256" + + - name: TARGET_PODS + value: "" + + - name: EPHEMERAL_STORAGE_MEBIBYTES + value: "" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # Provide the container runtime path + # Default set to docker container path + - name: CONTAINER_PATH + value: "/var/lib/docker/containers" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: disk-fill + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/host-path-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/docker-service-kill/docker-service-kill.chartserviceversion.yaml b/faults/kubernetes/docker-service-kill/docker-service-kill.chartserviceversion.yaml new file mode 100644 index 0000000..1c58745 --- /dev/null +++ b/faults/kubernetes/docker-service-kill/docker-service-kill.chartserviceversion.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: docker-service-kill + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Docker Service Kill + categoryDescription: | + docker-service-kill fault kills the Docker service gracefully for a certain chaos duration. + - Causes replicas to be evicted or become unreachable on account of nodes turning unschedulable (Not Ready) due to Docker service kill. + - The application node should be healthy once the chaos is stopped and the services are re-accessable. + keywords: + - Kubernetes + platforms: + - GKE + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/docker-service-kill/engine.yaml b/faults/kubernetes/docker-service-kill/engine.yaml similarity index 82% rename from charts/generic/docker-service-kill/engine.yaml rename to faults/kubernetes/docker-service-kill/engine.yaml index cfc1d1a..a13662a 100644 --- a/charts/generic/docker-service-kill/engine.yaml +++ b/faults/kubernetes/docker-service-kill/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -12,12 +13,15 @@ spec: - name: docker-service-kill spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '90' # in seconds - + - name: TARGET_NODE - value: '' \ No newline at end of file + value: '' + + - name: NODE_LABEL + value: "" diff --git a/charts/generic/docker-service-kill/experiment.yaml b/faults/kubernetes/docker-service-kill/fault.yaml similarity index 53% rename from charts/generic/docker-service-kill/experiment.yaml rename to faults/kubernetes/docker-service-kill/fault.yaml index 1d8d0ef..601a96c 100644 --- a/charts/generic/docker-service-kill/experiment.yaml +++ b/faults/kubernetes/docker-service-kill/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Kills the docker service on the application node to check the resiliency. + Kills the Docker service on the application node to check the resiliency. kind: ChaosExperiment metadata: name: docker-service-kill @@ -9,7 +10,7 @@ metadata: name: docker-service-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -17,66 +18,76 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list"] + verbs: ["get", "list"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name docker-service-kill + - -c + - ./experiments -name docker-service-kill command: - - /bin/bash + - /bin/bash env: - - - name: TOTAL_CHAOS_DURATION - value: '90' # in seconds + - name: TOTAL_CHAOS_DURATION + value: "90" # in seconds - # Period to wait before injection of chaos in sec - - name: RAMP_TIME - value: '' + # Period to wait before injection of chaos in sec + - name: RAMP_TIME + value: "" - - name: NODE_LABEL - value: '' + - name: NODE_LABEL + value: "" - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' + # provide lib image + - name: LIB_IMAGE + value: "ubuntu:16.04" + + # provide the target node name + - name: TARGET_NODE + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" labels: name: docker-service-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest - + app.kubernetes.io/version: ci diff --git a/charts/generic/icons/container-kill.png b/faults/kubernetes/icons/container-kill.png similarity index 100% rename from charts/generic/icons/container-kill.png rename to faults/kubernetes/icons/container-kill.png diff --git a/charts/generic/icons/disk-fill.png b/faults/kubernetes/icons/disk-fill.png similarity index 100% rename from charts/generic/icons/disk-fill.png rename to faults/kubernetes/icons/disk-fill.png diff --git a/charts/generic/icons/docker-service-kill.png b/faults/kubernetes/icons/docker-service-kill.png similarity index 100% rename from charts/generic/icons/docker-service-kill.png rename to faults/kubernetes/icons/docker-service-kill.png diff --git a/charts/generic/icons/kubelet-service-kill.png b/faults/kubernetes/icons/kubelet-service-kill.png similarity index 100% rename from charts/generic/icons/kubelet-service-kill.png rename to faults/kubernetes/icons/kubelet-service-kill.png diff --git a/charts/generic/icons/generic.png b/faults/kubernetes/icons/kubernetes.png similarity index 100% rename from charts/generic/icons/generic.png rename to faults/kubernetes/icons/kubernetes.png diff --git a/charts/generic/icons/node-cpu-hog.png b/faults/kubernetes/icons/node-cpu-hog.png similarity index 100% rename from charts/generic/icons/node-cpu-hog.png rename to faults/kubernetes/icons/node-cpu-hog.png diff --git a/charts/generic/icons/node-drain.png b/faults/kubernetes/icons/node-drain.png similarity index 100% rename from charts/generic/icons/node-drain.png rename to faults/kubernetes/icons/node-drain.png diff --git a/charts/generic/icons/node-io-stress.png b/faults/kubernetes/icons/node-io-stress.png similarity index 100% rename from charts/generic/icons/node-io-stress.png rename to faults/kubernetes/icons/node-io-stress.png diff --git a/charts/generic/icons/node-memory-hog.png b/faults/kubernetes/icons/node-memory-hog.png similarity index 100% rename from charts/generic/icons/node-memory-hog.png rename to faults/kubernetes/icons/node-memory-hog.png diff --git a/charts/generic/icons/node-restart.png b/faults/kubernetes/icons/node-poweroff.png similarity index 100% rename from charts/generic/icons/node-restart.png rename to faults/kubernetes/icons/node-poweroff.png diff --git a/experiments/generic/icons/node-restart.png b/faults/kubernetes/icons/node-restart.png similarity index 100% rename from experiments/generic/icons/node-restart.png rename to faults/kubernetes/icons/node-restart.png diff --git a/charts/generic/icons/node-taint.png b/faults/kubernetes/icons/node-taint.png similarity index 100% rename from charts/generic/icons/node-taint.png rename to faults/kubernetes/icons/node-taint.png diff --git a/charts/generic/icons/pod-autoscaler.png b/faults/kubernetes/icons/pod-autoscaler.png similarity index 100% rename from charts/generic/icons/pod-autoscaler.png rename to faults/kubernetes/icons/pod-autoscaler.png diff --git a/charts/generic/icons/pod-cpu-hog-exec.png b/faults/kubernetes/icons/pod-cpu-hog-exec.png similarity index 100% rename from charts/generic/icons/pod-cpu-hog-exec.png rename to faults/kubernetes/icons/pod-cpu-hog-exec.png diff --git a/charts/generic/icons/pod-cpu-hog.png b/faults/kubernetes/icons/pod-cpu-hog.png similarity index 100% rename from charts/generic/icons/pod-cpu-hog.png rename to faults/kubernetes/icons/pod-cpu-hog.png diff --git a/charts/generic/icons/pod-delete.png b/faults/kubernetes/icons/pod-delete.png similarity index 100% rename from charts/generic/icons/pod-delete.png rename to faults/kubernetes/icons/pod-delete.png diff --git a/charts/generic/icons/pod-dns-error.png b/faults/kubernetes/icons/pod-dns-error.png similarity index 100% rename from charts/generic/icons/pod-dns-error.png rename to faults/kubernetes/icons/pod-dns-error.png diff --git a/charts/generic/icons/pod-dns-spoof.png b/faults/kubernetes/icons/pod-dns-spoof.png similarity index 100% rename from charts/generic/icons/pod-dns-spoof.png rename to faults/kubernetes/icons/pod-dns-spoof.png diff --git a/charts/generic/icons/pod-http-latency.png b/faults/kubernetes/icons/pod-http-latency.png similarity index 100% rename from charts/generic/icons/pod-http-latency.png rename to faults/kubernetes/icons/pod-http-latency.png diff --git a/charts/generic/icons/pod-http-modify-body.png b/faults/kubernetes/icons/pod-http-modify-body.png similarity index 100% rename from charts/generic/icons/pod-http-modify-body.png rename to faults/kubernetes/icons/pod-http-modify-body.png diff --git a/charts/generic/icons/pod-http-modify-header.png b/faults/kubernetes/icons/pod-http-modify-header.png similarity index 100% rename from charts/generic/icons/pod-http-modify-header.png rename to faults/kubernetes/icons/pod-http-modify-header.png diff --git a/charts/generic/icons/pod-http-reset-peer.png b/faults/kubernetes/icons/pod-http-reset-peer.png similarity index 100% rename from charts/generic/icons/pod-http-reset-peer.png rename to faults/kubernetes/icons/pod-http-reset-peer.png diff --git a/charts/generic/icons/pod-http-status-code.png b/faults/kubernetes/icons/pod-http-status-code.png similarity index 100% rename from charts/generic/icons/pod-http-status-code.png rename to faults/kubernetes/icons/pod-http-status-code.png diff --git a/charts/generic/icons/pod-io-stress.png b/faults/kubernetes/icons/pod-io-stress.png similarity index 100% rename from charts/generic/icons/pod-io-stress.png rename to faults/kubernetes/icons/pod-io-stress.png diff --git a/charts/generic/icons/pod-memory-hog-exec.png b/faults/kubernetes/icons/pod-memory-hog-exec.png similarity index 100% rename from charts/generic/icons/pod-memory-hog-exec.png rename to faults/kubernetes/icons/pod-memory-hog-exec.png diff --git a/charts/generic/icons/pod-memory-hog.png b/faults/kubernetes/icons/pod-memory-hog.png similarity index 100% rename from charts/generic/icons/pod-memory-hog.png rename to faults/kubernetes/icons/pod-memory-hog.png diff --git a/charts/generic/icons/pod-network-corruption.png b/faults/kubernetes/icons/pod-network-corruption.png similarity index 100% rename from charts/generic/icons/pod-network-corruption.png rename to faults/kubernetes/icons/pod-network-corruption.png diff --git a/charts/generic/icons/pod-network-duplication.png b/faults/kubernetes/icons/pod-network-duplication.png similarity index 100% rename from charts/generic/icons/pod-network-duplication.png rename to faults/kubernetes/icons/pod-network-duplication.png diff --git a/charts/generic/icons/pod-network-latency.png b/faults/kubernetes/icons/pod-network-latency.png similarity index 100% rename from charts/generic/icons/pod-network-latency.png rename to faults/kubernetes/icons/pod-network-latency.png diff --git a/charts/generic/icons/pod-network-loss.png b/faults/kubernetes/icons/pod-network-loss.png similarity index 100% rename from charts/generic/icons/pod-network-loss.png rename to faults/kubernetes/icons/pod-network-loss.png diff --git a/charts/generic/icons/pod-network-partition.png b/faults/kubernetes/icons/pod-network-partition.png similarity index 100% rename from charts/generic/icons/pod-network-partition.png rename to faults/kubernetes/icons/pod-network-partition.png diff --git a/charts/generic/kubelet-service-kill/engine.yaml b/faults/kubernetes/kubelet-service-kill/engine.yaml similarity index 79% rename from charts/generic/kubelet-service-kill/engine.yaml rename to faults/kubernetes/kubelet-service-kill/engine.yaml index 5ebc548..c20042f 100644 --- a/charts/generic/kubelet-service-kill/engine.yaml +++ b/faults/kubernetes/kubelet-service-kill/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,20 +7,20 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: kubelet-service-kill-sa experiments: - name: kubelet-service-kill spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels - # kubernetes.io/hostname: 'node02' + # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - + # provide the target node name - name: TARGET_NODE value: '' diff --git a/experiments/generic/kubelet-service-kill/experiment.yaml b/faults/kubernetes/kubelet-service-kill/fault.yaml similarity index 53% rename from experiments/generic/kubelet-service-kill/experiment.yaml rename to faults/kubernetes/kubelet-service-kill/fault.yaml index 5f86d74..2f9c56e 100644 --- a/experiments/generic/kubelet-service-kill/experiment.yaml +++ b/faults/kubernetes/kubelet-service-kill/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Kills the kubelet service on the application node to check the resiliency. + Kills the Kubelet service on the application node to check the resiliency. kind: ChaosExperiment metadata: name: kubelet-service-kill @@ -9,7 +10,7 @@ metadata: name: kubelet-service-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -17,68 +18,76 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list"] + verbs: ["get", "list"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name kubelet-service-kill + - -c + - ./experiments -name kubelet-service-kill command: - - /bin/bash + - /bin/bash env: - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" - - name: LIB - value: 'litmus' + - name: NODE_LABEL + value: "" - - name: NODE_LABEL - value: '' + # provide lib image + - name: LIB_IMAGE + value: "ubuntu:16.04" - # provide lib image - - name: LIB_IMAGE - value: 'ubuntu:16.04' - - # provide the target node name - - name: TARGET_NODE - value: '' + # provide the target node name + - name: TARGET_NODE + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" labels: name: kubelet-service-kill app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job app.kubernetes.io/service-kill: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml b/faults/kubernetes/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml new file mode 100644 index 0000000..991864a --- /dev/null +++ b/faults/kubernetes/kubelet-service-kill/kubelet-service-kill.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: kubelet-service-kill + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Kubelet Service Kill + categoryDescription: | + kubelet-service-kill fault kills the Kubelet service gracefully for a certain chaos duration. + - Replicas may be evicted or become unreachable on account on nodes turning unschedulable (Not Ready) due to Kubelet service kill. + - The application node should be healthy once chaos is stopped and the services are reaccessable. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/faults/kubernetes/kubernetes.chartserviceversion.yaml b/faults/kubernetes/kubernetes.chartserviceversion.yaml new file mode 100644 index 0000000..32e4030 --- /dev/null +++ b/faults/kubernetes/kubernetes.chartserviceversion.yaml @@ -0,0 +1,120 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: kubernetes + version: 0.1.0 + annotations: + categories: Kubernetes + chartDescription: Injects kubernetes chaos experiment + executionPlane: "kubernetes" +spec: + displayName: Kubernetes + categoryDescription: > + Kubernetes is an open-source system for automating deployment, scaling, and management of containerized applications. It groups containers that make up an application into logical units for easier management and discovery. It will install all the experiments which can be used to inject chaos into containerized applications. + faults: + - name: pod-delete + description: It injects pod-delete chaos in a Kubernetes pod. + displayName: "Pod Delete" + - name: container-kill + description: It injects container-kill chaos in a Kubernetes pod . + displayName: "Container Kill" + - name: pod-cpu-hog + description: It injects cpu-hog chaos in a Kubernetes pod. + displayName: "Pod CPU Hog" + - name: pod-network-loss + description: It injects network-loss chaos in a Kubernetes pod. + displayName: "Pod Network Loss" + - name: pod-network-latency + description: It injects network-latency chaos in a Kubernetes pod. + displayName: "Pod Network Latency" + - name: pod-network-corruption + description: It injects network-corruption chaos in a Kubernetes pod. + displayName: "Pod Network Corruption" + - name: node-drain + description: It injects node-drain chaos in a Kubernetes node. + displayName: "Node Drain" + - name: node-cpu-hog + description: It injects node-cpu-hog chaos in a Kubernetes node. + displayName: "Node CPU Hog" + - name: node-restart + description: It injects node-restart chaos in a Kubernetes node. + displayName: "Node Restart" + - name: disk-fill + description: It injects disk-fill chaos in a Kubernetes node. + displayName: "Disk Fill" + - name: node-memory-hog + description: It injects node-memory-hog chaos in a Kubernetes node. + displayName: "Node Memory Hog" + - name: node-poweroff + description: Node poweroff contains chaos experiment to poweroff a node via SSH. + displayName: "Node Poweroff" + - name: pod-memory-hog + description: It injects pod-memory-hog chaos in a Kubernetes pod. + displayName: "Pod Memory Hog" + - name: kubelet-service-kill + description: It injects kubelet-service-kill chaos in a Kubernetes node. + displayName: "Kubelet Service Kill" + - name: pod-network-duplication + description: It injects pod-network-duplication chaos in a Kubernetes pod. + displayName: "Pod Network Duplication" + - name: node-taint + description: It injects node-taint chaos in a Kubernetes node. + displayName: "Node Taint" + - name: docker-service-kill + description: It injects docker-service-kill chaos in a Kubernetes pod. + displayName: "Docker Service Kill" + - name: pod-autoscaler + description: It injects pod-autoscaler chaos in a Kubernetes pod. + displayName: "Pod Autoscaler" + - name: node-io-stress + description: It injects node-io-stress chaos in a Kubernetes node. + displayName: "Node IO Stress" + - name: pod-io-stress + description: It injects pod-io-stress chaos in a Kubernetes pod. + displayName: "Pod IO Stress" + - name: pod-dns-error + description: It injects pod-dns-error chaos in a Kubernetes pod. + displayName: "Pod DNS Error" + - name: pod-dns-spoof + description: It injects pod-dns-spoof chaos in a Kubernetes pod. + displayName: "Pod DNS Spoof" + - name: pod-cpu-hog-exec + description: It injects pod-cpu-hog-exec chaos in a Kubernetes pod. + displayName: "Pod CPU Hog Exec" + - name: pod-memory-hog-exec + description: It injects pod-memory-hog-exec chaos in a Kubernetes pod. + displayName: "Pod Memory Hog Exec" + - name: pod-network-partition + description: It injects pod-network-partition chaos in a Kubernetes pod. + displayName: "Pod Network Partition" + - name: pod-http-latency + description: It injects pod-http-latency chaos in a Kubernetes pod. + displayName: "Pod HTTP Latency" + - name: pod-http-status-code + description: It injects pod-http-status-code chaos in a Kubernetes pod. + displayName: "Pod HTTP Status Code" + - name: pod-http-modify-header + description: It injects pod-http-modify-header chaos in a Kubernetes pod. + displayName: "Pod HTTP Modify Header" + - name: pod-http-modify-body + description: It injects pod-http-modify-body chaos in a Kubernetes pod. + displayName: "Pod HTTP Modify Body" + - name: pod-http-reset-peer + description: It injects pod-http-reset-peer chaos in a Kubernetes pod. + displayName: "Pod HTTP Reset Peer" + keywords: + - Kubernetes + minKubeVersion: 1.12.0 + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Kubernetes Slack + url: https://slack.kubernetes.io/ + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents/#kubernetes + icon: + - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico + mediatype: image/png diff --git a/experiments/generic/generic.package.yaml b/faults/kubernetes/kubernetes.package.yaml similarity index 88% rename from experiments/generic/generic.package.yaml rename to faults/kubernetes/kubernetes.package.yaml index e816034..3db6bac 100644 --- a/experiments/generic/generic.package.yaml +++ b/faults/kubernetes/kubernetes.package.yaml @@ -1,5 +1,6 @@ -packageName: generic -experiments: +--- +packageName: kubernetes +faults: - name: pod-delete CSV: pod-delete.chartserviceversion.yaml desc: "pod-delete" @@ -8,7 +9,7 @@ experiments: desc: "container-kill" - name: pod-network-loss CSV: pod-network-loss.chartserviceversion.yaml - desc: "Pod-network-loss" + desc: "pod-network-loss" - name: pod-network-latency CSV: pod-network-latency.chartserviceversion.yaml desc: "pod-network-latency" @@ -30,6 +31,12 @@ experiments: - name: node-memory-hog CSV: node-memory-hog.chartserviceversion.yaml desc: "node-memory-hog" + - name: node-poweroff + CSV: node-poweroff.chartserviceversion.yaml + desc: "node-poweroff" + - name: node-restart + CSV: node-restart.chartserviceversion.yaml + desc: "node-restart" - name: pod-memory-hog CSV: pod-memory-hog.chartserviceversion.yaml desc: "pod-memory-hog" @@ -54,9 +61,6 @@ experiments: - name: pod-io-stress CSV: pod-io-stress.chartserviceversion.yaml desc: "pod-io-stress" - - name: node-restart - CSV: node-restart.chartserviceversion.yaml - desc: "node-restart" - name: pod-dns-error CSV: pod-dns-error.chartserviceversion.yaml desc: "pod-dns-error" @@ -75,15 +79,21 @@ experiments: - name: pod-http-latency CSV: pod-http-latency.chartserviceversion.yaml desc: "pod-http-latency" + - name: pod-http-status-code + CSV: pod-http-status-code.chartserviceversion.yaml + desc: "pod-http-status-code" + - name: pod-http-modify-header + CSV: pod-http-modify-header.chartserviceversion.yaml + desc: "pod-http-modify-header" - name: pod-http-modify-body CSV: pod-http-modify-body.chartserviceversion.yaml desc: "pod-http-modify-body" - name: pod-http-reset-peer CSV: pod-http-reset-peer.chartserviceversion.yaml desc: "pod-http-reset-peer" - - name: pod-http-modify-header - CSV: pod-http-modify-header.chartserviceversion.yaml - desc: "pod-http-modify-header" - - name: pod-http-status-code - CSV: pod-http-status-code.chartserviceversion.yaml - desc: "pod-http-status-code" + - name: node-network-latency + CSV: node-network-latency.chartserviceversion.yaml + desc: "node-network-latency" + - name: node-network-loss + CSV: node-network-loss.chartserviceversion.yaml + desc: "node-network-loss" diff --git a/charts/generic/node-cpu-hog/engine.yaml b/faults/kubernetes/node-cpu-hog/engine.yaml similarity index 90% rename from charts/generic/node-cpu-hog/engine.yaml rename to faults/kubernetes/node-cpu-hog/engine.yaml index 85f754f..abbf6af 100644 --- a/charts/generic/node-cpu-hog/engine.yaml +++ b/faults/kubernetes/node-cpu-hog/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,7 +7,7 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-cpu-hog-sa experiments: @@ -17,17 +18,17 @@ spec: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '60' - + ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING - ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY + ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY - name: NODE_CPU_CORE value: '1' - ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. + ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING - name: CPU_LOAD value: '0' - + ## percentage of total nodes to target - name: NODES_AFFECTED_PERC value: '' diff --git a/faults/kubernetes/node-cpu-hog/fault.yaml b/faults/kubernetes/node-cpu-hog/fault.yaml new file mode 100644 index 0000000..15d3c3d --- /dev/null +++ b/faults/kubernetes/node-cpu-hog/fault.yaml @@ -0,0 +1,111 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Give a CPU spike on a node belonging to a deployment +kind: ChaosExperiment +metadata: + name: node-cpu-hog + labels: + name: node-cpu-hog + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name node-cpu-hog + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "60" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + ## ENTER THE NUMBER OF CORES OF CPU FOR CPU HOGGING + ## OPTIONAL VALUE IN CASE OF EMPTY VALUE IT WILL TAKE NODE CPU CAPACITY + - name: NODE_CPU_CORE + value: "" + + ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. + ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING + - name: CPU_LOAD + value: "100" + + # ENTER THE COMMA SEPARATED TARGET NODES NAME + - name: TARGET_NODES + value: "" + + - name: NODE_LABEL + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + ## percentage of total nodes to target + - name: NODES_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + ## it defines the sequence of chaos execution for multiple target nodes + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: node-cpu-hog + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml b/faults/kubernetes/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml new file mode 100644 index 0000000..ddc962c --- /dev/null +++ b/faults/kubernetes/node-cpu-hog/node-cpu-hog.chartserviceversion.yaml @@ -0,0 +1,37 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-cpu-hog + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node CPU Hog + categoryDescription: | + Node CPU hog fault disrupts the state of Kubernetes resources. This fault injects a CPU spike on a node where the application pod is scheduled. + - CPU hog on a particular node where the application deployment is available. + - After test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + experiments: + - node-cpu-hog + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/experiments/generic/node-drain/engine.yaml b/faults/kubernetes/node-drain/engine.yaml similarity index 76% rename from experiments/generic/node-drain/engine.yaml rename to faults/kubernetes/node-drain/engine.yaml index 65a4216..6c5be2a 100644 --- a/experiments/generic/node-drain/engine.yaml +++ b/faults/kubernetes/node-drain/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,21 +7,20 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-drain-sa experiments: - name: node-drain spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels - # kubernetes.io/hostname: 'node02' + # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '60' - + # enter the target node name - name: TARGET_NODE value: '' - \ No newline at end of file diff --git a/experiments/generic/node-drain/experiment.yaml b/faults/kubernetes/node-drain/fault.yaml similarity index 56% rename from experiments/generic/node-drain/experiment.yaml rename to faults/kubernetes/node-drain/fault.yaml index 8834d1d..e0de21d 100644 --- a/experiments/generic/node-drain/experiment.yaml +++ b/faults/kubernetes/node-drain/fault.yaml @@ -10,7 +10,7 @@ metadata: name: node-drain app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -18,68 +18,74 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] + resources: ["pods/exec", "pods/eviction"] + verbs: ["get", "list", "create"] # ignore daemonsets while draining the node - apiGroups: ["apps"] resources: ["daemonsets"] - verbs: ["list","get","delete"] + verbs: ["list", "get", "delete"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list","patch"] + verbs: ["get", "list", "patch"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name node-drain + - -c + - ./experiments -name node-drain command: - - /bin/bash + - /bin/bash env: - - - name: TARGET_NODE - value: '' + - name: TARGET_NODE + value: "" - - name: NODE_LABEL - value: '' + - name: NODE_LABEL + value: "" - - name: TOTAL_CHAOS_DURATION - value: '60' + - 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: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" - # 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 + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/node-drain/node-drain.chartserviceversion.yaml b/faults/kubernetes/node-drain/node-drain.chartserviceversion.yaml new file mode 100644 index 0000000..4b6568d --- /dev/null +++ b/faults/kubernetes/node-drain/node-drain.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-drain + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node Drain + categoryDescription: > + Drain the node where application pod is scheduled. + keywords: + - Kubernetes + platforms: + - GKE + - AWS(KOPS) + - Packet(Kubeadm) + - Konvoy + - EKS + - AKS + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: "" + mediatype: "" diff --git a/charts/generic/node-io-stress/engine.yaml b/faults/kubernetes/node-io-stress/engine.yaml similarity index 89% rename from charts/generic/node-io-stress/engine.yaml rename to faults/kubernetes/node-io-stress/engine.yaml index 938949f..138be73 100644 --- a/charts/generic/node-io-stress/engine.yaml +++ b/faults/kubernetes/node-io-stress/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,7 +7,7 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-io-stress-sa experiments: @@ -28,8 +29,8 @@ spec: ## Total number of workers default value is 4 - name: NUMBER_OF_WORKERS - value: '4' - + value: '4' + ## percentage of total nodes to target - name: NODES_AFFECTED_PERC value: '' diff --git a/faults/kubernetes/node-io-stress/fault.yaml b/faults/kubernetes/node-io-stress/fault.yaml new file mode 100644 index 0000000..1adba99 --- /dev/null +++ b/faults/kubernetes/node-io-stress/fault.yaml @@ -0,0 +1,123 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Give IO disk stress on a node belonging to a deployment +kind: ChaosExperiment +metadata: + name: node-io-stress + labels: + name: node-io-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name node-io-stress + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "120" + + ## specify the size as percentage of free space on the file system + ## default value 90 (in percentage) + - name: FILESYSTEM_UTILIZATION_PERCENTAGE + value: "10" + + ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space + ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty + - name: FILESYSTEM_UTILIZATION_BYTES + value: "" + + ## Number of core of CPU + - name: CPU + value: "1" + + ## Total number of workers default value is 4 + - name: NUMBER_OF_WORKERS + value: "4" + + ## Total number of VM workers + - name: VM_WORKERS + value: "1" + + ## enter the comma separated target nodes name + - name: TARGET_NODES + value: "" + + - name: NODE_LABEL + value: "" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + ## percentage of total nodes to target + - name: NODES_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + ## it defines the sequence of chaos execution for multiple target nodes + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: node-io-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/node-io-stress/node-io-stress.chartserviceversion.yaml b/faults/kubernetes/node-io-stress/node-io-stress.chartserviceversion.yaml new file mode 100644 index 0000000..ccd0a44 --- /dev/null +++ b/faults/kubernetes/node-io-stress/node-io-stress.chartserviceversion.yaml @@ -0,0 +1,32 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-io-stress + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node IO Stress + categoryDescription: | + This fault causes disk stress on the Kubernetes node. This fault aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes.. + - Disk stress on a particular node filesystem where the application deployment is available. + - The amount of disk stress can be either specifed as the size in percentage of the total free space on the file system or simply in Gigabytes(GB) + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: "" + mediatype: "" diff --git a/charts/generic/node-memory-hog/engine.yaml b/faults/kubernetes/node-memory-hog/engine.yaml similarity index 93% rename from charts/generic/node-memory-hog/engine.yaml rename to faults/kubernetes/node-memory-hog/engine.yaml index 8e6b01c..48d7964 100644 --- a/charts/generic/node-memory-hog/engine.yaml +++ b/faults/kubernetes/node-memory-hog/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,7 +7,7 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-memory-hog-sa experiments: @@ -25,12 +26,12 @@ spec: # provide the comma separated target node names - name: TARGET_NODES value: '' - + ## Specify the size as percent of total node capacity Ex: '30' ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty - name: MEMORY_CONSUMPTION_PERCENTAGE value: '0' - + ## Specify the amount of memory to be consumed in mebibytes ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty - name: MEMORY_CONSUMPTION_MEBIBYTES diff --git a/faults/kubernetes/node-memory-hog/fault.yaml b/faults/kubernetes/node-memory-hog/fault.yaml new file mode 100644 index 0000000..ed06bcd --- /dev/null +++ b/faults/kubernetes/node-memory-hog/fault.yaml @@ -0,0 +1,114 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Give a memory hog on a node belonging to a deployment +kind: ChaosExperiment +metadata: + name: node-memory-hog + labels: + name: node-memory-hog + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Cluster + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + # for experiment to perform node status checks + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name node-memory-hog + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "120" + + ## Specify the size as percent of total node capacity Ex: '30' + ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_MEBIBYTES empty + - name: MEMORY_CONSUMPTION_PERCENTAGE + value: "" + + ## Specify the amount of memory to be consumed in mebibytes + ## NOTE: for selecting this option keep MEMORY_CONSUMPTION_PERCENTAGE empty + - name: MEMORY_CONSUMPTION_MEBIBYTES + value: "" + + - name: NUMBER_OF_WORKERS + value: "1" + + # ENTER THE COMMA SEPARATED TARGET NODES NAME + - name: TARGET_NODES + value: "" + + - name: NODE_LABEL + value: "" + + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + ## percentage of total nodes to target + - name: NODES_AFFECTED_PERC + value: "" + + ## it defines the sequence of chaos execution for multiple target nodes + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: node-memory-hog + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/node-memory-hog/node-memory-hog.chartserviceversion.yaml b/faults/kubernetes/node-memory-hog/node-memory-hog.chartserviceversion.yaml new file mode 100644 index 0000000..172987f --- /dev/null +++ b/faults/kubernetes/node-memory-hog/node-memory-hog.chartserviceversion.yaml @@ -0,0 +1,37 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-memory-hog + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node Memory Hog + categoryDescription: | + Kubernetes Node memory hog fault disrupts the state of Kubernetes resources. This fault injects a memory spike on a node where the application pod is scheduled. + - Memory hog on a particular node where the application deployment is available. + - After the test, the recovery should be manual for the application pod and node in case they are not in an appropriate state. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + experiments: + - node-memory-hog + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: "" + mediatype: "" diff --git a/experiments/generic/node-poweroff/engine.yaml b/faults/kubernetes/node-poweroff/engine.yaml similarity index 85% rename from experiments/generic/node-poweroff/engine.yaml rename to faults/kubernetes/node-poweroff/engine.yaml index 68ac3a7..8374ba7 100644 --- a/experiments/generic/node-poweroff/engine.yaml +++ b/faults/kubernetes/node-poweroff/engine.yaml @@ -6,16 +6,16 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-poweroff-sa experiments: - name: node-poweroff spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels - # kubernetes.io/hostname: 'node02' + # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '60' diff --git a/charts/generic/node-poweroff/experiment.yaml b/faults/kubernetes/node-poweroff/fault.yaml similarity index 54% rename from charts/generic/node-poweroff/experiment.yaml rename to faults/kubernetes/node-poweroff/fault.yaml index 35080e3..238f6a0 100644 --- a/charts/generic/node-poweroff/experiment.yaml +++ b/faults/kubernetes/node-poweroff/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - poweroff node + Poweroff a node in the cluster kind: ChaosExperiment metadata: name: node-poweroff @@ -17,70 +18,79 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + resources: ["configmaps", "secrets"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] + verbs: ["get", "list", "watch"] # for creating and managing to execute comands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list"] + verbs: ["get", "list"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name node-restart + - -c + - ./experiments -name node-restart command: - - /bin/bash + - /bin/bash env: - - name: SSH_USER - value: 'root' + - name: SSH_USER + value: "root" - - name: TOTAL_CHAOS_DURATION - value: '60' + - name: TOTAL_CHAOS_DURATION + value: "60" - - name: REBOOT_COMMAND - value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true' + - name: REBOOT_COMMAND + value: '-o ServerAliveInterval=1 -o ServerAliveCountMax=1 "sudo systemctl poweroff --force --force" ; true' - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" + # provide lib image + - name: LIB_IMAGE + value: "litmuschaos/go-runner:latest" - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' + # ENTER THE TARGET NODE NAME + - name: TARGET_NODE + value: "" - - name: NODE_LABEL - value: '' + - name: NODE_LABEL + value: "" - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' + # ENTER THE TARGET NODE IP + - name: TARGET_NODE_IP + value: "" labels: name: node-poweroff diff --git a/faults/kubernetes/node-poweroff/node-poweroff.chartserviceversion.yaml b/faults/kubernetes/node-poweroff/node-poweroff.chartserviceversion.yaml new file mode 100644 index 0000000..d879473 --- /dev/null +++ b/faults/kubernetes/node-poweroff/node-poweroff.chartserviceversion.yaml @@ -0,0 +1,29 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-poweroff + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node Poweroff + categoryDescription: | + Node poweroff contains chaos experiment to poweroff a node via SSH. + keywords: + - Kubernetes + platforms: + - KVM/LibVirt based K8s + - EKS + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: "" + mediatype: "" diff --git a/experiments/generic/node-restart/engine.yaml b/faults/kubernetes/node-restart/engine.yaml similarity index 73% rename from experiments/generic/node-restart/engine.yaml rename to faults/kubernetes/node-restart/engine.yaml index 71e3d70..0489d5e 100644 --- a/experiments/generic/node-restart/engine.yaml +++ b/faults/kubernetes/node-restart/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,16 +7,16 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' - chaosServiceAccount: node-restart-sa + chaosServiceAccount: litmus-admin experiments: - name: node-restart spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels - # kubernetes.io/hostname: 'node02' + # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '60' @@ -31,3 +32,6 @@ spec: # ENTER THE USER TO BE USED FOR SSH AUTH - name: SSH_USER value: 'root' + + - name: REBOOT_COMMAND + value: 'sudo systemctl reboot; true' diff --git a/charts/generic/node-restart/experiment.yaml b/faults/kubernetes/node-restart/fault.yaml similarity index 50% rename from charts/generic/node-restart/experiment.yaml rename to faults/kubernetes/node-restart/fault.yaml index 427ae0b..aa8d8f5 100644 --- a/charts/generic/node-restart/experiment.yaml +++ b/faults/kubernetes/node-restart/fault.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | @@ -9,7 +10,7 @@ metadata: name: node-restart app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -17,73 +18,87 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps & secrets details and mount it to the experiment pod (if specified) - apiGroups: [""] - resources: ["configmaps","secrets"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + resources: ["configmaps", "secrets"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list"] + verbs: ["get", "list"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name node-restart + - -c + - ./experiments -name node-restart command: - - /bin/bash + - /bin/bash env: - - name: SSH_USER - value: 'root' + - name: SSH_USER + value: "root" + - name: REBOOT_COMMAND + value: "sudo systemctl reboot; true" - - name: TOTAL_CHAOS_DURATION - value: '60' + - name: TOTAL_CHAOS_DURATION + value: "60" - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" - # ENTER THE TARGET NODE NAME - - name: TARGET_NODE - value: '' + # ENTER THE TARGET NODE NAME + - name: TARGET_NODE + value: "" - - name: NODE_LABEL - value: '' + - name: NODE_LABEL + value: "" - # ENTER THE TARGET NODE IP - - name: TARGET_NODE_IP - value: '' + # ENTER THE TARGET NODE IP + - name: TARGET_NODE_IP + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" labels: name: node-restart app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci secrets: - name: id-rsa mountPath: /mnt/ diff --git a/faults/kubernetes/node-restart/node-restart.chartserviceversion.yaml b/faults/kubernetes/node-restart/node-restart.chartserviceversion.yaml new file mode 100644 index 0000000..89ecde7 --- /dev/null +++ b/faults/kubernetes/node-restart/node-restart.chartserviceversion.yaml @@ -0,0 +1,25 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-restart + version: 0.1.0 + annotations: + categories: Kubernetes +spec: + displayName: Node Restart + categoryDescription: | + Node restart fault restarts a target node via SSH. + keywords: + - Kubernetes + platforms: + - KVM/LibVirt based K8s + - EKS + chaosType: infra + minKubeVersion: 1.12.0 + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/generic/node-taint/engine.yaml b/faults/kubernetes/node-taint/engine.yaml similarity index 72% rename from charts/generic/node-taint/engine.yaml rename to faults/kubernetes/node-taint/engine.yaml index 44cfc24..1a192c0 100644 --- a/charts/generic/node-taint/engine.yaml +++ b/faults/kubernetes/node-taint/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,26 +7,25 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' chaosServiceAccount: node-taint-sa experiments: - name: node-taint spec: components: - # nodeSelector: + # nodeSelector: # # provide the node labels - # kubernetes.io/hostname: 'node02' + # kubernetes.io/hostname: 'node02' env: - name: TOTAL_CHAOS_DURATION value: '60' - + # set target node name - name: TARGET_NODE value: '' - + # set taint label & effect # key=value:effect or key:effect - name: TAINTS - value: 'node.kubernetes.io/unreachable:NoExecute' - \ No newline at end of file + value: 'app.hce.io/chaos=true:NoSchedule' diff --git a/charts/generic/node-taint/experiment.yaml b/faults/kubernetes/node-taint/fault.yaml similarity index 54% rename from charts/generic/node-taint/experiment.yaml rename to faults/kubernetes/node-taint/fault.yaml index 3313490..60aac57 100644 --- a/charts/generic/node-taint/experiment.yaml +++ b/faults/kubernetes/node-taint/fault.yaml @@ -10,7 +10,7 @@ metadata: name: node-taint app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -18,68 +18,79 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] - resources: ["pods/exec","pods/eviction"] - verbs: ["get","list","create"] + resources: ["pods/exec", "pods/eviction"] + verbs: ["get", "list", "create"] # ignore daemonsets while draining the node - apiGroups: ["apps"] resources: ["daemonsets"] - verbs: ["list","get","delete"] + verbs: ["list", "get", "delete"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] # for experiment to perform node status checks - apiGroups: [""] resources: ["nodes"] - verbs: ["get","list","patch","update"] + verbs: ["get", "list", "patch", "update"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name node-taint + - -c + - ./experiments -name node-taint command: - - /bin/bash + - /bin/bash env: + - name: TARGET_NODE + value: "" - - name: TARGET_NODE - value: '' + - name: NODE_LABEL + value: "" - - name: NODE_LABEL - value: '' + - name: TOTAL_CHAOS_DURATION + value: "60" - - name: TOTAL_CHAOS_DURATION - value: '60' + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + # set taint label & effect + # key=value:effect or key:effect + - name: TAINTS + value: "" - # set taint label & effect - # key=value:effect or key:effect - - name: TAINTS - value: '' + - name: DEFAULT_HEALTH_CHECK + value: "false" labels: name: node-taint app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/node-taint/node-taint.chartserviceversion.yaml b/faults/kubernetes/node-taint/node-taint.chartserviceversion.yaml new file mode 100644 index 0000000..bfe3484 --- /dev/null +++ b/faults/kubernetes/node-taint/node-taint.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: node-taint + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Node Taint + categoryDescription: > + Taint the node where application pod is scheduled. + keywords: + - Kubernetes + platforms: + - GKE + - AWS(KOPS) + - Packet(Kubeadm) + - Konvoy + - EKS + - AKS + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: "" + mediatype: "" diff --git a/charts/generic/pod-autoscaler/engine.yaml b/faults/kubernetes/pod-autoscaler/engine.yaml similarity index 80% rename from charts/generic/pod-autoscaler/engine.yaml rename to faults/kubernetes/pod-autoscaler/engine.yaml index 65dfbf1..5215809 100644 --- a/charts/generic/pod-autoscaler/engine.yaml +++ b/faults/kubernetes/pod-autoscaler/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,12 +7,12 @@ metadata: spec: # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx + #ex. values: ns1:name=percona,ns2:run=nginx auxiliaryAppInfo: '' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-autoscaler-sa experiments: - name: pod-autoscaler @@ -25,4 +26,4 @@ spec: # number of replicas to scale - name: REPLICA_COUNT value: '5' - \ No newline at end of file + diff --git a/experiments/generic/pod-autoscaler/experiment.yaml b/faults/kubernetes/pod-autoscaler/fault.yaml similarity index 56% rename from experiments/generic/pod-autoscaler/experiment.yaml rename to faults/kubernetes/pod-autoscaler/fault.yaml index 3950980..6e152aa 100644 --- a/experiments/generic/pod-autoscaler/experiment.yaml +++ b/faults/kubernetes/pod-autoscaler/fault.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | @@ -9,7 +10,7 @@ metadata: name: pod-autoscaler app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Cluster @@ -17,62 +18,68 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # performs CRUD operations on the deployments and statefulsets - apiGroups: ["apps"] - resources: ["deployments","statefulsets"] - verbs: ["list","get","patch","update"] + resources: ["deployments", "statefulsets"] + verbs: ["list", "get", "patch", "update"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-autoscaler + - -c + - ./experiments -name pod-autoscaler command: - - /bin/bash + - /bin/bash env: + - name: TOTAL_CHAOS_DURATION + value: "60" - - name: TOTAL_CHAOS_DURATION - value: '60' + # Period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + # Number of replicas to scale + - name: REPLICA_COUNT + value: "5" - # Number of replicas to scale - - name: REPLICA_COUNT - value: '5' + - name: DEFAULT_HEALTH_CHECK + value: "false" - # PROVIDE THE LIB HERE - # ONLY LITMUS SUPPORTED - - name: LIB - value: 'litmus' - labels: name: pod-autoscaler app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml b/faults/kubernetes/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml new file mode 100644 index 0000000..0e4b791 --- /dev/null +++ b/faults/kubernetes/pod-autoscaler/pod-autoscaler.chartserviceversion.yaml @@ -0,0 +1,32 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-autoscaler + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Autoscaler + categoryDescription: | + This fault aims to check the ability of nodes to accommodate the number of replicas a given application pod. + It can be used for other cases as well, such as for checking the Node auto-scaling feature. For example, check if the pods are successfully rescheduled within a specified period in cases where the existing nodes are already running at the specified limits. + keywords: + - Kubernetes + platforms: + - GKE + - EKS + - Minikube + - AKS + chaosType: infra + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/experiments/generic/pod-cpu-hog-exec/engine.yaml b/faults/kubernetes/pod-cpu-hog-exec/engine.yaml similarity index 77% rename from experiments/generic/pod-cpu-hog-exec/engine.yaml rename to faults/kubernetes/pod-cpu-hog-exec/engine.yaml index c793410..e79c65d 100644 --- a/experiments/generic/pod-cpu-hog-exec/engine.yaml +++ b/faults/kubernetes/pod-cpu-hog-exec/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-cpu-hog-exec-sa experiments: - name: pod-cpu-hog-exec @@ -19,12 +20,12 @@ spec: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - #number of cpu cores to be consumed + #number of CPU cores to be consumed #verify the resources the app has been launched with - name: CPU_CORES value: '1' ## Percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' - \ No newline at end of file + value: '' + diff --git a/charts/generic/pod-memory-hog-exec/experiment.yaml b/faults/kubernetes/pod-cpu-hog-exec/fault.yaml similarity index 58% rename from charts/generic/pod-memory-hog-exec/experiment.yaml rename to faults/kubernetes/pod-cpu-hog-exec/fault.yaml index 6f22101..f3ea4dd 100644 --- a/charts/generic/pod-memory-hog-exec/experiment.yaml +++ b/faults/kubernetes/pod-cpu-hog-exec/fault.yaml @@ -2,15 +2,15 @@ apiVersion: litmuschaos.io/v1alpha1 description: message: | - Injects memory consumption on pods belonging to an app deployment + Injects CPU consumption on pods belonging to an app deployment kind: ChaosExperiment metadata: - name: pod-memory-hog-exec + name: pod-cpu-hog-exec labels: - name: pod-memory-hog-exec + name: pod-cpu-hog-exec app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -18,84 +18,99 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-memory-hog-exec + - -c + - ./experiments -name pod-cpu-hog-exec command: - - /bin/bash + - /bin/bash env: - name: TOTAL_CHAOS_DURATION - value: '60' + value: "60" - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' + ## Number of CPU cores to stress + - name: CPU_CORES + value: "1" - ## percentage of total pods to target + ## Percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: "" ## Period to wait before and after injection of chaos in sec - name: RAMP_TIME - value: '' - + value: "" + # The command to kill the chaos process - name: CHAOS_KILL_COMMAND - value: "kill $(find /proc -name exe -lname '*/dd' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}' | head -n 1)" - + value: "kill $(find /proc -name exe -lname '*/md5sum' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}')" + + - name: TARGET_CONTAINER + value: "" + + - name: TARGET_PODS + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE - value: 'parallel' - - - name: TARGET_PODS - value: '' + value: "parallel" labels: - name: pod-memory-hog-exec + name: pod-cpu-hog-exec app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml b/faults/kubernetes/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml new file mode 100644 index 0000000..f44feea --- /dev/null +++ b/faults/kubernetes/pod-cpu-hog-exec/pod-cpu-hog-exec.chartserviceversion.yaml @@ -0,0 +1,34 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-cpu-hog-exec + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod CPU Hog Exec + categoryDescription: | + pod-cpu-hog-exec fault consumes CPU resources of specified containers in Kubernetes pods. + - Causes high CPU resource consumption utilizing one or more cores by triggering md5sum commands. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - Kind + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-cpu-hog/engine.yaml b/faults/kubernetes/pod-cpu-hog/engine.yaml similarity index 73% rename from experiments/generic/pod-cpu-hog/engine.yaml rename to faults/kubernetes/pod-cpu-hog/engine.yaml index dfa9bbb..90f5da0 100644 --- a/experiments/generic/pod-cpu-hog/engine.yaml +++ b/faults/kubernetes/pod-cpu-hog/engine.yaml @@ -1,4 +1,4 @@ - +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -8,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-cpu-hog-sa experiments: - name: pod-cpu-hog @@ -21,16 +21,16 @@ spec: value: '60' # in seconds - name: CPU_CORES - value: '1' + value: '1' ## Percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: '' ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: 'containerd' # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: '/run/containerd/containerd.sock' diff --git a/charts/generic/pod-memory-hog/experiment.yaml b/faults/kubernetes/pod-cpu-hog/fault.yaml similarity index 55% rename from charts/generic/pod-memory-hog/experiment.yaml rename to faults/kubernetes/pod-cpu-hog/fault.yaml index 2c7afff..03722ff 100644 --- a/charts/generic/pod-memory-hog/experiment.yaml +++ b/faults/kubernetes/pod-cpu-hog/fault.yaml @@ -2,15 +2,15 @@ apiVersion: litmuschaos.io/v1alpha1 description: message: | - Injects memory consumption on pods belonging to an app deployment + Injects CPU consumption on pods belonging to an app deployment kind: ChaosExperiment metadata: - name: pod-memory-hog + name: pod-cpu-hog labels: - name: pod-memory-hog + name: pod-cpu-hog app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -18,105 +18,121 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-memory-hog + - -c + - ./experiments -name pod-cpu-hog command: - - /bin/bash + - /bin/bash env: - name: TOTAL_CHAOS_DURATION - value: '60' + value: "60" - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## Number of workers to perform stress - - name: NUMBER_OF_WORKERS - value: '1' + ## Number of CPU cores to stress + - name: CPU_CORES + value: "1" - ## percentage of total pods to target + ## LOAD CPU WITH GIVEN PERCENT LOADING FOR THE CPU STRESS WORKERS. + ## 0 IS EFFECTIVELY A SLEEP (NO LOAD) AND 100 IS FULL LOADING + - name: CPU_LOAD + value: "100" + + ## Percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: "" ## Period to wait before and after injection of chaos in sec - name: RAMP_TIME - value: '' + value: "" - ## It is used in pumba lib only + ## It is used in pumba lib only - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' + value: "chaosnative/go-runner:ci" - ## It is used in pumba lib only + ## It is used in pumba lib only - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' + value: "alexeiled/stress-ng:latest-ubuntu" ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: "containerd" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' + value: "/run/containerd/containerd.sock" + + - name: TARGET_CONTAINER + value: "" - name: TARGET_PODS - value: '' + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" # To select pods on specific node(s) - name: NODE_LABEL - value: '' + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" labels: - name: pod-memory-hog + name: pod-cpu-hog app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml b/faults/kubernetes/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml new file mode 100644 index 0000000..ec0a5a5 --- /dev/null +++ b/faults/kubernetes/pod-cpu-hog/pod-cpu-hog.chartserviceversion.yaml @@ -0,0 +1,39 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-cpu-hog + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod CPU Hog + categoryDescription: | + Pod-CPU-Hog fault consumes the CPU resources of specified containers in Kubernetes pods. + - Causes CPU resource consumption on specified application containers using cgroups and litmus nsutil which consume CPU resources of the given target containers. + - It can test the application's resilience to potential slowness/unavailability of some replicas due to high CPU load. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - Kind + experiments: + - pod-cpu-hog + - sock-shop + - sock-shop-promProbe + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-delete/python/engine.yaml b/faults/kubernetes/pod-delete/engine.yaml similarity index 89% rename from charts/generic/pod-delete/python/engine.yaml rename to faults/kubernetes/pod-delete/engine.yaml index c211c73..047908d 100644 --- a/charts/generic/pod-delete/python/engine.yaml +++ b/faults/kubernetes/pod-delete/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: pod-delete-sa @@ -23,7 +24,7 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '10' - + # pod failures without '--force' & default terminationGracePeriodSeconds - name: FORCE value: 'false' @@ -31,3 +32,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/experiments/generic/pod-dns-spoof/experiment.yaml b/faults/kubernetes/pod-delete/fault.yaml similarity index 58% rename from experiments/generic/pod-dns-spoof/experiment.yaml rename to faults/kubernetes/pod-delete/fault.yaml index 0e6cf5a..7db0c13 100644 --- a/experiments/generic/pod-dns-spoof/experiment.yaml +++ b/faults/kubernetes/pod-delete/fault.yaml @@ -1,15 +1,16 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames + Deletes a pod belonging to a deployment/statefulset/daemonset kind: ChaosExperiment metadata: - name: pod-dns-spoof + name: pod-delete labels: - name: pod-dns-spoof + name: pod-delete app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -17,95 +18,101 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always args: - -c - - ./experiments -name pod-dns-spoof + - ./experiments -name pod-delete command: - /bin/bash env: - - name: TARGET_CONTAINER - value: "" - - # provide lib image - - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" - - name: TOTAL_CHAOS_DURATION - value: "60" # in seconds + value: "15" - # Time period to wait before and after injection of chaos in sec + # Period to wait before and after injection of chaos in sec - name: RAMP_TIME value: "" + - name: FORCE + value: "true" + + - name: CHAOS_INTERVAL + value: "5" + ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: "" + - name: TARGET_CONTAINER + value: "" + - name: TARGET_PODS value: "" - # provide the name of container runtime, it supports docker, containerd, crio - - name: CONTAINER_RUNTIME - value: 'containerd' + - name: DEFAULT_HEALTH_CHECK + value: "false" - # provide the socket file path - - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE value: "parallel" - # map of the target hostnames eg. '{"abc.com":"spoofabc.com"}' . If empty no queries will be spoofed - - name: SPOOF_MAP - value: "" - labels: - experiment: pod-dns-spoof + name: pod-delete app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-delete/pod-delete.chartserviceversion.yaml b/faults/kubernetes/pod-delete/pod-delete.chartserviceversion.yaml new file mode 100644 index 0000000..b85ce7e --- /dev/null +++ b/faults/kubernetes/pod-delete/pod-delete.chartserviceversion.yaml @@ -0,0 +1,42 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-delete + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Delete + categoryDescription: | + Pod delete fault disrupts the state of Kubernetes resources. This fault injects random pod delete failures against specified application. + - Causes (forced/graceful) pod failure of random replicas of an application deployment. + - Tests deployment sanity (replica availability & uninterrupted service) and recovery workflows of the application pod. + keywords: + - Kubernetes + platforms: + - GKE + - Konvoy + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - Kind + - Rancher + - OpenShift(OKD) + experiments: + - pod-delete + - podtato-head + - sock-shop + - sock-shop-promProbe + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/charts/generic/pod-dns-error/engine.yaml b/faults/kubernetes/pod-dns-error/engine.yaml similarity index 89% rename from charts/generic/pod-dns-error/engine.yaml rename to faults/kubernetes/pod-dns-error/engine.yaml index 83fd6bb..c927738 100644 --- a/charts/generic/pod-dns-error/engine.yaml +++ b/faults/kubernetes/pod-dns-error/engine.yaml @@ -1,12 +1,13 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: name: nginx-chaos spec: appinfo: - appns: "default" - applabel: "app=nginx" - appkind: "deployment" + appns: "" + applabel: "" + appkind: "" # It can be active/stop engineState: "active" #ex. values: ns1:name=percona,ns2:run=nginx @@ -24,7 +25,7 @@ spec: - name: TARGET_HOSTNAMES value: "" - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring + # can be either exact or substring, determines whether the DNS query has to match exactly with one of the targets or can have any of the targets as substring - name: MATCH_SCHEME value: "exact" @@ -39,3 +40,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: "" + diff --git a/charts/generic/pod-dns-error/experiment.yaml b/faults/kubernetes/pod-dns-error/fault.yaml similarity index 70% rename from charts/generic/pod-dns-error/experiment.yaml rename to faults/kubernetes/pod-dns-error/fault.yaml index fc21808..edad300 100644 --- a/charts/generic/pod-dns-error/experiment.yaml +++ b/faults/kubernetes/pod-dns-error/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Pod DNS Error injects dns failure/error in target pod containers + Pod DNS Error injects DNS failure/error in target pod containers kind: ChaosExperiment metadata: name: pod-dns-error @@ -9,7 +10,7 @@ metadata: name: pod-dns-error app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -17,47 +18,56 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" args: - -c @@ -70,7 +80,10 @@ spec: # provide lib image - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" + value: "chaosnative/go-runner:ci" + + - name: DEFAULT_HEALTH_CHECK + value: "false" - name: TOTAL_CHAOS_DURATION value: "60" # in seconds @@ -88,11 +101,11 @@ spec: # provide the name of container runtime, it supports docker, containerd, crio - name: CONTAINER_RUNTIME - value: 'containerd' + value: "containerd" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: "/run/containerd/containerd.sock" ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel @@ -103,7 +116,7 @@ spec: - name: TARGET_HOSTNAMES value: "" - # can be either exact or substring, determines whether the dns query has to match exactly with one of the targets or can have any of the targets as substring + # can be either exact or substring, determines whether the DNS query has to match exactly with one of the targets or can have any of the targets as substring - name: MATCH_SCHEME value: "exact" @@ -111,5 +124,5 @@ spec: experiment: pod-dns-error app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-dns-error/pod-dns-error.chartserviceversion.yaml b/faults/kubernetes/pod-dns-error/pod-dns-error.chartserviceversion.yaml new file mode 100644 index 0000000..852d085 --- /dev/null +++ b/faults/kubernetes/pod-dns-error/pod-dns-error.chartserviceversion.yaml @@ -0,0 +1,24 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-dns-error + version: 0.1.0 + annotations: + categories: kubernetes +spec: + displayName: Pod DNS Error + categoryDescription: > + Pod DNS Error fault injects DNS failure/error in target pod containers. + keywords: + - Kubernetes + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-dns-spoof/engine.yaml b/faults/kubernetes/pod-dns-spoof/engine.yaml similarity index 93% rename from charts/generic/pod-dns-spoof/engine.yaml rename to faults/kubernetes/pod-dns-spoof/engine.yaml index a468d88..f6b1f5f 100644 --- a/charts/generic/pod-dns-spoof/engine.yaml +++ b/faults/kubernetes/pod-dns-spoof/engine.yaml @@ -1,12 +1,13 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: name: nginx-chaos spec: appinfo: - appns: "default" - applabel: "app=nginx" - appkind: "deployment" + appns: "" + applabel: "" + appkind: "" # It can be active/stop engineState: "active" #ex. values: ns1:name=percona,ns2:run=nginx @@ -35,3 +36,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: "" + diff --git a/charts/generic/pod-dns-spoof/experiment.yaml b/faults/kubernetes/pod-dns-spoof/fault.yaml similarity index 70% rename from charts/generic/pod-dns-spoof/experiment.yaml rename to faults/kubernetes/pod-dns-spoof/fault.yaml index 0e6cf5a..e4309bc 100644 --- a/charts/generic/pod-dns-spoof/experiment.yaml +++ b/faults/kubernetes/pod-dns-spoof/fault.yaml @@ -1,7 +1,8 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Pod DNS Spoof can spoof particular dns requests in target pod container to desired target hostnames + Pod DNS Spoof can spoof particular DNS requests in target pod container to desired target hostnames kind: ChaosExperiment metadata: name: pod-dns-spoof @@ -9,7 +10,7 @@ metadata: name: pod-dns-spoof app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -17,47 +18,56 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" args: - -c @@ -70,7 +80,10 @@ spec: # provide lib image - name: LIB_IMAGE - value: "litmuschaos/go-runner:latest" + value: "chaosnative/go-runner:ci" + + - name: DEFAULT_HEALTH_CHECK + value: "false" - name: TOTAL_CHAOS_DURATION value: "60" # in seconds @@ -88,11 +101,11 @@ spec: # provide the name of container runtime, it supports docker, containerd, crio - name: CONTAINER_RUNTIME - value: 'containerd' + value: "containerd" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: "/run/containerd/containerd.sock" ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel @@ -107,5 +120,5 @@ spec: experiment: pod-dns-spoof app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml b/faults/kubernetes/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml new file mode 100644 index 0000000..2569931 --- /dev/null +++ b/faults/kubernetes/pod-dns-spoof/pod-dns-spoof.chartserviceversion.yaml @@ -0,0 +1,24 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-dns-spoof + version: 0.1.0 + annotations: + categories: kubernetes +spec: + displayName: Pod DNS Spoof + categoryDescription: > + Pod DNS Spoof fault spoofs particular DNS requests in a target pod container to desired target hostnames. + keywords: + - Kubernetes + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-http-latency/engine.yaml b/faults/kubernetes/pod-http-latency/engine.yaml similarity index 90% rename from experiments/generic/pod-http-latency/engine.yaml rename to faults/kubernetes/pod-http-latency/engine.yaml index ed00d91..a3c47ac 100644 --- a/experiments/generic/pod-http-latency/engine.yaml +++ b/faults/kubernetes/pod-http-latency/engine.yaml @@ -1,16 +1,17 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: name: nginx-http-chaos namespace: default -spec: +spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' + applabel: '' + appkind: '' chaosServiceAccount: pod-http-latency-sa experiments: - name: pod-http-latency @@ -19,7 +20,7 @@ spec: env: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - + - name: LATENCY value: '2000' #in ms @@ -39,3 +40,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-http-latency/fault.yaml b/faults/kubernetes/pod-http-latency/fault.yaml new file mode 100644 index 0000000..ce04985 --- /dev/null +++ b/faults/kubernetes/pod-http-latency/fault.yaml @@ -0,0 +1,148 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Injects HTTP request latency on pods belonging to an app deployment +kind: ChaosExperiment +metadata: + name: pod-http-latency + labels: + name: pod-http-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-http-latency + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + - name: LATENCY + value: "2000" #in ms + + # port of the target service + - name: TARGET_SERVICE_PORT + value: "80" + + # toxicity is the probability of the request to be affected + # provide the percentage value in the range of 0-100 + # 0 means no request will be affected and 100 means all request will be affected + - name: TOXICITY + value: "100" + + # port on which the proxy will listen + - name: PROXY_PORT + value: "20000" + + # network interface on which the proxy will listen + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-http-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-http-latency/pod-http-latency.chartserviceversion.yaml b/faults/kubernetes/pod-http-latency/pod-http-latency.chartserviceversion.yaml new file mode 100644 index 0000000..b95f09b --- /dev/null +++ b/faults/kubernetes/pod-http-latency/pod-http-latency.chartserviceversion.yaml @@ -0,0 +1,31 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-http-latency + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod HTTP Latency + categoryDescription: | + Pod-http-latency fault disrupts HTTP requests of kubernetes pods. This fault can inject random HTTP response delays on the app replica pods. + - Causes flaky access to application replica by injecting HTTP response delay using toxiproxy. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - EKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-http-modify-body/engine.yaml b/faults/kubernetes/pod-http-modify-body/engine.yaml similarity index 93% rename from experiments/generic/pod-http-modify-body/engine.yaml rename to faults/kubernetes/pod-http-modify-body/engine.yaml index 918ae07..36fc8f9 100644 --- a/experiments/generic/pod-http-modify-body/engine.yaml +++ b/faults/kubernetes/pod-http-modify-body/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,9 +7,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-http-modify-body-sa experiments: - name: pod-http-modify-body @@ -39,3 +40,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-http-modify-body/fault.yaml b/faults/kubernetes/pod-http-modify-body/fault.yaml new file mode 100644 index 0000000..13cccf1 --- /dev/null +++ b/faults/kubernetes/pod-http-modify-body/fault.yaml @@ -0,0 +1,159 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It injects the chaos inside the pod which modifies the body of the response from the provided application server to the body string provided by the user and reverts after a specified duration +kind: ChaosExperiment +metadata: + name: pod-http-modify-body + labels: + name: pod-http-modify-body + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-http-modify-body + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # provide the body string to overwrite the response body + # if no value is provided, response will be an empty body. + - name: RESPONSE_BODY + value: "" + + # provide the encoding type for the response body + # currently supported value are gzip, deflate + # if empty no encoding will be applied + - name: CONTENT_ENCODING + value: "" + + # provide the content type for the response body + - name: CONTENT_TYPE + value: "text/plain" + + # port of the target service + - name: TARGET_SERVICE_PORT + value: "80" + + # toxicity is the probability of the request to be affected + # provide the percentage value in the range of 0-100 + # 0 means no request will be affected and 100 means all request will be affected + - name: TOXICITY + value: "100" + + # port on which the proxy will listen + - name: PROXY_PORT + value: "20000" + + # network interface on which the proxy will listen + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-http-modify-body + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml b/faults/kubernetes/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml new file mode 100644 index 0000000..8b36a5a --- /dev/null +++ b/faults/kubernetes/pod-http-modify-body/pod-http-modify-body.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-http-modify-body + version: 0.1.0 + annotations: + categories: kubernetes +spec: + displayName: Pod HTTP Modify Body + categoryDescription: > + Pod-http-modify-body fault disrupts HTTP requests of kubernetes pods. This fault can modify the body of the response from the service targetted. + - Causes modification of response body of the HTTP request. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - kubernetes + platforms: + - "Minikube" + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-http-modify-header/engine.yaml b/faults/kubernetes/pod-http-modify-header/engine.yaml similarity index 92% rename from experiments/generic/pod-http-modify-header/engine.yaml rename to faults/kubernetes/pod-http-modify-header/engine.yaml index 84ee278..d9233e3 100644 --- a/experiments/generic/pod-http-modify-header/engine.yaml +++ b/faults/kubernetes/pod-http-modify-header/engine.yaml @@ -1,16 +1,17 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: name: nginx-http-chaos namespace: default -spec: +spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' + applabel: '' + appkind: '' chaosServiceAccount: pod-http-modify-header-sa experiments: - name: pod-http-modify-header @@ -19,11 +20,11 @@ spec: env: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - + # port of the target service - name: TARGET_SERVICE_PORT value: "80" - + # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} - name: HEADERS_MAP @@ -45,3 +46,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-http-modify-header/fault.yaml b/faults/kubernetes/pod-http-modify-header/fault.yaml new file mode 100644 index 0000000..18f5980 --- /dev/null +++ b/faults/kubernetes/pod-http-modify-header/fault.yaml @@ -0,0 +1,154 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It injects the chaos inside the pod which modifies the header of the request/response from the provided application server to the headers provided by the user and reverts after a specified duration +kind: ChaosExperiment +metadata: + name: pod-http-modify-header + labels: + name: pod-http-modify-header + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-http-modify-header + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # map of headers to modify/add; Eg: {"X-Litmus-Test-Header": "X-Litmus-Test-Value"} + # to remove a header, just set the value to ""; Eg: {"X-Litmus-Test-Header": ""} + - name: HEADERS_MAP + value: "{}" + + # whether to modify response headers or request headers. Accepted values: request, response + - name: HEADER_MODE + value: "response" + + # port of the target service + - name: TARGET_SERVICE_PORT + value: "80" + + # toxicity is the probability of the request to be affected + # provide the percentage value in the range of 0-100 + # 0 means no request will be affected and 100 means all request will be affected + - name: TOXICITY + value: "100" + + # port on which the proxy will listen + - name: PROXY_PORT + value: "20000" + + # network interface on which the proxy will listen + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-http-modify-header + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml b/faults/kubernetes/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml new file mode 100644 index 0000000..20df729 --- /dev/null +++ b/faults/kubernetes/pod-http-modify-header/pod-http-modify-header.chartserviceversion.yaml @@ -0,0 +1,31 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-http-modify-header + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod HTTP Modify Header + categoryDescription: | + Pod-http-modify-header fault disrupts HTTP requests of kubernetes pods. This fault can modify headers of incoming requests or the response from the service targetted. + - Causes modification of request/response headers of the HTTP request. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - EKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + icon: + - base64data: "" + mediatype: "" + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents diff --git a/charts/generic/pod-http-reset-peer/engine.yaml b/faults/kubernetes/pod-http-reset-peer/engine.yaml similarity index 92% rename from charts/generic/pod-http-reset-peer/engine.yaml rename to faults/kubernetes/pod-http-reset-peer/engine.yaml index a052368..2c234cf 100644 --- a/charts/generic/pod-http-reset-peer/engine.yaml +++ b/faults/kubernetes/pod-http-reset-peer/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,10 +8,10 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' + applabel: '' + appkind: '' chaosServiceAccount: pod-http-reset-peer-sa experiments: - name: pod-http-reset-peer @@ -20,7 +21,7 @@ spec: # set chaos duration (in sec) as desired - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - + # reset timeout specifies after how much duration to reset the connection - name: RESET_TIMEOUT value: '0' #in ms @@ -45,4 +46,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file + diff --git a/faults/kubernetes/pod-http-reset-peer/fault.yaml b/faults/kubernetes/pod-http-reset-peer/fault.yaml new file mode 100644 index 0000000..fa7e3ba --- /dev/null +++ b/faults/kubernetes/pod-http-reset-peer/fault.yaml @@ -0,0 +1,148 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + it injects chaos into the pod which stops outgoing HTTP requests by resetting the TCP connection and then reverts back to the original state after a specified duration +kind: ChaosExperiment +metadata: + name: pod-http-reset-peer + labels: + name: pod-http-reset-peer + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-http-reset-peer + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # reset timeout specifies after how much duration to reset the connection + - name: RESET_TIMEOUT + value: "0" #in ms + + # port of the target service + - name: TARGET_SERVICE_PORT + value: "80" + + # toxicity is the probability of the request to be affected + # provide the percentage value in the range of 0-100 + # 0 means no request will be affected and 100 means all request will be affected + - name: TOXICITY + value: "100" + + # port on which the proxy will listen + - name: PROXY_PORT + value: "20000" + + # network interface on which the proxy will listen + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-http-reset-peer + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml b/faults/kubernetes/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml new file mode 100644 index 0000000..3a74e46 --- /dev/null +++ b/faults/kubernetes/pod-http-reset-peer/pod-http-reset-peer.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-http-reset-peer + version: 0.1.0 + annotations: + categories: kubernetes +spec: + displayName: Pod HTTP Reset Peer + categoryDescription: > + pod-http-reset-peer fault disrupts HTTP requests of kubernetes pods. This fault can stop outgoing HTTP requests by resetting the TCP connection on the service targetted. + - Causes connection failure (connection reset by peer) of the HTTP request. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - kubernetes + platforms: + - "Minikube" + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-http-status-code/engine.yaml b/faults/kubernetes/pod-http-status-code/engine.yaml similarity index 90% rename from charts/generic/pod-http-status-code/engine.yaml rename to faults/kubernetes/pod-http-status-code/engine.yaml index 95f368e..f819c01 100644 --- a/charts/generic/pod-http-status-code/engine.yaml +++ b/faults/kubernetes/pod-http-status-code/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,9 +7,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-http-status-code-sa experiments: - name: pod-http-status-code @@ -22,8 +23,8 @@ spec: # set chaos interval (in sec) as desired - name: CHAOS_INTERVAL value: '10' - - # modified status code for the http response + + # modified status code for the HTTP response # if no value is provided, a random status code from the supported code list will selected # if an invalid status code is provided, the experiment will fail # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504 @@ -33,7 +34,7 @@ spec: # whether to modify the body as per the status code provided - name: "MODIFY_RESPONSE_BODY" value: "true" - + # port of the target service - name: TARGET_SERVICE_PORT value: "80" @@ -51,4 +52,3 @@ spec: - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/kubernetes/pod-http-status-code/fault.yaml b/faults/kubernetes/pod-http-status-code/fault.yaml new file mode 100644 index 0000000..088b8d7 --- /dev/null +++ b/faults/kubernetes/pod-http-status-code/fault.yaml @@ -0,0 +1,169 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It injects chaos inside the pod which modifies the status code of the response from the provided application server to desired status code provided by the user and reverts after a specified duration +kind: ChaosExperiment +metadata: + name: pod-http-status-code + labels: + name: pod-http-status-code + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-http-status-code + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # modified status code for the HTTP response + # if no value is provided, a random status code from the supported code list will selected + # if an invalid status code is provided, the experiment will fail + # supported status code list: [200, 201, 202, 204, 300, 301, 302, 304, 307, 400, 401, 403, 404, 500, 501, 502, 503, 504] + - name: STATUS_CODE + value: "" + + # whether to modify the body as per the status code provided + - name: "MODIFY_RESPONSE_BODY" + value: "true" + + # provide the body string to overwrite the response body. This will be used only if MODIFY_RESPONSE_BODY is set to true + - name: RESPONSE_BODY + value: "" + + # provide the encoding type for the response body + # currently supported value are gzip, deflate + # if empty no encoding will be applied + - name: CONTENT_ENCODING + value: "" + + # provide the content type for the response body + - name: CONTENT_TYPE + value: "text/plain" + + # port of the target service + - name: TARGET_SERVICE_PORT + value: "80" + + # toxicity is the probability of the request to be affected + # provide the percentage value in the range of 0-100 + # 0 means no request will be affected and 100 means all request will be affected + - name: TOXICITY + value: "100" + + # port on which the proxy will listen + - name: PROXY_PORT + value: "20000" + + # network interface on which the proxy will listen + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-http-status-code + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml b/faults/kubernetes/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml new file mode 100644 index 0000000..cfde04d --- /dev/null +++ b/faults/kubernetes/pod-http-status-code/pod-http-status-code.chartserviceversion.yaml @@ -0,0 +1,28 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-http-status-code + version: 0.1.0 + annotations: + categories: kubernetes +spec: + displayName: Pod HTTP Status Code + categoryDescription: > + pod-http-status-code fault disrupts HTTP requests of kubernetes pods. This fault can modify the status code of the response on the service targetted. + - Causes modification of status code of the HTTP request. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - kubernetes + platforms: + - "Minikube" + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-io-stress/engine.yaml b/faults/kubernetes/pod-io-stress/engine.yaml similarity index 83% rename from charts/generic/pod-io-stress/engine.yaml rename to faults/kubernetes/pod-io-stress/engine.yaml index 4b49e1d..c9de57f 100644 --- a/charts/generic/pod-io-stress/engine.yaml +++ b/faults/kubernetes/pod-io-stress/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-io-stress-sa experiments: - name: pod-io-stress @@ -30,8 +31,9 @@ spec: ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: 'containerd' # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: '/run/containerd/containerd.sock' + diff --git a/experiments/generic/pod-io-stress/experiment.yaml b/faults/kubernetes/pod-io-stress/fault.yaml similarity index 68% rename from experiments/generic/pod-io-stress/experiment.yaml rename to faults/kubernetes/pod-io-stress/fault.yaml index 4594342..8441093 100644 --- a/experiments/generic/pod-io-stress/experiment.yaml +++ b/faults/kubernetes/pod-io-stress/fault.yaml @@ -10,7 +10,7 @@ metadata: name: pod-io-stress app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -18,117 +18,127 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-io-stress + - -c + - ./experiments -name pod-io-stress command: - - /bin/bash + - /bin/bash env: - name: TOTAL_CHAOS_DURATION - value: '120' + value: "120" ## specify the size as percentage of free space on the file system ## default value 90 (in percentage) - name: FILESYSTEM_UTILIZATION_PERCENTAGE - value: '10' + value: "10" ## we can specify the size in Gigabyte (Gb) also in place of percentage of free space ## NOTE: for selecting this option FILESYSTEM_UTILIZATION_PERCENTAGE should be empty - name: FILESYSTEM_UTILIZATION_BYTES - value: '' + value: "" ## Total number of workers default value is 4 - name: NUMBER_OF_WORKERS - value: '4' + value: "4" ## Percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: "" # provide volume mount path - name: VOLUME_MOUNT_PATH - value: '' + value: "" + + - name: TARGET_CONTAINER + value: "" ## specify the comma separated target pods - name: TARGET_PODS - value: '' + value: "" # To select pods on specific node(s) - name: NODE_LABEL - value: '' + value: "" # Period to wait before and after injection of chaos in sec - name: RAMP_TIME - value: '' - - # Provide the LIB here - # support litmus and pumba - - name: LIB - value: 'litmus' + value: "" # provide lib image - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' + value: "chaosnative/go-runner:ci" + + - name: DEFAULT_HEALTH_CHECK + value: "false" ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: "containerd" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: "/run/containerd/containerd.sock" ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE - value: 'parallel' + value: "parallel" labels: name: pod-io-stress app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-io-stress/pod-io-stress.chartserviceversion.yaml b/faults/kubernetes/pod-io-stress/pod-io-stress.chartserviceversion.yaml new file mode 100644 index 0000000..099efc3 --- /dev/null +++ b/faults/kubernetes/pod-io-stress/pod-io-stress.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-io-stress + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod IO Stress + categoryDescription: | + This fault causes disk IO stress on the application pod. It aims to verify the resiliency of applications that share this disk resource for ephemeral or persistent storage purposes. + - Consumes the disk available by executing filesystem IO stress as available memory or by providing the value in GB. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-memory-hog-exec/engine.yaml b/faults/kubernetes/pod-memory-hog-exec/engine.yaml similarity index 87% rename from experiments/generic/pod-memory-hog-exec/engine.yaml rename to faults/kubernetes/pod-memory-hog-exec/engine.yaml index 5bc6b0d..a7ec850 100644 --- a/experiments/generic/pod-memory-hog-exec/engine.yaml +++ b/faults/kubernetes/pod-memory-hog-exec/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-memory-hog-exec-sa experiments: - name: pod-memory-hog-exec @@ -26,4 +27,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file + diff --git a/experiments/generic/pod-memory-hog-exec/experiment.yaml b/faults/kubernetes/pod-memory-hog-exec/fault.yaml similarity index 68% rename from experiments/generic/pod-memory-hog-exec/experiment.yaml rename to faults/kubernetes/pod-memory-hog-exec/fault.yaml index 3f29e61..142f019 100644 --- a/experiments/generic/pod-memory-hog-exec/experiment.yaml +++ b/faults/kubernetes/pod-memory-hog-exec/fault.yaml @@ -10,7 +10,7 @@ metadata: name: pod-memory-hog-exec app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -18,89 +18,99 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-memory-hog-exec + - -c + - ./experiments -name pod-memory-hog-exec command: - - /bin/bash + - /bin/bash env: - name: TOTAL_CHAOS_DURATION - value: '60' + value: "60" ## enter the amount of memory in megabytes to be consumed by the application pod - name: MEMORY_CONSUMPTION - value: '500' + value: "500" ## percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: "" ## Period to wait before and after injection of chaos in sec - name: RAMP_TIME - value: '' + value: "" - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus - - name: LIB - value: 'litmus' - # The command to kill the chaos process - name: CHAOS_KILL_COMMAND value: "kill $(find /proc -name exe -lname '*/dd' 2>&1 | grep -v 'Permission denied' | awk -F/ '{print $(NF-1)}' | head -n 1)" - + ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE - value: 'parallel' + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: TARGET_CONTAINER + value: "" - name: TARGET_PODS - value: '' + value: "" labels: name: pod-memory-hog-exec app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml b/faults/kubernetes/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml new file mode 100644 index 0000000..258a8ca --- /dev/null +++ b/faults/kubernetes/pod-memory-hog-exec/pod-memory-hog-exec.chartserviceversion.yaml @@ -0,0 +1,34 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-memory-hog-exec + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Memory Hog Exec + categoryDescription: | + pod-memory-hog-exec fault consumes memory resources of specified containers in Kubernetes pods. + - Consumes the memory specified by executing a dd command against special files /dev/zero(input) and /dev/null(output). + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - OpenShift(OKD) + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-memory-hog/engine.yaml b/faults/kubernetes/pod-memory-hog/engine.yaml similarity index 79% rename from experiments/generic/pod-memory-hog/engine.yaml rename to faults/kubernetes/pod-memory-hog/engine.yaml index d039dee..799d502 100644 --- a/experiments/generic/pod-memory-hog/engine.yaml +++ b/faults/kubernetes/pod-memory-hog/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,9 +8,9 @@ spec: # It can be active/stop engineState: 'active' appinfo: - appns: 'default' - applabel: 'app=nginx' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' chaosServiceAccount: pod-memory-hog-sa experiments: - name: pod-memory-hog @@ -25,12 +26,13 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: '' ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: 'containerd' # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' + value: '/run/containerd/containerd.sock' + diff --git a/experiments/generic/pod-memory-hog/experiment.yaml b/faults/kubernetes/pod-memory-hog/fault.yaml similarity index 64% rename from experiments/generic/pod-memory-hog/experiment.yaml rename to faults/kubernetes/pod-memory-hog/fault.yaml index a8dccab..f3a4667 100644 --- a/experiments/generic/pod-memory-hog/experiment.yaml +++ b/faults/kubernetes/pod-memory-hog/fault.yaml @@ -10,7 +10,7 @@ metadata: name: pod-memory-hog app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -18,110 +18,120 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-memory-hog + - -c + - ./experiments -name pod-memory-hog command: - - /bin/bash + - /bin/bash env: - name: TOTAL_CHAOS_DURATION - value: '60' + value: "60" ## enter the amount of memory in megabytes to be consumed by the application pod - name: MEMORY_CONSUMPTION - value: '500' - + value: "500" + ## Number of workers to perform stress - name: NUMBER_OF_WORKERS - value: '1' + value: "1" ## percentage of total pods to target - name: PODS_AFFECTED_PERC - value: '' + value: "" ## Period to wait before and after injection of chaos in sec - name: RAMP_TIME - value: '' + value: "" - ## env var that describes the library used to execute the chaos - ## default: litmus. Supported values: litmus, pumba - - name: LIB - value: 'litmus' - - ## It is used in pumba lib only + ## It is used in pumba lib only - name: LIB_IMAGE - value: 'litmuschaos/go-runner:latest' + value: "chaosnative/go-runner:ci" - ## It is used in pumba lib only + ## It is used in pumba lib only - name: STRESS_IMAGE - value: 'alexeiled/stress-ng:latest-ubuntu' + value: "alexeiled/stress-ng:latest-ubuntu" ## provide the cluster runtime - name: CONTAINER_RUNTIME - value: 'containerd' + value: "containerd" # provide the socket file path - name: SOCKET_PATH - value: '/run/containerd/containerd.sock' - + value: "/run/containerd/containerd.sock" + ## it defines the sequence of chaos execution for multiple target pods ## supported values: serial, parallel - name: SEQUENCE - value: 'parallel' + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: TARGET_CONTAINER + value: "" - name: TARGET_PODS - value: '' + value: "" # To select pods on specific node(s) - name: NODE_LABEL - value: '' + value: "" labels: name: pod-memory-hog app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/runtime-api-usage: "true" - app.kubernetes.io/version: latest + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml b/faults/kubernetes/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml new file mode 100644 index 0000000..464b307 --- /dev/null +++ b/faults/kubernetes/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml @@ -0,0 +1,39 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-memory-hog + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Memory Hog + categoryDescription: | + Pod-Memory-Hog fault consumes memory resources of specified containers in Kubernetes pods. + - Causes memory resource consumption on specified application containers using cgroups and litmus nsutil that consume memory resources of the given target containers. + - It tests the application's resilience to potential slowness/unavailability of some replicas due to high memory load. + - The application pod should be healthy once chaos is stopped. Expectation is that service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + - OpenShift(OKD) + experiments: + - pod-memory-hog + - sock-shop + - sock-shop-promProbe + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-network-corruption/engine.yaml b/faults/kubernetes/pod-network-corruption/engine.yaml similarity index 92% rename from charts/generic/pod-network-corruption/engine.yaml rename to faults/kubernetes/pod-network-corruption/engine.yaml index 63570ea..2b9310e 100644 --- a/charts/generic/pod-network-corruption/engine.yaml +++ b/faults/kubernetes/pod-network-corruption/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,11 +7,11 @@ metadata: spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' + applabel: '' + appkind: '' chaosServiceAccount: pod-network-corruption-sa experiments: - name: pod-network-corruption @@ -36,3 +37,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-network-corruption/fault.yaml b/faults/kubernetes/pod-network-corruption/fault.yaml new file mode 100644 index 0000000..3e23a07 --- /dev/null +++ b/faults/kubernetes/pod-network-corruption/fault.yaml @@ -0,0 +1,146 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Inject network packet corruption into application pod +kind: ChaosExperiment +metadata: + name: pod-network-corruption + labels: + name: pod-network-corruption + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-network-corruption + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TC_IMAGE + value: "gaiadocker/iproute2" + + - name: NETWORK_PACKET_CORRUPTION_PERCENTAGE + value: "100" #in PERCENTAGE + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the destination ips + # chaos injection will be triggered for these destination ips + - name: DESTINATION_IPS + value: "" + + # provide the destination hosts + # chaos injection will be triggered for these destination hosts + - name: DESTINATION_HOSTS + value: "" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-network-corruption + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml b/faults/kubernetes/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml new file mode 100644 index 0000000..2e80257 --- /dev/null +++ b/faults/kubernetes/pod-network-corruption/pod-network-corruption.chartserviceversion.yaml @@ -0,0 +1,35 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2020-01-07T10:28:08Z + name: pod-network-corruption + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos + support: https://slack.kubernetes.io/ +spec: + displayName: Pod Network Corruption + categoryDescription: | + Pod-network-corruption fault disrupts network connectivity to kubernetes pods. This fault injects 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 + platforms: + - GKE + - Packet(Kubeadm) + - Minikube + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-network-duplication/engine.yaml b/faults/kubernetes/pod-network-duplication/engine.yaml similarity index 86% rename from charts/generic/pod-network-duplication/engine.yaml rename to faults/kubernetes/pod-network-duplication/engine.yaml index 7c1faed..5141f52 100644 --- a/charts/generic/pod-network-duplication/engine.yaml +++ b/faults/kubernetes/pod-network-duplication/engine.yaml @@ -1,4 +1,5 @@ # chaosengine.yaml +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,12 +8,12 @@ metadata: spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-duplication-sa + applabel: '' + appkind: '' + chaosServiceAccount: pod-network-duplication-sa experiments: - name: pod-network-duplication spec: @@ -23,7 +24,7 @@ spec: - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE value: '100' - + # provide the name of container runtime # for litmus LIB, it supports docker, containerd, crio # for pumba LIB, it supports docker only @@ -33,7 +34,8 @@ spec: # provide the socket file path - name: SOCKET_PATH value: '/run/containerd/containerd.sock' - + ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-network-duplication/fault.yaml b/faults/kubernetes/pod-network-duplication/fault.yaml new file mode 100644 index 0000000..6478737 --- /dev/null +++ b/faults/kubernetes/pod-network-duplication/fault.yaml @@ -0,0 +1,144 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Injects network packet duplication on pods belonging to an app deployment +kind: ChaosExperiment +metadata: + name: pod-network-duplication + labels: + name: pod-network-duplication + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-network-duplication + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "60" + + - name: RAMP_TIME + value: "" + + - name: TARGET_CONTAINER + value: "" + + - name: TC_IMAGE + value: "gaiadocker/iproute2" + + - name: NETWORK_INTERFACE + value: "eth0" + + - name: NETWORK_PACKET_DUPLICATION_PERCENTAGE + value: "100" # in percentage + + - name: TARGET_PODS + value: "" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # provide the destination ips + # chaos injection will be triggered for these destination ips + - name: DESTINATION_IPS + value: "" + + # provide the destination hosts + # chaos injection will be triggered for these destination hosts + - name: DESTINATION_HOSTS + value: "" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-network-duplication + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml b/faults/kubernetes/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml new file mode 100644 index 0000000..fe24d5f --- /dev/null +++ b/faults/kubernetes/pod-network-duplication/pod-network-duplication.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-network-duplication + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Network Duplication + categoryDescription: | + Pod-network-duplication fault disrupts network connectivity to kubernetes pods. This fault injects percentage packet duplication on the app replica pods. + - Causes lossy access to application replica by injecting packet duplication 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 + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/experiments/generic/pod-network-latency/engine.yaml b/faults/kubernetes/pod-network-latency/engine.yaml similarity index 88% rename from experiments/generic/pod-network-latency/engine.yaml rename to faults/kubernetes/pod-network-latency/engine.yaml index aa4396c..3529ae2 100644 --- a/experiments/generic/pod-network-latency/engine.yaml +++ b/faults/kubernetes/pod-network-latency/engine.yaml @@ -1,16 +1,17 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: name: nginx-network-chaos namespace: default -spec: +spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' + applabel: '' + appkind: '' chaosServiceAccount: pod-network-latency-sa experiments: - name: pod-network-latency @@ -24,7 +25,7 @@ spec: value: '2000' - name: JITTER - value: '0' + value: '0' # provide the name of container runtime # for litmus LIB, it supports docker, containerd, crio @@ -39,3 +40,4 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' + diff --git a/faults/kubernetes/pod-network-latency/fault.yaml b/faults/kubernetes/pod-network-latency/fault.yaml new file mode 100644 index 0000000..92d92bb --- /dev/null +++ b/faults/kubernetes/pod-network-latency/fault.yaml @@ -0,0 +1,149 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Injects network latency on pods belonging to an app deployment +kind: ChaosExperiment +metadata: + name: pod-network-latency + labels: + name: pod-network-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-network-latency + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + - name: NETWORK_INTERFACE + value: "eth0" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + - name: TC_IMAGE + value: "gaiadocker/iproute2" + + - name: NETWORK_LATENCY + value: "2000" #in ms + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # Time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: JITTER + value: "0" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: TARGET_PODS + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # provide the destination ips + # chaos injection will be triggered for these destination ips + - name: DESTINATION_IPS + value: "" + + # provide the destination hosts + # chaos injection will be triggered for these destination hosts + - name: DESTINATION_HOSTS + value: "" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-network-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-network-latency/pod-network-latency.chartserviceversion.yaml b/faults/kubernetes/pod-network-latency/pod-network-latency.chartserviceversion.yaml new file mode 100644 index 0000000..56d084a --- /dev/null +++ b/faults/kubernetes/pod-network-latency/pod-network-latency.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-network-latency + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Network Latency + categoryDescription: | + Pod-network-latency fault disrupts network connectivity of Kubernetes pods. This fault injects random network delays on the app replica pods. + - Causes flaky access to application replica by injecting network delay using Pumba. + - The application pod should be healthy once chaos is stopped. Service-requests should be served despite chaos. + keywords: + - Kubernetes + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + - AKS + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-network-loss/engine.yaml b/faults/kubernetes/pod-network-loss/engine.yaml similarity index 84% rename from charts/generic/pod-network-loss/engine.yaml rename to faults/kubernetes/pod-network-loss/engine.yaml index 96599ae..8dda8d7 100644 --- a/charts/generic/pod-network-loss/engine.yaml +++ b/faults/kubernetes/pod-network-loss/engine.yaml @@ -1,4 +1,4 @@ -# chaosengine.yaml +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -7,12 +7,12 @@ metadata: spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-loss-sa + applabel: '' + appkind: '' + chaosServiceAccount: pod-network-loss-sa experiments: - name: pod-network-loss spec: @@ -20,7 +20,7 @@ spec: env: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds - + - name: NETWORK_PACKET_LOSS_PERCENTAGE value: '100' @@ -33,8 +33,8 @@ spec: # provide the socket file path - name: SOCKET_PATH value: '/run/containerd/containerd.sock' - + ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file + diff --git a/faults/kubernetes/pod-network-loss/fault.yaml b/faults/kubernetes/pod-network-loss/fault.yaml new file mode 100644 index 0000000..5095fe9 --- /dev/null +++ b/faults/kubernetes/pod-network-loss/fault.yaml @@ -0,0 +1,146 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Injects network packet loss on pods belonging to an app deployment +kind: ChaosExperiment +metadata: + name: pod-network-loss + labels: + name: pod-network-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) + - apiGroups: ["apps"] + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: ["apps.openshift.io"] + resources: ["deploymentconfigs"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) + - apiGroups: [""] + resources: ["replicationcontrollers"] + verbs: ["get", "list"] + # deriving the parent/owner details of the pod(if parent is argo-rollouts) + - apiGroups: ["argoproj.io"] + resources: ["rollouts"] + verbs: ["list", "get"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-network-loss + command: + - /bin/bash + env: + - name: TARGET_CONTAINER + value: "" + + # provide lib image + - name: LIB_IMAGE + value: "chaosnative/go-runner:ci" + + - name: NETWORK_INTERFACE + value: "eth0" + + - name: TC_IMAGE + value: "gaiadocker/iproute2" + + - name: NETWORK_PACKET_LOSS_PERCENTAGE + value: "100" #in PERCENTAGE + + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + - name: TARGET_PODS + value: "" + + # To select pods on specific node(s) + - name: NODE_LABEL + value: "" + + # provide the name of container runtime + # for litmus LIB, it supports docker, containerd, crio + # for pumba LIB, it supports docker only + - name: CONTAINER_RUNTIME + value: "containerd" + + # provide the destination ips + # chaos injection will be triggered for these destination ips + - name: DESTINATION_IPS + value: "" + + # provide the destination hosts + # chaos injection will be triggered for these destination hosts + - name: DESTINATION_HOSTS + value: "" + + # provide the socket file path + - name: SOCKET_PATH + value: "/run/containerd/containerd.sock" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: pod-network-loss + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/runtime-api-usage: "true" + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-network-loss/pod-network-loss.chartserviceversion.yaml b/faults/kubernetes/pod-network-loss/pod-network-loss.chartserviceversion.yaml new file mode 100644 index 0000000..6593f69 --- /dev/null +++ b/faults/kubernetes/pod-network-loss/pod-network-loss.chartserviceversion.yaml @@ -0,0 +1,36 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-network-loss + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Network Loss + categoryDescription: | + Pod-network-loss fault disrupts network connectivity to kubernetes pods. This fault injects percentage packet loss on the app replica pods. + - Causes loss of access to application replica by injecting packet loss 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 + platforms: + - GKE + - Minikube + - Packet(Kubeadm) + - EKS + experiments: + - bank-of-anthos + - sock-shop + - sock-shop-promProbe + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/generic/pod-network-partition/engine.yaml b/faults/kubernetes/pod-network-partition/engine.yaml similarity index 75% rename from charts/generic/pod-network-partition/engine.yaml rename to faults/kubernetes/pod-network-partition/engine.yaml index ef656e1..30c3bc2 100644 --- a/charts/generic/pod-network-partition/engine.yaml +++ b/faults/kubernetes/pod-network-partition/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -6,12 +7,12 @@ metadata: spec: # It can be active/stop engineState: 'active' - appinfo: - appns: 'default' + appinfo: + appns: '' # FYI, To see app label, apply kubectl get pods --show-labels - applabel: 'app=nginx' - appkind: 'deployment' - chaosServiceAccount: pod-network-partition-sa + applabel: '' + appkind: '' + chaosServiceAccount: pod-network-partition-sa experiments: - name: pod-network-partition spec: @@ -19,3 +20,4 @@ spec: env: - name: TOTAL_CHAOS_DURATION value: '60' # in seconds + diff --git a/faults/kubernetes/pod-network-partition/fault.yaml b/faults/kubernetes/pod-network-partition/fault.yaml new file mode 100644 index 0000000..6fbc1e4 --- /dev/null +++ b/faults/kubernetes/pod-network-partition/fault.yaml @@ -0,0 +1,108 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + Injects 100% network packet loss on pods belonging to an app deployment +kind: ChaosExperiment +metadata: + name: pod-network-partition + labels: + name: pod-network-partition + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Fetch configmaps details and mount it to the experiment pod (if specified) + - apiGroups: [""] + resources: ["configmaps"] + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # performs CRUD operations on the network policies + - apiGroups: ["networking.k8s.io"] + resources: ["networkpolicies"] + verbs: ["create", "delete", "list", "get"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name pod-network-partition + command: + - /bin/bash + env: + - name: TOTAL_CHAOS_DURATION + value: "60" # in seconds + + # time period to wait before and after injection of chaos in sec + - name: RAMP_TIME + value: "" + + - name: DEFAULT_HEALTH_CHECK + value: "false" + + # provide the destination ips + # chaos injection will be triggered for these destination ips + - name: DESTINATION_IPS + value: "" + + # provide the destination hosts + # chaos injection will be triggered for these destination hosts + - name: DESTINATION_HOSTS + value: "" + + # provide network policy type + # support ingress, egress, all values + - name: POLICY_TYPES + value: "all" + + # provide labels of the destination pods + - name: POD_SELECTOR + value: "" + + # provide labels the destination namespaces + - name: NAMESPACE_SELECTOR + value: "" + + # provide comma separated ports + - name: PORTS + value: "" + + labels: + name: pod-network-partition + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/faults/kubernetes/pod-network-partition/pod-network-partition.chartserviceversion.yaml b/faults/kubernetes/pod-network-partition/pod-network-partition.chartserviceversion.yaml new file mode 100644 index 0000000..51bab8e --- /dev/null +++ b/faults/kubernetes/pod-network-partition/pod-network-partition.chartserviceversion.yaml @@ -0,0 +1,29 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: pod-network-partition + version: 0.1.0 + annotations: + categories: Kubernetes + vendor: LitmusChaos +spec: + displayName: Pod Network Partition + categoryDescription: | + pod-network-partition fault disrupts network connectivity to kubernetes pods. This fault injects complete egress/ingress network loss based on label and namespace selectors. + - The application pod should be healthy once chaos is stopped. Service-requests should be served (say, via alternate replicas) despite chaos. + keywords: + - Kubernetes + platforms: + - Minikube + - Packet(Kubeadm) + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - base64data: "" + mediatype: "" diff --git a/charts/spring-boot/icons/spring-boot-app-kill.png b/faults/spring-boot/icons/spring-boot-app-kill.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-app-kill.png rename to faults/spring-boot/icons/spring-boot-app-kill.png diff --git a/charts/spring-boot/icons/spring-boot-cpu-stress.png b/faults/spring-boot/icons/spring-boot-cpu-stress.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-cpu-stress.png rename to faults/spring-boot/icons/spring-boot-cpu-stress.png diff --git a/charts/spring-boot/icons/spring-boot-exceptions.png b/faults/spring-boot/icons/spring-boot-exceptions.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-exceptions.png rename to faults/spring-boot/icons/spring-boot-exceptions.png diff --git a/charts/spring-boot/icons/spring-boot-faults.png b/faults/spring-boot/icons/spring-boot-faults.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-faults.png rename to faults/spring-boot/icons/spring-boot-faults.png diff --git a/charts/spring-boot/icons/spring-boot-latency.png b/faults/spring-boot/icons/spring-boot-latency.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-latency.png rename to faults/spring-boot/icons/spring-boot-latency.png diff --git a/charts/spring-boot/icons/spring-boot-memory-stress.png b/faults/spring-boot/icons/spring-boot-memory-stress.png similarity index 100% rename from charts/spring-boot/icons/spring-boot-memory-stress.png rename to faults/spring-boot/icons/spring-boot-memory-stress.png diff --git a/charts/spring-boot/icons/spring-boot.png b/faults/spring-boot/icons/spring-boot.png similarity index 100% rename from charts/spring-boot/icons/spring-boot.png rename to faults/spring-boot/icons/spring-boot.png diff --git a/charts/spring-boot/spring-boot-app-kill/engine.yaml b/faults/spring-boot/spring-boot-app-kill/engine.yaml similarity index 85% rename from charts/spring-boot/spring-boot-app-kill/engine.yaml rename to faults/spring-boot/spring-boot-app-kill/engine.yaml index 81def27..86be567 100644 --- a/charts/spring-boot/spring-boot-app-kill/engine.yaml +++ b/faults/spring-boot/spring-boot-app-kill/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-app-kill-sa @@ -23,4 +24,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-app-kill/fault.yaml b/faults/spring-boot/spring-boot-app-kill/fault.yaml new file mode 100644 index 0000000..c18511b --- /dev/null +++ b/faults/spring-boot/spring-boot-app-kill/fault.yaml @@ -0,0 +1,94 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill +kind: ChaosExperiment +metadata: + name: spring-boot-app-kill + labels: + name: spring-boot-app-kill + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-app-kill + command: + - /bin/bash + env: + # port of the spring boot application + - name: CM_PORT + value: "" + + #it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-app-kill + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml b/faults/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml similarity index 55% rename from charts/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml index 184c530..fcb35b1 100644 --- a/charts/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-app-kill/spring-boot-app-kill.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-app-kill version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-app-kill categoryDescription: | - This experiment allows injecting Chaos Monkey app-kill assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey app-kill assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-app-kill - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-app-kill - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-app-kill/experiment.yaml diff --git a/charts/spring-boot/spring-boot-cpu-stress/engine.yaml b/faults/spring-boot/spring-boot-cpu-stress/engine.yaml similarity index 90% rename from charts/spring-boot/spring-boot-cpu-stress/engine.yaml rename to faults/spring-boot/spring-boot-cpu-stress/engine.yaml index e79586d..4bf5283 100644 --- a/charts/spring-boot/spring-boot-cpu-stress/engine.yaml +++ b/faults/spring-boot/spring-boot-cpu-stress/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-cpu-stress-sa @@ -32,4 +33,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-cpu-stress/fault.yaml b/faults/spring-boot/spring-boot-cpu-stress/fault.yaml new file mode 100644 index 0000000..a86043d --- /dev/null +++ b/faults/spring-boot/spring-boot-cpu-stress/fault.yaml @@ -0,0 +1,102 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress +kind: ChaosExperiment +metadata: + name: spring-boot-cpu-stress + labels: + name: spring-boot-cpu-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-cpu-stress + command: + - /bin/bash + env: + # it contains fraction of cpu to be stressed(0.95 equals 95%) + # it supports value in range [0.1,1.0] + - name: CPU_LOAD_FRACTION + value: "0.9" + + # port of the spring boot application + - name: CM_PORT + value: "" + + #it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + - name: TOTAL_CHAOS_DURATION + value: "30" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-cpu-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml b/faults/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml similarity index 55% rename from charts/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml index a040b37..9575b11 100644 --- a/charts/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-cpu-stress/spring-boot-cpu-stress.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-cpu-stress version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-cpu-stress categoryDescription: | - This experiment allows injecting Chaos Monkey cpu stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey cpu stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject CPU stress. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-cpu-stress - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-cpu-stress - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-cpu-stress/experiment.yaml diff --git a/charts/spring-boot/spring-boot-exceptions/engine.yaml b/faults/spring-boot/spring-boot-exceptions/engine.yaml similarity index 91% rename from charts/spring-boot/spring-boot-exceptions/engine.yaml rename to faults/spring-boot/spring-boot-exceptions/engine.yaml index fb496bc..f4366d4 100644 --- a/charts/spring-boot/spring-boot-exceptions/engine.yaml +++ b/faults/spring-boot/spring-boot-exceptions/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-exceptions-sa @@ -35,4 +36,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-exceptions/fault.yaml b/faults/spring-boot/spring-boot-exceptions/fault.yaml new file mode 100644 index 0000000..1346377 --- /dev/null +++ b/faults/spring-boot/spring-boot-exceptions/fault.yaml @@ -0,0 +1,105 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency +kind: ChaosExperiment +metadata: + name: spring-boot-exceptions + labels: + name: spring-boot-exceptions + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-exceptions + command: + - /bin/bash + env: + # Type of raised exception + - name: CM_EXCEPTIONS_TYPE + value: "java.lang.IllegalArgumentException" + + # Argument of raised exception + - name: CM_EXCEPTIONS_ARGUMENTS + value: "java.lang.String:custom illegal argument exception" + + # port of the spring boot application + - name: CM_PORT + value: "" + + #it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + - name: TOTAL_CHAOS_DURATION + value: "30" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-exceptions + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml b/faults/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml similarity index 55% rename from charts/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml index ac9e8ee..97a16a6 100644 --- a/charts/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-exceptions/spring-boot-exceptions.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-exceptions version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-exceptions categoryDescription: | - This experiment allows injecting Chaos Monkey exceptions assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey exceptions assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject exception. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-exceptions - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-exceptions - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-exceptions/experiment.yaml diff --git a/charts/spring-boot/spring-boot-faults/engine.yaml b/faults/spring-boot/spring-boot-faults/engine.yaml similarity index 96% rename from charts/spring-boot/spring-boot-faults/engine.yaml rename to faults/spring-boot/spring-boot-faults/engine.yaml index ce886a0..a869d92 100644 --- a/charts/spring-boot/spring-boot-faults/engine.yaml +++ b/faults/spring-boot/spring-boot-faults/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-faults-sa @@ -74,4 +75,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-faults/fault.yaml b/faults/spring-boot/spring-boot-faults/fault.yaml new file mode 100644 index 0000000..cefa263 --- /dev/null +++ b/faults/spring-boot/spring-boot-faults/fault.yaml @@ -0,0 +1,144 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress +kind: ChaosExperiment +metadata: + name: spring-boot-faults + labels: + name: spring-boot-faults + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-faults + command: + - /bin/bash + env: + # it enables spring app-kill fault + - name: CM_KILL_APPLICATION_ACTIVE + value: "" + + # it enables spring-boot latency fault + - name: CM_LATENCY_ACTIVE + value: "" + + # provide the latency (ms) + # it is applicable when latency is active + - name: LATENCY + value: "2000" + + # it enables spring-boot memory stress fault + - name: CM_MEMORY_ACTIVE + value: "" + + # it contains fraction of memory to be stressed(0.70 equals 70%) + # it supports value in range [0.01,0.95] + # it is applicable when memory is active + - name: MEMORY_FILL_FRACTION + value: "0.70" + + # it enables spring-boot cpu stress fault + - name: CM_CPU_ACTIVE + value: "" + + # it contains fraction of cpu to be stressed(0.95 equals 95%) + # it supports value in range [0.1,1.0] + # it is applicable when cpu is active + - name: CPU_LOAD_FRACTION + value: "0.9" + + # it enables spring-boot exceptions fault + - name: CM_EXCEPTIONS_ACTIVE + value: "" + + # Type of raised exception + # it is applicable when exceptions is active + - name: CM_EXCEPTIONS_TYPE + value: "java.lang.IllegalArgumentException" + + # Argument of raised exception + # it is applicable when exceptions is active + - name: CM_EXCEPTIONS_ARGUMENTS + value: "java.lang.String:custom illegal argument exception" + + # port of the spring boot application + - name: CM_PORT + value: "" + + #it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + - name: TOTAL_CHAOS_DURATION + value: "30" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-faults + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml b/faults/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml similarity index 56% rename from charts/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml index 78e5055..ab74fb8 100644 --- a/charts/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-faults/spring-boot-faults.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-faults version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-faults categoryDescription: | - This experiment allows injecting Chaos Monkey assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject Spring Boot faults. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-faults - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-faults - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-faults/experiment.yaml diff --git a/charts/spring-boot/spring-boot-latency/engine.yaml b/faults/spring-boot/spring-boot-latency/engine.yaml similarity index 88% rename from charts/spring-boot/spring-boot-latency/engine.yaml rename to faults/spring-boot/spring-boot-latency/engine.yaml index d34469c..61d4590 100644 --- a/charts/spring-boot/spring-boot-latency/engine.yaml +++ b/faults/spring-boot/spring-boot-latency/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-latency-sa @@ -31,4 +32,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-latency/fault.yaml b/faults/spring-boot/spring-boot-latency/fault.yaml new file mode 100644 index 0000000..149f8c2 --- /dev/null +++ b/faults/spring-boot/spring-boot-latency/fault.yaml @@ -0,0 +1,101 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency +kind: ChaosExperiment +metadata: + name: spring-boot-latency + labels: + name: spring-boot-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-latency + command: + - /bin/bash + env: + # provide the latency (ms) + - name: LATENCY + value: "2000" + + # port of the spring boot application + - name: CM_PORT + value: "" + + # it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + - name: TOTAL_CHAOS_DURATION + value: "30" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-latency + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml b/faults/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml similarity index 55% rename from charts/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml index f8553bd..40d8343 100644 --- a/charts/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-latency/spring-boot-latency.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-latency version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-latency categoryDescription: | - This experiment allows injecting Chaos Monkey network latency assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey network latency assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject latency. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-latency - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-latency - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-latency/experiment.yaml diff --git a/charts/spring-boot/spring-boot-memory-stress/engine.yaml b/faults/spring-boot/spring-boot-memory-stress/engine.yaml similarity index 90% rename from charts/spring-boot/spring-boot-memory-stress/engine.yaml rename to faults/spring-boot/spring-boot-memory-stress/engine.yaml index 16da3a5..042c2ba 100644 --- a/charts/spring-boot/spring-boot-memory-stress/engine.yaml +++ b/faults/spring-boot/spring-boot-memory-stress/engine.yaml @@ -1,3 +1,4 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: @@ -5,9 +6,9 @@ metadata: namespace: default spec: appinfo: - appns: 'default' - applabel: 'app=spring-boot' - appkind: 'deployment' + appns: '' + applabel: '' + appkind: '' # It can be active/stop engineState: 'active' chaosServiceAccount: spring-boot-memory-stress-sa @@ -32,4 +33,3 @@ spec: ## percentage of total pods to target - name: PODS_AFFECTED_PERC value: '' - \ No newline at end of file diff --git a/faults/spring-boot/spring-boot-memory-stress/fault.yaml b/faults/spring-boot/spring-boot-memory-stress/fault.yaml new file mode 100644 index 0000000..43ba3c1 --- /dev/null +++ b/faults/spring-boot/spring-boot-memory-stress/fault.yaml @@ -0,0 +1,102 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +description: + message: | + It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress +kind: ChaosExperiment +metadata: + name: spring-boot-memory-stress + labels: + name: spring-boot-memory-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: chaosexperiment + app.kubernetes.io/version: ci +spec: + definition: + scope: Namespaced + permissions: + # Create and monitor the experiment & helper pods + - apiGroups: [""] + resources: ["pods"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] + # Performs CRUD operations on the events inside chaosengine and chaosresult + - apiGroups: [""] + resources: ["events"] + verbs: ["create", "get", "list", "patch", "update"] + # Track and get the runner, experiment, and helper pods log + - apiGroups: [""] + resources: ["pods/log"] + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container + - apiGroups: [""] + resources: ["pods/exec"] + verbs: ["get", "list", "create"] + # for configuring and monitor the experiment job by the chaos-runner pod + - apiGroups: ["batch"] + resources: ["jobs"] + verbs: ["create", "list", "get", "delete", "deletecollection"] + # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow + - apiGroups: ["litmuschaos.io"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] + image: "litmuschaos/go-runner:latest" + imagePullPolicy: Always + args: + - -c + - ./experiments -name spring-boot-memory-stress + command: + - /bin/bash + env: + # it contains fraction of memory to be stressed(0.70 equals 70%) + # it supports value in range [0.01,0.95] + - name: MEMORY_FILL_FRACTION + value: "0.70" + + # port of the spring boot application + - name: CM_PORT + value: "" + + # it contains number of requests are to be attacked + # n value means nth request will be affected + - name: CM_LEVEL + value: "1" + + # it limits watched packages/classes/methods + - name: CM_WATCHED_CUSTOM_SERVICES + value: "" + + # provide name of watcher + # it supports controller, restController, service, repository, component, webClient + - name: CM_WATCHERS + value: "restController" + + - name: TOTAL_CHAOS_DURATION + value: "30" + + ## percentage of total pods to target + - name: PODS_AFFECTED_PERC + value: "" + + ## Period to wait before and after injection of chaos + - name: RAMP_TIME + value: "" + + ## it defines the sequence of chaos execution for multiple target pods + ## supported values: serial, parallel + - name: SEQUENCE + value: "parallel" + + labels: + name: spring-boot-memory-stress + app.kubernetes.io/part-of: litmus + app.kubernetes.io/component: experiment-job + app.kubernetes.io/version: ci diff --git a/charts/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml b/faults/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml similarity index 55% rename from charts/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml rename to faults/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml index 568687c..821e35a 100644 --- a/charts/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml +++ b/faults/spring-boot/spring-boot-memory-stress/spring-boot-memory-stress.chartserviceversion.yaml @@ -1,23 +1,19 @@ -apiVersion: litmuchaos.io/v1alpha1 +--- +apiVersion: litmuschaos.io/v1alpha1 kind: ChartServiceVersion metadata: - createdAt: 2022-11-17T10:28:08Z name: spring-boot-memory-stress version: 0.1.0 annotations: categories: Spring Boot - vendor: CNCF - support: https://slack.kubernetes.io/ + vendor: LitmusChaos spec: displayName: spring-boot-memory-stress categoryDescription: | - This experiment allows injecting Chaos Monkey memory-stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. + This experiment allows injecting Chaos Monkey memory-stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath. It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress. It tests the resiliency of the system when some applications are having unexpected faulty behavior. keywords: - - Kubernetes - - K8S - Spring Boot - - Pod platforms: - GKE - Konvoy @@ -25,25 +21,13 @@ spec: - Minikube - EKS maturity: alpha - maintainers: - - name: Stephane Cazeaux - email: stephane.cazeaux@orange.com - - name: Shubham Chaudhary - email: shubham.chaudhary@harness.io minKubeVersion: 1.12.0 - provider: - name: Orange labels: app.kubernetes.io/component: chartserviceversion - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci links: - - name: Source Code - url: https://github.com/litmuschaos/litmus-go/tree/master/experiments/spring-boot/spring-boot-memory-stress - name: Documentation - url: https://litmuschaos.github.io/litmus/experiments/categories/spring-boot/spring-boot-memory-stress - - name: Video - url: + url: https://litmuschaos.github.io/litmus/experiments/categories/contents icon: - - url: + - url: mediatype: "" - chaosexpcrdlink: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot-memory-stress/experiment.yaml diff --git a/faults/spring-boot/spring-boot.chartserviceversion.yaml b/faults/spring-boot/spring-boot.chartserviceversion.yaml new file mode 100644 index 0000000..49109e0 --- /dev/null +++ b/faults/spring-boot/spring-boot.chartserviceversion.yaml @@ -0,0 +1,44 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: spring-boot + version: 0.1.0 + annotations: + categories: Spring Boot + chartDescription: Injects spring boot chaos +spec: + displayName: Spring Boot + categoryDescription: > + It contains chaos to disrupt state of spring-boot application. + faults: + - name: spring-boot-app-kill + description: It injects app-kill chaos in a spring-boot application. + displayName: "Spring Boot App Kill" + - name: spring-boot-cpu-stress + description: It injects cpu-stress chaos in a spring-boot application. + displayName: "Spring Boot CPU Stress" + - name: spring-boot-memory-stress + description: It injects memory-stress chaos in a spring-boot application. + displayName: "Spring Boot Memory Stress" + - name: spring-boot-latency + description: It injects network-latency chaos in a spring-boot application. + displayName: "Spring Boot Latency" + - name: spring-boot-exceptions + description: It injects exceptions chaos in a spring-boot application. + displayName: "Spring Boot Exceptions" + - name: spring-boot-faults + description: It injects faults in a spring-boot application. + displayName: "Spring Boot Faults" + keywords: + - Kubernetes + - Spring Boot + - K8S + - Pod + minKubeVersion: 1.12.0 + links: + - name: Documentation + url: https://spring.io/projects/spring-boot + icon: + - url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot/icons/spring-boot.png + mediatype: image/png diff --git a/charts/spring-boot/spring-boot.package.yaml b/faults/spring-boot/spring-boot.package.yaml similarity index 95% rename from charts/spring-boot/spring-boot.package.yaml rename to faults/spring-boot/spring-boot.package.yaml index 0347743..7119887 100644 --- a/charts/spring-boot/spring-boot.package.yaml +++ b/faults/spring-boot/spring-boot.package.yaml @@ -1,3 +1,4 @@ +--- packageName: spring-boot experiments: - name: spring-boot-app-kill @@ -17,4 +18,4 @@ experiments: desc: "spring-boot-exceptions" - name: spring-boot-faults CSV: spring-boot-faults.chartserviceversion.yaml - desc: "spring-boot-faults" \ No newline at end of file + desc: "spring-boot-faults" diff --git a/charts/vmware/icons/vm-poweroff.png b/faults/vmware/icons/vm-poweroff.png similarity index 100% rename from charts/vmware/icons/vm-poweroff.png rename to faults/vmware/icons/vm-poweroff.png diff --git a/charts/vmware/icons/vmware.png b/faults/vmware/icons/vmware.png similarity index 100% rename from charts/vmware/icons/vmware.png rename to faults/vmware/icons/vmware.png diff --git a/experiments/vmware/vm-poweroff/engine.yaml b/faults/vmware/vm-poweroff/engine.yaml similarity index 66% rename from experiments/vmware/vm-poweroff/engine.yaml rename to faults/vmware/vm-poweroff/engine.yaml index a9fa88a..974b97c 100644 --- a/experiments/vmware/vm-poweroff/engine.yaml +++ b/faults/vmware/vm-poweroff/engine.yaml @@ -1,16 +1,14 @@ +--- apiVersion: litmuschaos.io/v1alpha1 kind: ChaosEngine metadata: - name: vmware-vm-chaos + name: vmware-engine namespace: default spec: - # It can be active/stop engineState: 'active' - #ex. values: ns1:name=percona,ns2:run=nginx - auxiliaryAppInfo: '' - chaosServiceAccount: vm-poweroff-sa + chaosServiceAccount: litmus-admin experiments: - - name: vm-poweroff + - name: vmware-vm-poweroff spec: components: env: @@ -22,6 +20,9 @@ spec: - name: CHAOS_INTERVAL value: '30' - # provide VM MOIDs as comma separated values + # provide VM MOIDs as comma separated values - name: APP_VM_MOIDS value: '' + + - name: SEQUENCE + value: 'parallel' diff --git a/charts/generic/pod-delete/experiment.yaml b/faults/vmware/vm-poweroff/fault.yaml similarity index 50% rename from charts/generic/pod-delete/experiment.yaml rename to faults/vmware/vm-poweroff/fault.yaml index c82ab84..5cd52ba 100644 --- a/charts/generic/pod-delete/experiment.yaml +++ b/faults/vmware/vm-poweroff/fault.yaml @@ -1,15 +1,16 @@ +--- apiVersion: litmuschaos.io/v1alpha1 description: message: | - Deletes a pod belonging to a deployment/statefulset/daemonset + It poweroff the VMware instance for a certain chaos duration. kind: ChaosExperiment metadata: - name: pod-delete + name: vmware-vm-poweroff labels: - name: pod-delete + name: vmware-vm-poweroff app.kubernetes.io/part-of: litmus app.kubernetes.io/component: chaosexperiment - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci spec: definition: scope: Namespaced @@ -17,87 +18,102 @@ spec: # Create and monitor the experiment & helper pods - apiGroups: [""] resources: ["pods"] - verbs: ["create","delete","get","list","patch","update", "deletecollection"] + verbs: + [ + "create", + "delete", + "get", + "list", + "patch", + "update", + "deletecollection", + ] # Performs CRUD operations on the events inside chaosengine and chaosresult - apiGroups: [""] resources: ["events"] - verbs: ["create","get","list","patch","update"] + verbs: ["create", "get", "list", "patch", "update"] # Fetch configmaps details and mount it to the experiment pod (if specified) - apiGroups: [""] resources: ["configmaps"] - verbs: ["get","list",] - # Track and get the runner, experiment, and helper pods log + verbs: ["get", "list"] + # Track and get the runner, experiment, and helper pods log - apiGroups: [""] resources: ["pods/log"] - verbs: ["get","list","watch"] - # for creating and managing to execute comands inside target container + verbs: ["get", "list", "watch"] + # for creating and managing to execute commands inside target container - apiGroups: [""] resources: ["pods/exec"] - verbs: ["get","list","create"] + verbs: ["get", "list", "create"] # deriving the parent/owner details of the pod(if parent is anyof {deployment, statefulset, daemonsets}) - apiGroups: ["apps"] - resources: ["deployments","statefulsets","replicasets", "daemonsets"] - verbs: ["list","get"] - # deriving the parent/owner details of the pod(if parent is deploymentConfig) + resources: ["deployments", "statefulsets", "replicasets", "daemonsets"] + verbs: ["list", "get"] + # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: ["apps.openshift.io"] resources: ["deploymentconfigs"] - verbs: ["list","get"] + verbs: ["list", "get"] # deriving the parent/owner details of the pod(if parent is deploymentConfig) - apiGroups: [""] resources: ["replicationcontrollers"] - verbs: ["get","list"] + verbs: ["get", "list"] # deriving the parent/owner details of the pod(if parent is argo-rollouts) - apiGroups: ["argoproj.io"] resources: ["rollouts"] - verbs: ["list","get"] + verbs: ["list", "get"] # for configuring and monitor the experiment job by the chaos-runner pod - apiGroups: ["batch"] resources: ["jobs"] - verbs: ["create","list","get","delete","deletecollection"] + verbs: ["create", "list", "get", "delete", "deletecollection"] # for creation, status polling and deletion of litmus chaos resources used within a chaos workflow - apiGroups: ["litmuschaos.io"] - resources: ["chaosengines","chaosexperiments","chaosresults"] - verbs: ["create","list","get","patch","update","delete"] + resources: ["chaosengines", "chaosexperiments", "chaosresults"] + verbs: ["create", "list", "get", "patch", "update", "delete"] image: "litmuschaos/go-runner:latest" imagePullPolicy: Always args: - - -c - - ./experiments -name pod-delete + - -c + - ./experiments -name vm-poweroff command: - - /bin/bash + - /bin/bash env: + - name: TOTAL_CHAOS_DURATION + value: "30" - - name: TOTAL_CHAOS_DURATION - value: '15' + - name: CHAOS_INTERVAL + value: "10" - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' + - name: RAMP_TIME + value: "" - - name: FORCE - value: 'true' + - name: VCENTERSERVER + valueFrom: + secretKeyRef: + name: vcenter-secret + key: VCENTERSERVER - - name: CHAOS_INTERVAL - value: '5' + - name: VCENTERUSER + valueFrom: + secretKeyRef: + name: vcenter-secret + key: VCENTERUSER - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' + - name: VCENTERPASS + valueFrom: + secretKeyRef: + name: vcenter-secret + key: VCENTERPASS - - name: TARGET_PODS - value: '' + - name: APP_VM_MOIDS + value: "" - # To select pods on specific node(s) - - name: NODE_LABEL - value: '' + - name: SEQUENCE + value: "parallel" + + - name: DEFAULT_HEALTH_CHECK + value: "false" - ## it defines the sequence of chaos execution for multiple target pods - ## supported values: serial, parallel - - name: SEQUENCE - value: 'parallel' - labels: - name: pod-delete + name: vmware-vm-poweroff app.kubernetes.io/part-of: litmus app.kubernetes.io/component: experiment-job - app.kubernetes.io/version: latest + app.kubernetes.io/version: ci diff --git a/faults/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml b/faults/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml new file mode 100644 index 0000000..5fd7567 --- /dev/null +++ b/faults/vmware/vm-poweroff/vm-poweroff.chartserviceversion.yaml @@ -0,0 +1,29 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + createdAt: 2022-07-19T10:28:08Z + name: vmware-vm-poweroff + version: 0.1.0 + annotations: + categories: VMWare + vendor: LitmusChaos +spec: + displayName: VMware VM Power Off + categoryDescription: | + vm-poweroff fault Power-Offs the target VMs for a certain chaos duration and then bring back to Power-On state. + - This fault helps verify the resiliency of the process/application that are running on the target instance. + keywords: + - VMware + platforms: + - VMware + minKubeVersion: 1.12.0 + labels: + app.kubernetes.io/component: chartserviceversion + app.kubernetes.io/version: ci + links: + - name: Documentation + url: https://litmuschaos.github.io/litmus/experiments/categories/contents + icon: + - url: + mediatype: "" diff --git a/faults/vmware/vmware.chartserviceversion.yaml b/faults/vmware/vmware.chartserviceversion.yaml new file mode 100644 index 0000000..ae0c6da --- /dev/null +++ b/faults/vmware/vmware.chartserviceversion.yaml @@ -0,0 +1,33 @@ +--- +apiVersion: litmuschaos.io/v1alpha1 +kind: ChartServiceVersion +metadata: + name: vmware + version: 0.1.0 + annotations: + categories: VMware + chartDescription: Injects faults on VMware system + executionPlane: "kubernetes" +spec: + displayName: VMware + categoryDescription: > + VMware chaos contains different experiments for VMware platform. It uses VMware apis to carry out the fault logic for different components. + faults: + - name: vm-poweroff + description: It injects power-off chaos on VMware VMs. + displayName: "VMware VM Poweroff" + keywords: + - VMware + minKubeVersion: 1.12.0 + links: + - name: Kubernetes Website + url: https://kubernetes.io + - name: Source Code + url: https://github.com/kubernetes/kubernetes + - name: Kubernetes Slack + url: https://slack.kubernetes.io/ + - name: Documentation + url: "https://litmuschaos.github.io/litmus/experiments/categories/contents/#vmware" + icon: + - url: https://raw.githubusercontent.com/litmuschaos/charthub.litmuschaos.io/master/public/litmus.ico + mediatype: image/png diff --git a/charts/vmware/vmware.package.yaml b/faults/vmware/vmware.package.yaml similarity index 89% rename from charts/vmware/vmware.package.yaml rename to faults/vmware/vmware.package.yaml index 3fe0e48..812c39e 100644 --- a/charts/vmware/vmware.package.yaml +++ b/faults/vmware/vmware.package.yaml @@ -1,5 +1,6 @@ +--- packageName: vmware -experiments: +faults: - name: vm-poweroff CSV: vm-poweroff.chartserviceversion.yaml desc: "vm-poweroff" diff --git a/scenarios/icons/pod-delete.png b/scenarios/icons/pod-delete.png deleted file mode 100644 index 16aa7b4..0000000 Binary files a/scenarios/icons/pod-delete.png and /dev/null differ diff --git a/scenarios/icons/pod-memory-hog.png b/scenarios/icons/pod-memory-hog.png deleted file mode 100644 index e49a468..0000000 Binary files a/scenarios/icons/pod-memory-hog.png and /dev/null differ diff --git a/scenarios/pod-delete/pod-delete.chartserviceversion.yaml b/scenarios/pod-delete/pod-delete.chartserviceversion.yaml deleted file mode 100644 index 244bbc7..0000000 --- a/scenarios/pod-delete/pod-delete.chartserviceversion.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-24T10:28:08Z - name: pod-delete - version: 0.1.0 - annotations: - categories: pod-delete - chartDescription: Deletes a k8s pod -spec: - displayName: Pod Delete - categoryDescription: > - Pod delete contains chaos to disrupt state of kubernetes resources. Experiments can inject random pod delete failures against specified application. - experiments: - - name: pod-delete - description: "This experiment injects random pod delete failures against specified application." - keywords: - - Kubernetes - - Podtato-head - - Pod - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maintainers: - - name: oumkale - email: oumkale@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://docs.litmuschaos.io/docs/chaoshub/#generic-chaos - icon: - - url: - mediatype: "" diff --git a/scenarios/pod-delete/workflow.yaml b/scenarios/pod-delete/workflow.yaml deleted file mode 100644 index 5d23cfc..0000000 --- a/scenarios/pod-delete/workflow.yaml +++ /dev/null @@ -1,157 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Workflow -metadata: - generateName: argowf-chaos-pod-delete- - namespace: litmus - labels: - subject: "{{workflow.parameters.appNamespace}}_kube-proxy" -spec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - - name: appNamespace - value: "kube-system" - templates: - - name: argowf-chaos - steps: - - - name: install-experiment - template: install-experiment - - - name: run-chaos - template: run-chaos - - - name: revert-chaos - template: revert-chaos - - - name: install-experiment - inputs: - artifacts: - - name: install-experiment - path: /tmp/pod-delete.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset - kind: ChaosExperiment - metadata: - name: pod-delete - spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-delete - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - labels: - name: pod-delete - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl apply -f /tmp/pod-delete.yaml -n {{workflow.parameters.adminModeNamespace}}", - ] - - - name: run-chaos - inputs: - artifacts: - - name: run-chaos - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: kube-proxy-pod-delete-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.appNamespace}}_kube-proxy" - spec: - appinfo: - appns: kube-system - applabel: "k8s-app=kube-proxy" - appkind: daemonset - jobCleanUpPolicy: retain - engineState: 'active' - chaosServiceAccount: litmus-admin - experiments: - - name: pod-delete - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: "60" - - name: CHAOS_INTERVAL - value: "10" - - name: FORCE - value: "false" - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine kube-proxy-pod-delete-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] diff --git a/scenarios/pod-delete/workflow_cron.yaml b/scenarios/pod-delete/workflow_cron.yaml deleted file mode 100644 index 8da977c..0000000 --- a/scenarios/pod-delete/workflow_cron.yaml +++ /dev/null @@ -1,161 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: CronWorkflow -metadata: - name: argo-chaos-pod-delete-cron-wf - namespace: litmus - labels: - subject: "{{workflow.parameters.appNamespace}}_kube-proxy" -spec: - schedule: "0 * * * *" - concurrencyPolicy: "Forbid" - startingDeadlineSeconds: 0 - workflowSpec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - - name: appNamespace - value: "kube-system" - templates: - - name: argowf-chaos - steps: - - - name: install-experiment - template: install-experiment - - - name: run-chaos - template: run-chaos - - - name: revert-chaos - template: revert-chaos - - - name: install-experiment - inputs: - artifacts: - - name: install-experiment - path: /tmp/pod-delete.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - description: - message: | - Deletes a pod belonging to a deployment/statefulset/daemonset - kind: ChaosExperiment - metadata: - name: pod-delete - spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "apps" - - "batch" - - "litmuschaos.io" - resources: - - "deployments" - - "jobs" - - "pods" - - "pods/log" - - "events" - - "configmaps" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - - apiGroups: - - "" - resources: - - "nodes" - verbs: - - "get" - - "list" - image: "litmuschaos/go-runner:latest" - imagePullPolicy: Always - args: - - -c - - ./experiments -name pod-delete - command: - - /bin/bash - env: - - - name: TOTAL_CHAOS_DURATION - value: '15' - - # Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - # provide the kill count - - name: KILL_COUNT - value: '' - - - name: FORCE - value: 'true' - - - name: CHAOS_INTERVAL - value: '5' - - labels: - name: pod-delete - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl apply -f /tmp/pod-delete.yaml -n {{workflow.parameters.adminModeNamespace}}", - ] - - - name: run-chaos - inputs: - artifacts: - - name: run-chaos - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: kube-proxy-pod-delete-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.appNamespace}}_kube-proxy" - spec: - appinfo: - appns: kube-system - applabel: "k8s-app=kube-proxy" - appkind: daemonset - jobCleanUpPolicy: retain - engineState: 'active' - chaosServiceAccount: litmus-admin - experiments: - - name: pod-delete - spec: - components: - env: - - name: TOTAL_CHAOS_DURATION - value: "60" - - name: CHAOS_INTERVAL - value: "10" - - name: FORCE - value: "false" - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine kube-proxy-pod-delete-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] diff --git a/scenarios/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml b/scenarios/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml deleted file mode 100644 index fc67c5f..0000000 --- a/scenarios/pod-memory-hog/pod-memory-hog.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-24T10:28:08Z - name: pod-memory-hog - version: 0.1.0 - annotations: - categories: pod-memory-hog - chartDescription: Injects memory chaos on a k8s pod -spec: - displayName: Pod Memory Hog - categoryDescription: > - Pod-Memory-Hog contains chaos to consume memory resouces of specified containers in Kubernetes pods - and revert the chaos - experiments: - - name: pod-memory-hog - description: "Injects memory chaos on a k8s pod" - keywords: - - Kubernetes - - Podtato-head - - Pod - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maintainers: - - name: oumkale - email: oumkale@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://docs.litmuschaos.io/docs/chaoshub/#generic-chaos - icon: - - url: - mediatype: "" diff --git a/scenarios/pod-memory-hog/workflow_cron.yaml b/scenarios/pod-memory-hog/workflow_cron.yaml deleted file mode 100644 index c565503..0000000 --- a/scenarios/pod-memory-hog/workflow_cron.yaml +++ /dev/null @@ -1,158 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: CronWorkflow -metadata: - name: argo-chaos-pod-memory-cron-wf - namespace: litmus - labels: - subject: "{{workflow.parameters.appNamespace}}_kube-proxy" -spec: - schedule: "0 * * * *" - concurrencyPolicy: "Forbid" - startingDeadlineSeconds: 0 - workflowSpec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - - name: appNamespace - value: "kube-system" - templates: - - name: argowf-chaos - steps: - - - name: install-experiment - template: install-experiment - - - name: run-chaos - template: run-chaos - - - name: revert-chaos - template: revert-chaos - - - name: install-experiment - inputs: - artifacts: - - name: install-experiment - path: /tmp/pod-memory-hog.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - description: - message: | - Injects memory consumption on pods belonging to an app deployment - kind: ChaosExperiment - metadata: - name: pod-memory-hog - spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "batch" - - "litmuschaos.io" - resources: - - "jobs" - - "pods" - - "pods/log" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-memory-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '10' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: TARGET_POD - value: '' - - labels: - name: pod-memory-hog - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl apply -f /tmp/pod-memory-hog.yaml -n {{workflow.parameters.adminModeNamespace}}", - ] - - - name: run-chaos - inputs: - artifacts: - - name: run-chaos - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: kube-proxy-pod-memory-hog-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.appNamespace}}_kube-proxy" - spec: - appinfo: - appns: kube-system - applabel: "k8s-app=kube-proxy" - appkind: daemonset - jobCleanUpPolicy: retain - engineState: 'active' - chaosServiceAccount: litmus-admin - experiments: - - name: pod-memory-hog - spec: - components: - env: - - name: TARGET_CONTAINER - value: 'kube-proxy' - - - name: MEMORY_CONSUMPTION - value: '500' - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: CHAOS_KILL_COMMAND - value: "kill -9 $(ps afx | grep \"[dd] if /dev/zero\" | awk '{print $1}' | tr '\n' ' ')" - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine kube-proxy-pod-memory-hog-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] diff --git a/scenarios/podtato-head/podtato-head.chartserviceversion.yaml b/scenarios/podtato-head/podtato-head.chartserviceversion.yaml deleted file mode 100644 index bc4c726..0000000 --- a/scenarios/podtato-head/podtato-head.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-24T10:28:08Z - name: podtato-head - version: 0.1.0 - annotations: - categories: podtato-head - chartDescription: Injects chaos on podtato-head application -spec: - displayName: Podtato-head Chaos - categoryDescription: > - It install podtato-head application, inject chaos on podtato-head, uninstall the application - and revert the chaos - experiments: - - name: pod-delete - description: "Deletes a k8s pod" - keywords: - - Kubernetes - - Podtato-head - - Pod - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maintainers: - - name: oumkale - email: oumkale@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://docs.litmuschaos.io/docs/chaoshub/#generic-chaos - icon: - - url: - mediatype: "" diff --git a/scenarios/podtato-head/workflow_cron.yaml b/scenarios/podtato-head/workflow_cron.yaml deleted file mode 100644 index 099a050..0000000 --- a/scenarios/podtato-head/workflow_cron.yaml +++ /dev/null @@ -1,118 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: CronWorkflow -metadata: - name: argowf-podtato-head-chaos-cron-wf - namespace: litmus - labels: - subject : "{{workflow.parameters.adminModeNamespace}}_podtato-head" -spec: - schedule: "0 * * * *" - concurrencyPolicy: "Forbid" - startingDeadlineSeconds: 0 - workflowSpec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - templates: - - name: argowf-chaos - steps: - - - name: install-application - template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments - - - name: pod-delete - template: pod-delete - - - name: revert-chaos - template: revert-chaos - - name: delete-application - template: delete-application - - - name: install-application - container: - image: litmuschaos/litmus-app-deployer:latest - args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=apply","-timeout=400", "-app=podtato-head","-scope=namespace"] - - - name: install-chaos-experiments - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - - "kubectl apply -f https://hub.litmuschaos.io/api/chaos/master?file=charts/generic/experiments.yaml -n - {{workflow.parameters.adminModeNamespace}} ; sleep 30" - - - name: pod-delete - inputs: - artifacts: - - name: pod-delete - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: podtato-main-pod-delete-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.adminModeNamespace}}_podtato-main" - spec: - appinfo: - appns: {{workflow.parameters.adminModeNamespace}} - applabel: 'name=podtato-main' - appkind: 'deployment' - engineState: 'active' - chaosServiceAccount: litmus-admin - jobCleanUpPolicy: 'retain' - components: - runner: - imagePullPolicy: Always - experiments: - - name: pod-delete - spec: - probe: - - name: "check-podtato-main-access-url" - type: "httpProbe" - httpProbe/inputs: - url: "http://podtato-main.{{workflow.parameters.adminModeNamespace}}.svc.cluster.local:9000" - insecureSkipVerify: false - method: - get: - criteria: "==" - responseCode: "200" - mode: "Continuous" - runProperties: - probeTimeout: 1s - interval: 100ms - attempt: 1 - components: - env: - - 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' - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: delete-application - container: - image: litmuschaos/litmus-app-deployer:latest - args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=delete","-app=podtato-head"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine podtato-main-pod-delete-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] \ No newline at end of file diff --git a/scripts/combine-all-crs.go b/scripts/combine-all-crs.go index 9df0b2b..202812a 100644 --- a/scripts/combine-all-crs.go +++ b/scripts/combine-all-crs.go @@ -16,7 +16,7 @@ import ( func main() { - directories, err := GetAllSubDirectories("./../charts") + directories, err := GetAllSubDirectories("./../faults") if err != nil { log.Fatalf("unable to get chart categories details, err: %v", err) } @@ -41,21 +41,21 @@ func main() { // get the list of all sub-directories subDirectories, err := GetAllSubDirectories(directory) if err != nil { - log.Fatalf("unable to get experiment details, err: %v", err) + log.Fatalf("unable to get fault details, err: %v", err) } for _, subdirectory := range subDirectories { - isFileExist := IsFileExist(subdirectory + "/experiment.yaml") + isFileExist := IsFileExist(subdirectory + "/fault.yaml") if isFileExist { - CRName, err := GetCRName(subdirectory + "/experiment.yaml") + CRName, err := GetCRName(subdirectory + "/fault.yaml") if err != nil || CRName == "" { - log.Fatalf("unable to extract the CR name for %v file, err: %v", subdirectory+"/experiment.yaml", err) + log.Fatalf("unable to extract the CR name for %v file, err: %v", subdirectory+"/fault.yaml", err) } if !Contains(CRName, CRNames) { - if err := CopyData(filePath, subdirectory+"/experiment.yaml"); err != nil { - log.Fatalf("unable to copy data for %v experiment, err: %v", subdirectory, err) + if err := CopyData(filePath, subdirectory+"/fault.yaml"); err != nil { + log.Fatalf("unable to copy data for %v fault, err: %v", subdirectory, err) } CRNames = append(CRNames, CRName) } diff --git a/service-accounts/argowf-chaos-admin.yaml b/service-accounts/argowf-chaos-admin.yaml index 92cb131..140ec20 100644 --- a/service-accounts/argowf-chaos-admin.yaml +++ b/service-accounts/argowf-chaos-admin.yaml @@ -1,7 +1,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: - generateName: argowf-chaos- + name: argowf-chaos- spec: entrypoint: argowf-chaos serviceAccountName: argo-chaos @@ -22,8 +22,8 @@ spec: template: run-chaos - name: run-benchmark template: run-benchmark - - - name: revert-chaos - template: revert-chaos + - - name: cleanup-chaos-resources + template: cleanup-chaos-resources - name: run-chaos inputs: @@ -105,7 +105,7 @@ spec: command: [sh, -c] args: ['kubectl apply -f /tmp/bench.yaml -n {{workflow.parameters.appNamespace}}'] - - name: revert-chaos + - name: cleanup-chaos-resources container: image: alpine/k8s:1.18.2 command: [sh, -c] diff --git a/workflows/icons/bank-of-anthos.png b/workflows/icons/bank-of-anthos.png deleted file mode 100644 index ba9028d..0000000 Binary files a/workflows/icons/bank-of-anthos.png and /dev/null differ diff --git a/workflows/icons/podtato-head.png b/workflows/icons/podtato-head.png deleted file mode 100644 index 59e9f28..0000000 Binary files a/workflows/icons/podtato-head.png and /dev/null differ diff --git a/workflows/icons/sock-shop-promProbe.png b/workflows/icons/sock-shop-promProbe.png deleted file mode 100644 index 00b4a19..0000000 Binary files a/workflows/icons/sock-shop-promProbe.png and /dev/null differ diff --git a/workflows/icons/sock-shop.png b/workflows/icons/sock-shop.png deleted file mode 100644 index 00b4a19..0000000 Binary files a/workflows/icons/sock-shop.png and /dev/null differ diff --git a/workflows/pod-memory-hog/workflow.yaml b/workflows/pod-memory-hog/workflow.yaml deleted file mode 100644 index c429b58..0000000 --- a/workflows/pod-memory-hog/workflow.yaml +++ /dev/null @@ -1,154 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Workflow -metadata: - generateName: argowf-chaos-pod-memory-hog- - namespace: litmus - labels: - subject: "{{workflow.parameters.appNamespace}}_kube-proxy" -spec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - - name: appNamespace - value: "kube-system" - templates: - - name: argowf-chaos - steps: - - - name: install-experiment - template: install-experiment - - - name: run-chaos - template: run-chaos - - - name: revert-chaos - template: revert-chaos - - - name: install-experiment - inputs: - artifacts: - - name: install-experiment - path: /tmp/pod-memory-hog.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - description: - message: | - Injects memory consumption on pods belonging to an app deployment - kind: ChaosExperiment - metadata: - name: pod-memory-hog - spec: - definition: - scope: Namespaced - permissions: - - apiGroups: - - "" - - "batch" - - "litmuschaos.io" - resources: - - "jobs" - - "pods" - - "pods/log" - - "events" - - "chaosengines" - - "chaosexperiments" - - "chaosresults" - verbs: - - "create" - - "list" - - "get" - - "patch" - - "update" - - "delete" - image: "litmuschaos/go-runner:latest" - args: - - -c - - ./experiments -name pod-memory-hog - command: - - /bin/bash - env: - - name: TOTAL_CHAOS_DURATION - value: '30' - - - name: CHAOS_INTERVAL - value: '10' - - ## enter the amount of memory in megabytes to be consumed by the application pod - - name: MEMORY_CONSUMPTION - value: '500' - - ## percentage of total pods to target - - name: PODS_AFFECTED_PERC - value: '' - - ## Period to wait before and after injection of chaos in sec - - name: RAMP_TIME - value: '' - - - name: TARGET_POD - value: '' - - labels: - name: pod-memory-hog - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl apply -f /tmp/pod-memory-hog.yaml -n {{workflow.parameters.adminModeNamespace}}", - ] - - - name: run-chaos - inputs: - artifacts: - - name: run-chaos - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: kube-proxy-pod-memory-hog-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.appNamespace}}_kube-proxy" - spec: - appinfo: - appns: kube-system - applabel: "k8s-app=kube-proxy" - appkind: daemonset - jobCleanUpPolicy: retain - engineState: 'active' - chaosServiceAccount: litmus-admin - experiments: - - name: pod-memory-hog - spec: - components: - env: - - name: TARGET_CONTAINER - value: 'kube-proxy' - - - name: MEMORY_CONSUMPTION - value: '500' - - - name: TOTAL_CHAOS_DURATION - value: '60' # in seconds - - - name: CHAOS_KILL_COMMAND - value: "kill -9 $(ps afx | grep \"[dd] if /dev/zero\" | awk '{print $1}' | tr '\n' ' ')" - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine kube-proxy-pod-memory-hog-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] diff --git a/workflows/podtato-head/podtato-head.chartserviceversion.yaml b/workflows/podtato-head/podtato-head.chartserviceversion.yaml deleted file mode 100644 index f413d4e..0000000 --- a/workflows/podtato-head/podtato-head.chartserviceversion.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: litmuchaos.io/v1alpha1 -kind: ChartServiceVersion -metadata: - createdAt: 2021-05-24T10:28:08Z - name: podtato-head - version: 0.1.0 - annotations: - categories: podtato-head - chartDescription: Injects chaos on podtato-head application -spec: - displayName: Podtato-head Chaos - categoryDescription: > - It install podtato-head application, inject chaos on podtato-head, uninstall the application - and revert the chaos - experiments: - - pod-delete - keywords: - - Kubernetes - - Podtato-head - - Pod - platforms: - - GKE - - Minikube - - Packet(Kubeadm) - - EKS - - AKS - maintainers: - - name: oumkale - email: oumkale@chaosnative.com - provider: - name: ChaosNative - links: - - name: Kubernetes Slack - url: https://slack.kubernetes.io/ - - name: Documentation - url: https://docs.litmuschaos.io/docs/chaoshub/#generic-chaos - icon: - - url: - mediatype: "" - \ No newline at end of file diff --git a/workflows/podtato-head/workflow.yaml b/workflows/podtato-head/workflow.yaml deleted file mode 100644 index b8165d4..0000000 --- a/workflows/podtato-head/workflow.yaml +++ /dev/null @@ -1,114 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Workflow -metadata: - generateName: argowf-podtato-head-chaos- - namespace: litmus - labels: - subject : "{{workflow.parameters.adminModeNamespace}}_podtato-main" -spec: - entrypoint: argowf-chaos - serviceAccountName: argo-chaos - securityContext: - runAsUser: 1000 - runAsNonRoot: true - arguments: - parameters: - - name: adminModeNamespace - value: "litmus" - templates: - - name: argowf-chaos - steps: - - - name: install-application - template: install-application - - - name: install-chaos-experiments - template: install-chaos-experiments - - - name: pod-delete - template: pod-delete - - - name: revert-chaos - template: revert-chaos - - name: delete-application - template: delete-application - - - name: install-application - container: - image: litmuschaos/litmus-app-deployer:latest - args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=apply","-timeout=400", "-app=podtato-head","-scope=namespace"] - - - name: install-chaos-experiments - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - - "kubectl apply -f https://hub.litmuschaos.io/api/chaos/master?file=charts/generic/experiments.yaml -n - {{workflow.parameters.adminModeNamespace}} ; sleep 30" - - - name: pod-delete - inputs: - artifacts: - - name: pod-delete - path: /tmp/chaosengine.yaml - raw: - data: | - apiVersion: litmuschaos.io/v1alpha1 - kind: ChaosEngine - metadata: - name: podtato-main-pod-delete-chaos - namespace: {{workflow.parameters.adminModeNamespace}} - labels: - context: "{{workflow.parameters.adminModeNamespace}}_podtato-main" - spec: - appinfo: - appns: {{workflow.parameters.adminModeNamespace}} - applabel: 'name=podtato-main' - appkind: 'deployment' - engineState: 'active' - chaosServiceAccount: litmus-admin - jobCleanUpPolicy: 'retain' - components: - runner: - imagePullPolicy: Always - experiments: - - name: pod-delete - spec: - probe: - - name: "check-podtato-main-access-url" - type: "httpProbe" - httpProbe/inputs: - url: "http://podtato-main.{{workflow.parameters.adminModeNamespace}}.svc.cluster.local:9000" - insecureSkipVerify: false - method: - get: - criteria: "==" - responseCode: "200" - mode: "Continuous" - runProperties: - probeTimeout: 1s - interval: 100ms - attempt: 1 - components: - env: - - 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' - container: - image: litmuschaos/litmus-checker:latest - args: ["-file=/tmp/chaosengine.yaml","-saveName=/tmp/engine-name"] - - - name: delete-application - container: - image: litmuschaos/litmus-app-deployer:latest - args: ["-namespace={{workflow.parameters.adminModeNamespace}}","-typeName=resilient","-operation=delete","-app=podtato-head"] - - - name: revert-chaos - container: - image: litmuschaos/k8s:latest - command: [sh, -c] - args: - [ - "kubectl delete chaosengine podtato-main-pod-delete-chaos -n {{workflow.parameters.adminModeNamespace}}", - ] \ No newline at end of file