Adds ability to configure frequency for pod termination via annotation#353
Open
multimac wants to merge 7 commits intolinki:masterfrom
Open
Adds ability to configure frequency for pod termination via annotation#353multimac wants to merge 7 commits intolinki:masterfrom
multimac wants to merge 7 commits intolinki:masterfrom
Conversation
caae9b1 to
ac9a4e7
Compare
Author
|
Just updated with the ability to set a default termination frequency, via the This applies to pods which lack the annotation and helps avoid them from being terminated too frequently, since it's likely that people will decrease the interval at which Chaoskube runs when using the annotation. |
Author
|
This PR has ballooned slightly. I've added the ability to configure per-pod (via annotations):
All of these use annotations in the form |
f45361e to
09d46aa
Compare
09d46aa to
6b7de05
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds ability to configure frequency for pod termination via annotation.
Closes #20
Allows specifying a new command line flag,
--termination-frequency-annotationwhich sets the annotation to look for and use to calculate the approximate frequency at which to terminate a given pod. Follows the examples given in #20, such as...chaos.alpha.kubernetes.io/frequency=2/dayfor "kill this twice per day"chaos.alpha.kubernetes.io/frequency=10/hourfor "kill this ten times per hour"chaos.alpha.kubernetes.io/frequency=1/weekfor "kill this once a week"chaos.alpha.kubernetes.io/frequency=0.5/dayfor "kill this pod once every two days"Pods without the annotation are assumed to always be candidates for termination. The
--max-killflag also still applies and will potentially limit how frequently a pod is terminated if it isn't high enough.