open-feature / open-feature-operator

A Kubernetes feature flag operator
https://openfeature.dev
Apache License 2.0
164 stars 33 forks source link

fix: handle multiple imagePullSecrets #666

Closed toddbaert closed 4 weeks ago

toddbaert commented 4 weeks ago

The previous iteration of this was ALMOST working, but:

I've added a sort of hacky "post-processor" script which allows us to add helm control flow where we otherwise couldn't. After talking with @thisthat I think this is the only solution until kustomize supports helm output.

Again, I tested locally, and ImagePullSecrets (even more than one) are added to both the manager deployment and the deployments we create at runtime.

Fixes: https://github.com/open-feature/open-feature-operator/issues/665

codecov[bot] commented 4 weeks ago

Codecov Report

Attention: Patch coverage is 50.00000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 86.51%. Comparing base (546635e) to head (724fad4). Report is 13 commits behind head on main.

:exclamation: Current head 724fad4 differs from pull request most recent head b84c1a7

Please upload reports for the commit b84c1a7 to get more accurate results.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #666 +/- ## ========================================== - Coverage 86.81% 86.51% -0.30% ========================================== Files 19 19 Lines 1577 1587 +10 ========================================== + Hits 1369 1373 +4 - Misses 168 173 +5 - Partials 40 41 +1 ``` | [Files](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature) | Coverage Δ | | |---|---|---| | [common/flagdproxy/flagdproxy.go](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666?src=pr&el=tree&filepath=common%2Fflagdproxy%2Fflagdproxy.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature#diff-Y29tbW9uL2ZsYWdkcHJveHkvZmxhZ2Rwcm94eS5nbw==) | `88.70% <100.00%> (+0.53%)` | :arrow_up: | | [controllers/core/flagd/config.go](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666?src=pr&el=tree&filepath=controllers%2Fcore%2Fflagd%2Fconfig.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature#diff-Y29udHJvbGxlcnMvY29yZS9mbGFnZC9jb25maWcuZ28=) | `0.00% <0.00%> (ø)` | | | [controllers/core/flagd/resources/deployment.go](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666?src=pr&el=tree&filepath=controllers%2Fcore%2Fflagd%2Fresources%2Fdeployment.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature#diff-Y29udHJvbGxlcnMvY29yZS9mbGFnZC9yZXNvdXJjZXMvZGVwbG95bWVudC5nbw==) | `94.56% <0.00%> (-5.44%)` | :arrow_down: | ... and [2 files with indirect coverage changes](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature) | [Flag](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature) | Coverage Δ | | |---|---|---| | [unit-tests](https://app.codecov.io/gh/open-feature/open-feature-operator/pull/666/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature) | `86.51% <50.00%> (-0.30%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=open-feature#carryforward-flags-in-the-pull-request-comment) to find out more.