-
Notifications
You must be signed in to change notification settings - Fork 20
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: general mechanism to allow a container (or init-container) environment to overridden from the OperatorOverride #742
feat: general mechanism to allow a container (or init-container) environment to overridden from the OperatorOverride #742
Conversation
I think this change would be a prime candidate to use |
I like that idea. I think in the cm it would look like:
but I don't immediately see how we'd persuade Jackson to manufacture EnvVar objects rather (than Map). What am I missing? We could just spin off a separate |
Use something like Serialization.jsonMapper().convertValue(map, EnvVar[].class) with the map from the env field. |
+1 |
@shawkins @MikeEdgar how does this look? I needed to make a decision about whether the override feature should apply to any environment variable, even those that probably shouldn't be overridden. I thought about separating a container's env var into a set of those which are reasonable to override and those which are not ( I think we should apply the same pattern to the other containers, but what to give you chance to comment first. |
…den from OperatorOverride
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.
This looks good. Just one comment which supports what you said about making this more generally usable for any of the operands.
operator/src/main/java/org/bf2/operator/managers/OperandOverrideManager.java
Show resolved
Hide resolved
operator/src/main/java/org/bf2/operator/managers/OperandOverrideManager.java
Show resolved
Hide resolved
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
A general mechanism to allow a container (or init-container) environment to overridden from the
OperatorOverride
. Currently it is just applied to the canary image.(The scope of this PR has been broadened. Originally we wanted a mechanism to allow canary reconcile and connection check interval to be overridden to help investigate MGDSTRM-8698 by having the ability to turn off the connection check.
The scope has been extended to include admin server. I note that strimzi does let let you override envvars for any of its deployments.