Example CR
The following example NiFi CR deploys a 3 node cluster with single user authentication (admin/admin), Kubernetes-based state management and leader election, and a Route to access the NiFi UI.
apiVersion: cfm.cloudera.com/v1alpha1
kind: Nifi
metadata:
name: mynifi
spec:
replicas: 3
image:
repository: container.repository.cloudera.com/cloudera/cfm-nifi-k8s
tag: [***NIFI TAG***]
pullSecret: docker-pull-secret
tiniImage:
repository: container.repository.cloudera.com/cloudera/cfm-tini
tag: [***CFM TINI TAG***]
pullSecret: docker-pull-secret
hostName: mynifi.[***OPENSHIFT ROUTER DOMAIN***]
uiConnection:
type: Route
serviceConfig:
sessionAffinity: ClientIP
configOverride:
nifiProperties:
upsert:
nifi.cluster.leader.election.implementation: "KubernetesLeaderElectionManager"
authorizers: |
<authorizers>
<authorizer>
<identifier>single-user-authorizer</identifier>
<class>org.apache.nifi.authorization.single.user.SingleUserAuthorizer</class>
</authorizer>
</authorizers>
loginIdentityProviders: |
<loginIdentityProviders>
<provider>
<identifier>single-user-provider</identifier>
<class>org.apache.nifi.authentication.single.user.SingleUserLoginIdentityProvider</class>
<property name="Username">admin</property>
<property name="Password">$2b$10$GRa8g9Z5rBENXPFNHFBosev9XmY6CSk0SdcBi5sQMRX92KD73asGG</property>
</provider>
</loginIdentityProviders>
stateManagement:
clusterProvider:
id: kubernetes-provider
class: org.apache.nifi.kubernetes.state.provider.KubernetesConfigMapStateProvider