-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
feat(appset): Policies create-only, create-update, sync per ApplicationSet #11462
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #11462 +/- ##
==========================================
+ Coverage 49.56% 49.58% +0.01%
==========================================
Files 256 256
Lines 43920 43913 -7
==========================================
+ Hits 21770 21774 +4
+ Misses 19987 19976 -11
Partials 2163 2163
☔ View full report in Codecov by Sentry. |
c0b6cae
to
25f34d3
Compare
If an Argo CD operator uses the sync policy as part of their security model, this could be a breaking change. For example, if the admin enforces a controller-level create-only rule, this would allow the user to escalate their privileges to create/update/delete. Could we add an addendum to the admin-defined policy to enable user-specified policies? For example That would allow us to 1) make this feature opt-in and 2) still specify a default. |
25f34d3
to
169750b
Compare
@crenshaw-dev could you please help me on this ? I am not sure to understand what should I do. |
5114f44
to
d38af94
Compare
@speedfl you're asking for clarification in reference to my suggested change in policy override behavior? Or is your question regarding something else? |
@crenshaw-dev sorry it was not really clear. |
@speedfl ah cool. So, right now we're pulling a global sync policy which is stored on I think wherever we're setting Then we could do a check like |
8361c19
to
b5f2fe3
Compare
@crenshaw-dev I added the Added as well unit tests. |
@speedfl can you rebase? |
docs/operator-manual/applicationset/Controlling-Resource-Modification.md
Show resolved
Hide resolved
7430984
to
ff53e79
Compare
@crenshaw-dev I see that |
@speedfl fails on master locally or in CI? Could be an environment issue. |
@crenshaw-dev this morning everything worked. The CI was green. |
Signed-off-by: Geoffrey Muselli <[email protected]>
eae49e3
to
f28a144
Compare
Signed-off-by: Geoffrey Muselli <[email protected]>
@ishitasequeira all done :) |
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.
LGTM!! Just added a quick documentation change that I missed out earlier.
@crenshaw-dev could you take another look at the PR?
docs/operator-manual/applicationset/Controlling-Resource-Modification.md
Show resolved
Hide resolved
Signed-off-by: Geoffrey Muselli <[email protected]>
Signed-off-by: gmuselli <[email protected]>
Signed-off-by: gmuselli <[email protected]>
Signed-off-by: gmuselli <[email protected]>
@ishitasequeira and @crenshaw-dev I fix the unit tests after label |
Signed-off-by: gmuselli <[email protected]>
Signed-off-by: gmuselli <[email protected]>
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.
lfg, thanks as always @speedfl!
…onSet (argoproj#11462) * 11073: SyncPolicy per applicationset Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix Lint 2 Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Fix after review Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Empty Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix after review Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix doc Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix doc Signed-off-by: gmuselli <[email protected]> * 11073: Use enable policy override Signed-off-by: gmuselli <[email protected]> * 11073: Fix unit test label Signed-off-by: gmuselli <[email protected]> * 11073: Update documentation Signed-off-by: gmuselli <[email protected]> * 11073: Update e2e Signed-off-by: gmuselli <[email protected]> --------- Signed-off-by: Geoffrey Muselli <[email protected]> Signed-off-by: gmuselli <[email protected]>
…onSet (argoproj#11462) * 11073: SyncPolicy per applicationset Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix Lint 2 Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Empty Signed-off-by: gmuselli <[email protected]> * 11073: Fix after review Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Empty Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix after review Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix doc Signed-off-by: Geoffrey Muselli <[email protected]> * 11073: Fix doc Signed-off-by: gmuselli <[email protected]> * 11073: Use enable policy override Signed-off-by: gmuselli <[email protected]> * 11073: Fix unit test label Signed-off-by: gmuselli <[email protected]> * 11073: Update documentation Signed-off-by: gmuselli <[email protected]> * 11073: Update e2e Signed-off-by: gmuselli <[email protected]> --------- Signed-off-by: Geoffrey Muselli <[email protected]> Signed-off-by: gmuselli <[email protected]>
Currently
create-only
,create-update
,sync
policies are only part of the controller launch parameters which does not allow to selectively disable deletion/updates.Motivations
Provide a way to temporarily to deactivate the Applications update (ie: Disable AutoSync on one of the generated Applications) without impacting all projects/teams
Provide a way to deactivate Applications deletion on a set of ApplicationSet and enable it on other without several instances of the ApplicationSet controller
Signed-off-by: gmuselli [email protected]
Closes #11073
Note on DCO:
If the DCO action in the integration test fails, one or more of your commits are not signed off. Please click on the Details link next to the DCO action for instructions on how to resolve this.
Note: I am not able to remove the kubebuilder annotations: go-swagger/go-swagger#2687
Checklist: