konpyutaika / nifikop

The NiFiKop NiFi Kubernetes operator makes it easy to run Apache NiFi on Kubernetes. Apache NiFI is a free, open-source solution that support powerful and scalable directed graphs of data routing, transformation, and system mediation logic.
https://konpyutaika.github.io/nifikop/
Apache License 2.0
122 stars 39 forks source link

When using read only authorizerConfig it is not used when adding new nodes #407

Closed wrender closed 2 months ago

wrender commented 3 months ago

What steps will reproduce the bug?

Hello, If I use a read only configuration like this, it works great and provides the functionality I need for ldaps authorizations when I initially setup a cluster. However, when I try later to add another node to the cluster, the node gets added with the default template, instead of my new template, in turn breaking the cluster:

 authorizerConfig:
    replaceTemplateConfigMap:
      data: authorizers.xml
      name: raw
      namespace: nifikop

I also tested with the replaceTemplateSecretConfig and the same issue occurs. For example:

 authorizerConfig:
    replaceTemplateSecretConfig:
      data: authorizers.xml
      name: raw
      namespace: nifikop

What is the expected behavior?

I would expect this to also create this authorizers.xml file the same for new nodes.

What do you see instead?

When I add new nodes the cluster, the are added with the default authorizers.go template, and in turn the cluster seems to fail.

Possible solution

No response

NiFiKop version

v1.7.0-release

Golang version

1.22.1

Kubernetes version

Client Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.3", GitCommit:"2e7996e3e2712684bc73f0dec0200d64eec7fe40", GitTreeState:"clean", BuildDate:"2020-05-20T12:52:00Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"linux/amd64"} Server Version: version.Info{Major:"1", Minor:"27", GitVersion:"v1.27.8", GitCommit:"66fee42707cd7f5a89f1987f7cb81b02dd19161c", GitTreeState:"clean", BuildDate:"2023-11-15T16:50:09Z", GoVersion:"go1.20.11", Compiler:"gc", Platform:"linux/amd64"}

NiFi version

1.23.0

Additional context

No response

mh013370 commented 2 months ago

I've raised a PR to address this.