Commit 76bdbc2
committed
Fix issue where IPBlock and NamespaceSelector are mutually exclusive
On upgrade, the IPBlock was already set and then after upgrade it enters
the conditional where it tries to add the NamespaceSelector. So, in that
case both are set. Instead, when we set one, we should unset the other
to ensure they aren't both set.
This fixes the error:
NetworkPolicy.networking.k8s.io "miq-application-allow-inbound-httpd" is
invalid: spec.ingress[0].from[0]: Forbidden: may not specify both ipBlock
and another peer
CP4AIOPS-220121 parent 5648ec4 commit 76bdbc2
File tree
1 file changed
+4
-1
lines changed- manageiq-operator/api/v1alpha1/helpers/miq-components
1 file changed
+4
-1
lines changedLines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
56 | 57 | | |
57 | 58 | | |
58 | 59 | | |
59 | | - | |
| 60 | + | |
| 61 | + | |
60 | 62 | | |
61 | 63 | | |
62 | 64 | | |
63 | 65 | | |
64 | 66 | | |
65 | 67 | | |
| 68 | + | |
66 | 69 | | |
67 | 70 | | |
68 | 71 | | |
| |||
0 commit comments