-
Notifications
You must be signed in to change notification settings - Fork 154
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement resource pruning in k8s plugin #5455
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #5455 +/- ##
==========================================
+ Coverage 26.15% 26.16% +0.01%
==========================================
Files 456 457 +1
Lines 48992 49285 +293
==========================================
+ Hits 12814 12896 +82
- Misses 35156 35363 +207
- Partials 1022 1026 +4 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
// Set the namespace for all manifests. | ||
manifests[i].body.SetNamespace(input.Namespace) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need this to ensure the loaded manifests' namespaces are matched with applied resource.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, we have to check the input.Namespace
is empty or not.
// Add builtin labels and annotations for tracking application live state. | ||
manifests[i].AddLabels(map[string]string{ | ||
LabelManagedBy: ManagedByPiped, | ||
LabelPiped: input.PipedID, | ||
LabelApplication: input.AppID, | ||
LabelCommitHash: input.CommitHash, | ||
}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I want these labels to retrieve live resources when pruning the resources.
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
What this PR does:
as title
Why we need it:
to prune the resources which removed in the git repository
Which issue(s) this PR fixes:
Part of #4980
Does this PR introduce a user-facing change?: No