1################################################################################
3################################################################################
6 # global image pull policy to use for all container images in the chart
7 # can be overridden by individual image pullPolicy
9 # global list of secret names to use as image pull secrets for all pod specs in the chart
10 # secrets must exist in the same namespace
11 # https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
13 # global registry to use for all container images in the chart
14 # can be overridden by individual image registry
16 # global labels will be applied to all resources deployed by the chart
18################################################################################
20################################################################################
21# override name of the chart
23# override full name of the chart+release
25# override the namespace that resources are installed into
27# reference a common CA Certificate or Bundle in all nats config `tls` blocks and nats-box contexts
28# note: `tls.verify` still must be set in the appropriate nats config `tls` blocks to require mTLS
31 # set configMapName in order to mount an existing configMap to dir
33 # set secretName in order to mount an existing secretName to dir
35 # directory to mount the configMap or secret to
36 dir: /etc/nats-ca-cert
37 # key in the configMap or secret that contains the CA Certificate or Bundle
39################################################################################
40# NATS Stateful Set and associated resources
41################################################################################
43############################################################
45############################################################
50 # must be 2 or higher when jetstream is enabled
52 # set to false to allow cluster nodes to advertise their addresses
53 # so that clients can reconnect without extra DNS lookups.
54 # Note: in case clients have external connectivity make sure to define the `advertise` section as well.
55 # If clients are behind a load balancer it is best to leave this as is.
57 # apply to generated route URLs that connect to other pods in the StatefulSet
59 # if both user and password are set, they will be added to route URLs
60 # and the cluster authorization block
63 # set to true to use FQDN in route URLs
65 k8sClusterDomain: cluster.local
68 # set secretName in order to mount an existing secret to dir
70 dir: /etc/nats-certs/cluster
73 # merge or patch the tls config
74 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
77 # merge or patch the cluster config
78 # https://docs.nats.io/running-a-nats-service/configuration/clustering/cluster_config
86 ############################################################
87 # stateful set -> volume claim templates -> jetstream pvc
88 ############################################################
93 # merge or patch the jetstream pvc
94 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#persistentvolumeclaim-v1-core
97 # defaults to "{{ include "nats.fullname" $ }}-js"
99 # defaults to the PVC size
103 # ensure that container has a sufficient memory limit greater than maxSize
105 # merge or patch the jetstream config
106 # https://docs.nats.io/running-a-nats-service/configuration#jetstream
113 # set secretName in order to mount an existing secret to dir
115 dir: /etc/nats-certs/nats
118 # merge or patch the tls config
119 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
127 # set secretName in order to mount an existing secret to dir
129 dir: /etc/nats-certs/leafnodes
132 # merge or patch the tls config
133 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
136 # merge or patch the leafnodes config
137 # https://docs.nats.io/running-a-nats-service/configuration/leafnodes/leafnode_conf
145 # set secretName in order to mount an existing secret to dir
147 dir: /etc/nats-certs/websocket
150 # merge or patch the tls config
151 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
154 ############################################################
156 ############################################################
157 # service must be enabled also
160 # must contain at least 1 host otherwise ingress will not be created
164 # sets to the ingress class name
166 # set to an existing secret name to enable TLS on the ingress; applies to all hosts
168 # merge or patch the ingress
169 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#ingress-v1-networking-k8s-io
172 # defaults to "{{ include "nats.fullname" $ }}-ws"
174 # merge or patch the websocket config
175 # https://docs.nats.io/running-a-nats-service/configuration/websocket/websocket_conf
183 # set secretName in order to mount an existing secret to dir
185 dir: /etc/nats-certs/mqtt
188 # merge or patch the tls config
189 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
192 # merge or patch the mqtt config
193 # https://docs.nats.io/running-a-nats-service/configuration/mqtt/mqtt_config
201 # set secretName in order to mount an existing secret to dir
203 dir: /etc/nats-certs/gateway
206 # merge or patch the tls config
207 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/tls
210 # merge or patch the gateway config
211 # https://docs.nats.io/running-a-nats-service/configuration/gateways/gateway#gateway-configuration-block
218 # config.nats.tls must be enabled also
219 # when enabled, monitoring port will use HTTPS with the options from config.nats.tls
220 # if promExporter is also enabled, consider setting promExporter.monitorDomain
228 ############################################################
229 # stateful set -> volume claim templates -> resolver pvc
230 ############################################################
235 # merge or patch the pvc
236 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#persistentvolumeclaim-v1-core
239 # defaults to "{{ include "nats.fullname" $ }}-resolver"
241 # merge or patch the resolver
242 # https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/jwt/resolver
245 # adds a prefix to the server name, which defaults to the pod name
246 # helpful for ensuring server name is unique in a super cluster
248 # merge or patch the nats config
249 # https://docs.nats.io/running-a-nats-service/configuration
250 # following special rules apply
251 # 1. strings that start with << and end with >> will be unquoted
252 # use this for variables and numbers with units
253 # 2. keys ending in $include will be switched to include directives
254 # keys are sorted alphabetically, use prefix before $includes to control includes ordering
255 # paths should be relative to /etc/nats-config/nats.conf
259 # $include: ./my-config.conf
260 # zzz$include: ./my-config-last.conf
263 # token: << $TOKEN >>
265 # max_memory_store: << 1GB >>
267 # will yield the config:
269 # include ./my-config.conf;
274 # "max_memory_store": 1GB
276 # "server_name": "nats",
277 # include ./my-config-last.conf;
281############################################################
282# stateful set -> pod template -> nats container
283############################################################
286 repository: chainguard-private/nats
290 # if digest is provided, it overrides tag (example: "sha256:abcdef1234567890")
291 digest: sha256:96317aa77c165e25a1308af285c223a8105fbad79ceb90e5e6fc752b9d7abc22
292 # if fullImageName is provided, it overrides registry, repository, tag, and digest
294 # container port options
295 # must be enabled in the config section also
296 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#containerport-v1-core
306 # map with key as env var name, value can be string or map
317 # merge or patch the container
318 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#container-v1-core
321 # container resources
329############################################################
330# stateful set -> pod template -> reloader container
331############################################################
335 repository: chainguard-private/nats-server-config-reloader
339 digest: sha256:b2072fe7907cc604593368dff03f5c0a5430102aa3f9f067de10bc89f1f19cb9
341 # env var map, see nats.env for an example
343 # all nats container volume mounts with the following prefixes
344 # will be mounted into the reloader container
345 natsVolumeMountPrefixes:
347 # merge or patch the container
348 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#container-v1-core
351############################################################
352# stateful set -> pod template -> prom-exporter container
353############################################################
354# config.monitor must be enabled
358 repository: chainguard-private/prometheus-nats-exporter
362 digest: sha256:f373df5ff8977b72d994e83d0d7a3a8b4bd5dab8fcae0976696c337a3c29fbea
365 # if config.monitor.tls.enabled is set to true, monitorDomain must be set to the common name
366 # or a SAN used in the tls certificate
367 monitorDomain: localhost
368 # env var map, see nats.env for an example
370 # merge or patch the container
371 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#container-v1-core
374 ############################################################
375 # prometheus pod monitor
376 ############################################################
379 # merge or patch the pod monitor
380 # https://prometheus-operator.dev/docs/api-reference/api/#monitoring.coreos.com/v1.PodMonitor
383 # defaults to "{{ include "nats.fullname" $ }}"
385############################################################
387############################################################
390 # service port options
391 # additional boolean field enable to control whether port is exposed in the service
392 # must be enabled in the config section also
393 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#serviceport-v1-core
411 # merge or patch the service
412 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#service-v1-core
415 # defaults to "{{ include "nats.fullname" $ }}"
417############################################################
418# other nats extension points
419############################################################
423 # merge or patch the stateful set
424 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#statefulset-v1-apps
427 # defaults to "{{ include "nats.fullname" $ }}"
429# stateful set -> pod template
431 # adds a hash of the ConfigMap as a pod annotation
432 # this will cause the StatefulSet to roll when the ConfigMap is updated
433 # set to true to force pod rollouts on config changes instead of using the reloader for hot updates
434 configChecksumAnnotation: false
435 # map of topologyKey: topologySpreadConstraint
436 # labelSelector will be added to match StatefulSet pods
438 # topologySpreadConstraints:
439 # kubernetes.io/hostname:
442 topologySpreadConstraints: {}
443 # merge or patch the pod template
444 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#pod-v1-core
449 # merge or patch the headless service
450 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#service-v1-core
453 # defaults to "{{ include "nats.fullname" $ }}-headless"
457 # merge or patch the config map
458 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#configmap-v1-core
461 # defaults to "{{ include "nats.fullname" $ }}-config"
463# pod disruption budget
466 # merge or patch the pod disruption budget
467 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#poddisruptionbudget-v1-policy
470 # defaults to "{{ include "nats.fullname" $ }}"
475 # merge or patch the service account
476 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#serviceaccount-v1-core
479 # defaults to "{{ include "nats.fullname" $ }}"
481############################################################
484# NATS Box Deployment and associated resources
485############################################################
488 ############################################################
490 ############################################################
494 # set contents in order to create a secret with the creds file contents
496 # set secretName in order to mount an existing secret to dir
498 # defaults to /etc/nats-creds/<context-name>
502 # set contents in order to create a secret with the nkey file contents
504 # set secretName in order to mount an existing secret to dir
506 # defaults to /etc/nats-nkeys/<context-name>
509 # used to connect with client certificates
511 # set secretName in order to mount an existing secret to dir
513 # defaults to /etc/nats-certs/<context-name>
517 # merge or patch the context
518 # https://docs.nats.io/using-nats/nats-tools/nats_cli#nats-contexts
521 # name of context to select by default
522 defaultContextName: default
523 ############################################################
524 # deployment -> pod template -> nats-box container
525 ############################################################
528 repository: chainguard-private/nats-box
532 digest: sha256:5c608e7ff75a15d6c8402b5e14671fd3e34fb4f26a4ddf8636fae9d6d8f48b01
535 # env var map, see nats.env for an example
537 # merge or patch the container
538 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#container-v1-core
541 ############################################################
542 # other nats-box extension points
543 ############################################################
547 # merge or patch the deployment
548 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#deployment-v1-apps
551 # defaults to "{{ include "nats.fullname" $ }}-box"
553 # deployment -> pod template
555 # merge or patch the pod template
556 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#pod-v1-core
561 # merge or patch the context secret
562 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#secret-v1-core
565 # defaults to "{{ include "nats.fullname" $ }}-box-contexts"
569 # merge or patch the contents secret
570 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#secret-v1-core
573 # defaults to "{{ include "nats.fullname" $ }}-box-contents"
578 # merge or patch the service account
579 # https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#serviceaccount-v1-core
582 # defaults to "{{ include "nats.fullname" $ }}-box"
584################################################################################
585# Extra user-defined resources
586################################################################################
588# add arbitrary user-generated resources
595# - apiVersion: networking.istio.io/v1beta1
596# kind: VirtualService
600# {{ include "nats.fullname" $ | quote }}
603# {{ include "nats.labels" $ }}
619# {{ .Values.service.name | quote }}
623# {{ .Values.config.websocket.port }}