Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Helm: fix egress-dicovery netpols (grafana#11838)
**What this PR does / why we need it**: This PR fix an issue happening when deploying the `egress-discovery` networkPolicy or ciliumNetworkPolicy. When one wants to deploy the `egress-discovery` netpol, one only has to specify the `networkPolicy.discovery.port` field in the values. However, with the current state of the templates, when this field is specified, **both** the networkPolicy and the ciliumNetworkPolicy are generated since the only condition for their creation is `if .Values.networkPolicy.discovery.port`. I thus added an additional condition : `eq .Values.networkPolicy.flavor "cilium"` (or `"kubernetes"` for the networkPolicy) so that only one of these is generated according to the `flavor` specified in the values. **Special notes for your reviewer**: **Checklist** - [x] Reviewed the [`CONTRIBUTING.md`](https://github.com/grafana/loki/blob/main/CONTRIBUTING.md) guide (**required**) - [ ] Documentation added - [ ] Tests updated - [x] `CHANGELOG.md` updated - [ ] If the change is worth mentioning in the release notes, add `add-to-release-notes` label - [ ] Changes that require user attention or interaction to upgrade are documented in `docs/sources/setup/upgrade/_index.md` - [x] For Helm chart changes bump the Helm chart version in `production/helm/loki/Chart.yaml` and update `production/helm/loki/CHANGELOG.md` and `production/helm/loki/README.md`. [Example PR](grafana@d10549e) - [ ] If the change is deprecating or removing a configuration option, update the `deprecated-config.yaml` and `deleted-config.yaml` files respectively in the `tools/deprecated-config-checker` directory. [Example PR](grafana@0d4416a) --------- Signed-off-by: QuantumEnigmaa <[email protected]> Co-authored-by: Michel Hollands <[email protected]>
- Loading branch information