5GSEC / nimbus

Intent driven security automation framework
Apache License 2.0
19 stars 9 forks source link

(feat): added status based policy creation logic #212

Closed VedRatan closed 5 days ago

VedRatan commented 1 week ago

Description

- In this feature we watch for the status of Kyveno policy to be in ready phase, only then we'll create a trigger for the existing resources to apply the mutation via Kyverno mutation policy. - Couple of bug fixes are also included in this PR. - The status logic is being written referring [kyverno code-desc](https://github.com/kyverno/kyverno/blob/8890fffafb983665b54630333eda8a0e437bfaaa/api/kyverno/v1/policy_status.go#L15) Fixes #207 **Does this PR introduce a breaking change?** ## Checklist - [x] PR title follows the `: ` convention - [ ] I use [conventional commits](https://www.conventionalcommits.org/) in my commit messages - [ ] I have updated the [documentation](../docs) accordingly - [ ] I Keep It Small and Simple: The smaller the PR is, the easier it is to review and have it merged - [x] I have performed a self-review of my code - [x] I have added tests that prove my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes ## Additional information for reviewer #### Mention if this PR is part of any design or a continuation of previous PRs