Hi, has anyone successfully used the Flink Kuberne...
# troubleshooting
r
Hi, has anyone successfully used the Flink Kubernetes Operator with Kustomize? I'm having trouble patching things under
spec.taskManager.podTemplate.spec.containers
. Values from the base get overwritten in the output. My setup is 3 levels of FlinkDeployment: • base (common to all jobs) • job base (common to all environments for a given job) • overlay (configuration for a particular job in a particular environment) In base I would for example mount a configmap to get a Hadoop config, in job base I would reference a common configmap, and in the overlay I would set resources for the pod. I added the
openapi
reference to the CRD definition, too. I did a quick test with a regular Kubernetes deployment and it seems to work as I expect. Any tips?
m
Hi @Ricco Førgaard! We used kustomize for a while extensively with the operator last year. We have a simple example here: https://github.com/apache/flink-kubernetes-operator/tree/main/examples/kustomize
Once you get to 3 layers thing can get tricky, because the second layer might modify things in such a way that the third layers modifications become invalid (even though they would work if you applied the 3rd layer onto the first directly). Other than debugging layer by layer there is not much more tricks that I can share unfortunately.
r
Ok thanks, I guess I'll have to dig deeper 🙂
I looked at the openapi schema and notice that the schema generated by the operator (or fabric8 maybe) doesn't use the
x-kubernetes-patch-merge-key
and
x-kubernetes-patch-strategy
properties like the Kubernetes schema does. Do you think it could cause any problems?