Deploys an NCache distributed cache cluster on
Kubernetes (on-premises, AKS, EKS). The chart creates the NCache server pods, the
client and management gateways, and the caches you enable, and handles licensing, TLS, scaling and
image upgrades through helm install / helm upgrade.
To see every configurable parameter and its default:
helm show values oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8
Only the installation key is required.
deployment.platformcan be used to match your cluster (on-prem, AKS, EKS). But is option paramter and its default value is on-prem
helm install ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--set deployment.key="INSTALLATION-KEY"
This starts a 2-server cluster with the cache defaultCache (Partition-Replica, 1 GB) and runs on
an evaluation license.
Check the deployment:
kubectl get pods
kubectl get services
Activate a purchased license at install time:
helm install ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--set deployment.key="INSTALLATION-KEY" \
--set deployment.platform=on-prem \
--set license.licenseKey="XXXXXXXX-XXXXXX-XXXXXXXX" \
--set license.envName="Prod"
Or on a running release:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values \
--set license.licenseKey="XXXXXXXX-XXXXXX-XXXXXXXX" \
--set license.envName="Prod"
The chart has four cache slots. caches[0] (defaultCache) is enabled by default; enable the others
in order (caches[1] before caches[2]). Disabling a cache removes it and its data.
| Slot | Default name | Store type |
|---|---|---|
caches[0] | defaultCache | Distributed Cache (enabled) |
caches[1] | sessionCache | Distributed Cache |
caches[2] | pubsubCache | Pub/Sub |
caches[3] | dataCache | Distributed Cache |
Create a cache at install time with your own settings:
helm install ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--set deployment.key="INSTALLATION-KEY" \
--set 'caches[1].enabled=true' \
--set 'caches[2].enabled=true' \
--set 'caches[3].enabled=true'
Add a cache to a running release:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values \
--set 'caches[1].enabled=true' \
--set 'caches[2].enabled=true' \
--set 'caches[3].enabled=true'
TLS can be set at install time or switched on and off on a running release; the servers are not replaced, only the caches are restarted one server at a time.
helm install ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--set deployment.key="INSTALLATION-KEY" \
--set tls.enabled=true
Enable or disable on a running release:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values --set tls.enabled=true
The chart publishes two LoadBalancer services:
| Service | Ports | Used by |
|---|---|---|
ncache-client-gateway | 9800 (clients), 9803-9997 | Cache clients |
ncache-mgmt-gateway | 9801 (HTTP) | Browser |
By default the load balancer assigns the address. To give the management gateway a fixed address, set
gateway.mgmtCenterEndpoint:
helm install ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--set deployment.key="INSTALLATION-KEY" \
--set gateway.mgmtCenterEndpoint="20.10.30.40"
Enable or disable on a running release:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values -gateway.mgmtCenterEndpoint="20.10.30.40"
Find the gateway addresses:
kubectl get service ncache-mgmt-gateway ncache-client-gateway
Then open Management Center at http://<EXTERNAL-IP of ncache-mgmt-gateway>:9801 and point clients at
<EXTERNAL-IP of ncache-client-gateway>:9800.
Change the number of NCache servers on a running release. Scale-up adds the pods and joins them to every cache; scale-down removes one server at a time so each partition's replica is rebuilt before the next server leaves.
Scale up to 4 servers:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values \
--set deployment.servers=4
Scale back down to 2 servers:
helm upgrade ncache oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8 \
--reuse-values \
--set deployment.servers=2
Note: NCache is deployed with required pod anti-affinity (
deployment.podAntiAffinity=true, the default), which allows only one NCache server pod per worker node. Before scaling up, make sure the cluster has a free schedulable worker node for every server you add; otherwise the new pods stayPending. Check the available nodes withkubectl get nodes.
Watch the change:
kubectl get pods -w
Always pass --reuse-values to helm upgrade; without it Helm resets every setting you do not repeat
to its default (enabled caches would be removed). deployment.name, deployment.podAntiAffinity and
deployment.platform are fixed at install time and an upgrade that changes them is rejected.
helm uninstall ncache
Content type
Helm
Digest
sha256:bf2c2f321…
Size
30.2 kB
Last updated
5 days ago
helm pull oci://registry-1.docker.io/alachisoft/ncache-helm --version 5.3.8