chaosmonkey.attacks package¶
Submodules¶
chaosmonkey.attacks.attack module¶
-
class
chaosmonkey.attacks.attack.
Attack
(attack_config)[source]¶ Bases:
object
Base class for attacks. Every attack must extend from this class
-
example
= None¶ dict example for using when calling add plan endpoint
-
ref
= None¶ string Unique identifier for the attack. Must be module_name.AttackClass
-
run
()[source]¶ This method is called by an executor to perform the actual attack. You can access the self.attack_config that holds the configuration used when calling the endpoint to plan the attacks.
-
schema
= None¶ dict Valid jsonSchema to validate the attack attributes in the API
-
chaosmonkey.attacks.executor module¶
-
chaosmonkey.attacks.executor.
execute
(attack_config=None, plan_id=None)[source]¶ This func is executed for every job stored in the scheduler. Receive in kwargs all attack configuration used when creating the executor that indicates which attack and configuration should be used to do the actual attack.
Parameters: - attack_config – Dict with attack configuration
- plan_id – String plan id for the plan containing the executor