nifikop icon indicating copy to clipboard operation
nifikop copied to clipboard

no effect for componentId in NifiUser / NifiUserGroup (accessPolicies)

Open teplydat opened this issue 4 years ago • 0 comments

Bug Report

What did you do? I want to grant permission on specific "components" (let's call it "itam". So it is a process group under "NiFi Flow") via CR "NifiUserGroup". Doc is here: https://orange-opensource.github.io/nifikop/docs/v0.4.3/3_tasks/4_nifi_user_group

...
- type: component
      action: read
      resource: /
      componentType: process-groups
      componentId: 1ac3ab15-0177-1000-0000-000017feb4b2
#      componentId: "1ac3ab15-0177-1000-0000-000017feb4b2"
#      componentId: "itam"

I tried different things for componentId.

What did you expect to see? User policy should be for example: "Component policy for process Group itam"

What did you see instead? Under which circumstances? No such policy. If I don't specify "componentId" then it is: "Component policy for process Group NiFi Flow"

Environment

  • nifikop version: nifikop: v0.4.2-alpha-release

  • go version: -

  • Kubernetes version information: OpenShift 4.6.z, K8s 1.19

  • Kubernetes cluster kind: ?

  • NiFi version: nifi-1.11.4-RC1

Possible Solution It seems the componentId is not set here: https://github.com/Orange-OpenSource/nifikop/blob/08e3fc742d96d630287b244f95b4e2dbeb2890a1/pkg/clientwrappers/accesspolicies/policies.go#L132

Would be very nice if someone can help!

teplydat avatar Jan 22 '21 08:01 teplydat