Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1 | ## nginx configuration |
| 2 | ## Ref: https://github.com/kubernetes/ingress-nginx/blob/main/docs/user-guide/nginx-configuration/index.md |
| 3 | ## |
| 4 | |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 5 | global: |
| 6 | image: |
| 7 | # -- Registry host to pull images from. |
| 8 | registry: registry.k8s.io |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 9 | ## Overrides for generated resource names |
| 10 | # See templates/_helpers.tpl |
| 11 | # nameOverride: |
| 12 | # fullnameOverride: |
| 13 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 14 | # -- Override the deployment namespace; defaults to .Release.Namespace |
| 15 | namespaceOverride: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 16 | ## Labels to apply to all resources |
| 17 | ## |
| 18 | commonLabels: {} |
| 19 | # scmhash: abc123 |
| 20 | # myLabel: aakkmd |
| 21 | |
| 22 | controller: |
| 23 | name: controller |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 24 | enableAnnotationValidations: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 25 | image: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 26 | ## Keep false as default for now! |
| 27 | chroot: false |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 28 | # registry: registry.k8s.io |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 29 | image: ingress-nginx/controller |
| 30 | ## for backwards compatibility consider setting the full image url via the repository value below |
| 31 | ## use *either* current default registry/image or repository format or installing chart by providing the values.yaml will fail |
| 32 | ## repository: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 33 | tag: "v1.12.1" |
| 34 | digest: sha256:d2fbc4ec70d8aa2050dd91a91506e998765e86c96f32cffb56c503c9c34eed5b |
| 35 | digestChroot: sha256:90155c86548e0bb95b3abf1971cd687d8f5d43f340cfca0ad3484e2b8351096e |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 36 | pullPolicy: IfNotPresent |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 37 | runAsNonRoot: true |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 38 | # -- This value must not be changed using the official image. |
| 39 | # uid=101(www-data) gid=82(www-data) groups=82(www-data) |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 40 | runAsUser: 101 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 41 | # -- This value must not be changed using the official image. |
| 42 | # uid=101(www-data) gid=82(www-data) groups=82(www-data) |
| 43 | runAsGroup: 82 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 44 | allowPrivilegeEscalation: false |
| 45 | seccompProfile: |
| 46 | type: RuntimeDefault |
| 47 | readOnlyRootFilesystem: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 48 | # -- Configures the controller container name |
| 49 | containerName: controller |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 50 | # -- Configures the ports that the nginx-controller listens on |
| 51 | containerPort: |
| 52 | http: 80 |
| 53 | https: 443 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 54 | # -- Global configuration passed to the ConfigMap consumed by the controller. Values may contain Helm templates. |
| 55 | # Ref.: https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/configmap/ |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 56 | config: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 57 | # -- Annotations to be added to the controller config configuration configmap. |
| 58 | configAnnotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 59 | # -- Will add custom headers before sending traffic to backends according to https://github.com/kubernetes/ingress-nginx/tree/main/docs/examples/customization/custom-headers |
| 60 | proxySetHeaders: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 61 | # -- Will add custom headers before sending response traffic to the client according to: https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/configmap/#add-headers |
| 62 | addHeaders: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 63 | # -- Optionally customize the pod dnsConfig. |
| 64 | dnsConfig: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 65 | # -- Optionally customize the pod hostAliases. |
| 66 | hostAliases: [] |
| 67 | # - ip: 127.0.0.1 |
| 68 | # hostnames: |
| 69 | # - foo.local |
| 70 | # - bar.local |
| 71 | # - ip: 10.1.2.3 |
| 72 | # hostnames: |
| 73 | # - foo.remote |
| 74 | # - bar.remote |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 75 | # -- Optionally customize the pod hostname. |
| 76 | hostname: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 77 | # -- Optionally change this to ClusterFirstWithHostNet in case you have 'hostNetwork: true'. |
| 78 | # By default, while using host network, name resolution uses the host's DNS. If you wish nginx-controller |
| 79 | # to keep resolving names inside the k8s network, use ClusterFirstWithHostNet. |
| 80 | dnsPolicy: ClusterFirst |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 81 | # -- Bare-metal considerations via the host network https://kubernetes.github.io/ingress-nginx/deploy/baremetal/#via-the-host-network |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 82 | # Ingress status was blank because there is no Service exposing the Ingress-Nginx Controller in a configuration using the host network, the default --publish-service flag used in standard cloud setups does not apply |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 83 | reportNodeInternalIp: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 84 | # -- Process Ingress objects without ingressClass annotation/ingressClassName field |
| 85 | # Overrides value for --watch-ingress-without-class flag of the controller binary |
| 86 | # Defaults to false |
| 87 | watchIngressWithoutClass: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 88 | # -- Process IngressClass per name (additionally as per spec.controller). |
| 89 | ingressClassByName: false |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 90 | # -- This configuration enables Topology Aware Routing feature, used together with service annotation service.kubernetes.io/topology-mode="auto" |
| 91 | # Defaults to false |
| 92 | enableTopologyAwareRouting: false |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 93 | # -- This configuration disable Nginx Controller Leader Election |
| 94 | disableLeaderElection: false |
| 95 | # -- Duration a leader election is valid before it's getting re-elected, e.g. `15s`, `10m` or `1h`. (Default: 30s) |
| 96 | electionTTL: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 97 | # -- This configuration defines if Ingress Controller should allow users to set |
| 98 | # their own *-snippet annotations, otherwise this is forbidden / dropped |
| 99 | # when users add those annotations. |
| 100 | # Global snippets in ConfigMap are still respected |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 101 | allowSnippetAnnotations: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 102 | # -- Required for use with CNI based kubernetes installations (such as ones set up by kubeadm), |
| 103 | # since CNI and hostport don't mix yet. Can be deprecated once https://github.com/kubernetes/kubernetes/issues/23920 |
| 104 | # is merged |
| 105 | hostNetwork: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 106 | ## Use host ports 80 and 443 |
| 107 | ## Disabled by default |
| 108 | hostPort: |
| 109 | # -- Enable 'hostPort' or not |
| 110 | enabled: false |
| 111 | ports: |
| 112 | # -- 'hostPort' http port |
| 113 | http: 80 |
| 114 | # -- 'hostPort' https port |
| 115 | https: 443 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 116 | # NetworkPolicy for controller component. |
| 117 | networkPolicy: |
| 118 | # -- Enable 'networkPolicy' or not |
| 119 | enabled: false |
| 120 | # -- Election ID to use for status update, by default it uses the controller name combined with a suffix of 'leader' |
| 121 | electionID: "" |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 122 | # -- This section refers to the creation of the IngressClass resource. |
| 123 | # IngressClasses are immutable and cannot be changed after creation. |
| 124 | # We do not support namespaced IngressClasses, yet, so a ClusterRole and a ClusterRoleBinding is required. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 125 | ingressClassResource: |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 126 | # -- Name of the IngressClass |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 127 | name: nginx |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 128 | # -- Create the IngressClass or not |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 129 | enabled: true |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 130 | # -- If true, Ingresses without `ingressClassName` get assigned to this IngressClass on creation. |
| 131 | # Ingress creation gets rejected if there are multiple default IngressClasses. |
| 132 | # Ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#default-ingress-class |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 133 | default: false |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 134 | # -- Annotations to be added to the IngressClass resource. |
| 135 | annotations: {} |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 136 | # -- Controller of the IngressClass. An Ingress Controller looks for IngressClasses it should reconcile by this value. |
| 137 | # This value is also being set as the `--controller-class` argument of this Ingress Controller. |
| 138 | # Ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#ingress-class |
| 139 | controllerValue: k8s.io/ingress-nginx |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 140 | # -- Aliases of this IngressClass. Creates copies with identical settings but the respective alias as name. |
| 141 | # Useful for development environments with only one Ingress Controller but production-like Ingress resources. |
| 142 | # `default` gets enabled on the original IngressClass only. |
| 143 | aliases: [] |
| 144 | # aliases: |
| 145 | # - nginx-alias-1 |
| 146 | # - nginx-alias-2 |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 147 | # -- A link to a custom resource containing additional configuration for the controller. |
| 148 | # This is optional if the controller consuming this IngressClass does not require additional parameters. |
| 149 | # Ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#ingress-class |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 150 | parameters: {} |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 151 | # parameters: |
| 152 | # apiGroup: k8s.example.com |
| 153 | # kind: IngressParameters |
| 154 | # name: external-lb |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 155 | # -- For backwards compatibility with ingress.class annotation, use ingressClass. |
| 156 | # Algorithm is as follows, first ingressClassName is considered, if not present, controller looks for ingress.class annotation |
| 157 | ingressClass: nginx |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 158 | # -- Labels to add to the pod container metadata |
| 159 | podLabels: {} |
| 160 | # key: value |
| 161 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 162 | # -- Security context for controller pods |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 163 | podSecurityContext: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 164 | # -- sysctls for controller pods |
| 165 | ## Ref: https://kubernetes.io/docs/tasks/administer-cluster/sysctl-cluster/ |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 166 | sysctls: {} |
| 167 | # sysctls: |
| 168 | # "net.core.somaxconn": "8192" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 169 | # -- Security context for controller containers |
| 170 | containerSecurityContext: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 171 | # -- Allows customization of the source of the IP address or FQDN to report |
| 172 | # in the ingress status field. By default, it reads the information provided |
| 173 | # by the service. If disable, the status field reports the IP address of the |
| 174 | # node or nodes where an ingress controller pod is running. |
| 175 | publishService: |
| 176 | # -- Enable 'publishService' or not |
| 177 | enabled: true |
| 178 | # -- Allows overriding of the publish service to bind to |
| 179 | # Must be <namespace>/<service_name> |
| 180 | pathOverride: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 181 | # Limit the scope of the controller to a specific namespace |
| 182 | scope: |
| 183 | # -- Enable 'scope' or not |
| 184 | enabled: false |
| 185 | # -- Namespace to limit the controller to; defaults to $(POD_NAMESPACE) |
| 186 | namespace: "" |
| 187 | # -- When scope.enabled == false, instead of watching all namespaces, we watching namespaces whose labels |
| 188 | # only match with namespaceSelector. Format like foo=bar. Defaults to empty, means watching all namespaces. |
| 189 | namespaceSelector: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 190 | # -- Allows customization of the configmap / nginx-configmap namespace; defaults to $(POD_NAMESPACE) |
| 191 | configMapNamespace: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 192 | tcp: |
| 193 | # -- Allows customization of the tcp-services-configmap; defaults to $(POD_NAMESPACE) |
| 194 | configMapNamespace: "" |
| 195 | # -- Annotations to be added to the tcp config configmap |
| 196 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 197 | udp: |
| 198 | # -- Allows customization of the udp-services-configmap; defaults to $(POD_NAMESPACE) |
| 199 | configMapNamespace: "" |
| 200 | # -- Annotations to be added to the udp config configmap |
| 201 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 202 | # -- Maxmind license key to download GeoLite2 Databases. |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 203 | ## https://blog.maxmind.com/2019/12/significant-changes-to-accessing-and-using-geolite2-databases/ |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 204 | maxmindLicenseKey: "" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 205 | # -- Additional command line arguments to pass to Ingress-Nginx Controller |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 206 | # E.g. to specify the default SSL certificate you can use |
| 207 | extraArgs: {} |
| 208 | ## extraArgs: |
| 209 | ## default-ssl-certificate: "<namespace>/<secret_name>" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 210 | ## time-buckets: "0.005,0.01,0.025,0.05,0.1,0.25,0.5,1,2.5,5,10" |
| 211 | ## length-buckets: "10,20,30,40,50,60,70,80,90,100" |
| 212 | ## size-buckets: "10,100,1000,10000,100000,1e+06,1e+07" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 213 | |
| 214 | # -- Additional environment variables to set |
| 215 | extraEnvs: [] |
| 216 | # extraEnvs: |
| 217 | # - name: FOO |
| 218 | # valueFrom: |
| 219 | # secretKeyRef: |
| 220 | # key: FOO |
| 221 | # name: secret-resource |
| 222 | |
| 223 | # -- Use a `DaemonSet` or `Deployment` |
| 224 | kind: Deployment |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 225 | # -- Annotations to be added to the controller Deployment or DaemonSet |
| 226 | ## |
| 227 | annotations: {} |
| 228 | # keel.sh/pollSchedule: "@every 60m" |
| 229 | |
| 230 | # -- Labels to be added to the controller Deployment or DaemonSet and other resources that do not have option to specify labels |
| 231 | ## |
| 232 | labels: {} |
| 233 | # keel.sh/policy: patch |
| 234 | # keel.sh/trigger: poll |
| 235 | |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 236 | # -- The update strategy to apply to the Deployment or DaemonSet |
| 237 | ## |
| 238 | updateStrategy: {} |
| 239 | # rollingUpdate: |
| 240 | # maxUnavailable: 1 |
| 241 | # type: RollingUpdate |
| 242 | |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 243 | # -- Specifies the number of seconds you want to wait for the controller deployment to progress before the system reports back that it has failed. |
| 244 | # Ref.: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#progress-deadline-seconds |
| 245 | progressDeadlineSeconds: 0 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 246 | # -- `minReadySeconds` to avoid killing pods before we are ready |
| 247 | ## |
| 248 | minReadySeconds: 0 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 249 | # -- Node tolerations for server scheduling to nodes with taints |
| 250 | ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ |
| 251 | ## |
| 252 | tolerations: [] |
| 253 | # - key: "key" |
| 254 | # operator: "Equal|Exists" |
| 255 | # value: "value" |
| 256 | # effect: "NoSchedule|PreferNoSchedule|NoExecute(1.6 only)" |
| 257 | |
| 258 | # -- Affinity and anti-affinity rules for server scheduling to nodes |
| 259 | ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity |
| 260 | ## |
| 261 | affinity: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 262 | # # An example of preferred pod anti-affinity, weight is in the range 1-100 |
| 263 | # podAntiAffinity: |
| 264 | # preferredDuringSchedulingIgnoredDuringExecution: |
| 265 | # - weight: 100 |
| 266 | # podAffinityTerm: |
| 267 | # labelSelector: |
| 268 | # matchExpressions: |
| 269 | # - key: app.kubernetes.io/name |
| 270 | # operator: In |
| 271 | # values: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 272 | # - '{{ include "ingress-nginx.name" . }}' |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 273 | # - key: app.kubernetes.io/instance |
| 274 | # operator: In |
| 275 | # values: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 276 | # - '{{ .Release.Name }}' |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 277 | # - key: app.kubernetes.io/component |
| 278 | # operator: In |
| 279 | # values: |
| 280 | # - controller |
| 281 | # topologyKey: kubernetes.io/hostname |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 282 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 283 | # # An example of required pod anti-affinity |
| 284 | # podAntiAffinity: |
| 285 | # requiredDuringSchedulingIgnoredDuringExecution: |
| 286 | # - labelSelector: |
| 287 | # matchExpressions: |
| 288 | # - key: app.kubernetes.io/name |
| 289 | # operator: In |
| 290 | # values: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 291 | # - '{{ include "ingress-nginx.name" . }}' |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 292 | # - key: app.kubernetes.io/instance |
| 293 | # operator: In |
| 294 | # values: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 295 | # - '{{ .Release.Name }}' |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 296 | # - key: app.kubernetes.io/component |
| 297 | # operator: In |
| 298 | # values: |
| 299 | # - controller |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 300 | # topologyKey: kubernetes.io/hostname |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 301 | |
| 302 | # -- Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in. |
| 303 | ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/ |
| 304 | ## |
| 305 | topologySpreadConstraints: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 306 | # - labelSelector: |
| 307 | # matchLabels: |
| 308 | # app.kubernetes.io/name: '{{ include "ingress-nginx.name" . }}' |
| 309 | # app.kubernetes.io/instance: '{{ .Release.Name }}' |
| 310 | # app.kubernetes.io/component: controller |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 311 | # matchLabelKeys: |
| 312 | # - pod-template-hash |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 313 | # topologyKey: topology.kubernetes.io/zone |
| 314 | # maxSkew: 1 |
| 315 | # whenUnsatisfiable: ScheduleAnyway |
| 316 | # - labelSelector: |
| 317 | # matchLabels: |
| 318 | # app.kubernetes.io/name: '{{ include "ingress-nginx.name" . }}' |
| 319 | # app.kubernetes.io/instance: '{{ .Release.Name }}' |
| 320 | # app.kubernetes.io/component: controller |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 321 | # matchLabelKeys: |
| 322 | # - pod-template-hash |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 323 | # topologyKey: kubernetes.io/hostname |
| 324 | # maxSkew: 1 |
| 325 | # whenUnsatisfiable: ScheduleAnyway |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 326 | |
| 327 | # -- `terminationGracePeriodSeconds` to avoid killing pods before we are ready |
| 328 | ## wait up to five minutes for the drain of connections |
| 329 | ## |
| 330 | terminationGracePeriodSeconds: 300 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 331 | # -- Node labels for controller pod assignment |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 332 | ## Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 333 | ## |
| 334 | nodeSelector: |
| 335 | kubernetes.io/os: linux |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 336 | ## Liveness and readiness probe values |
| 337 | ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#container-probes |
| 338 | ## |
| 339 | ## startupProbe: |
| 340 | ## httpGet: |
| 341 | ## # should match container.healthCheckPath |
| 342 | ## path: "/healthz" |
| 343 | ## port: 10254 |
| 344 | ## scheme: HTTP |
| 345 | ## initialDelaySeconds: 5 |
| 346 | ## periodSeconds: 5 |
| 347 | ## timeoutSeconds: 2 |
| 348 | ## successThreshold: 1 |
| 349 | ## failureThreshold: 5 |
| 350 | livenessProbe: |
| 351 | httpGet: |
| 352 | # should match container.healthCheckPath |
| 353 | path: "/healthz" |
| 354 | port: 10254 |
| 355 | scheme: HTTP |
| 356 | initialDelaySeconds: 10 |
| 357 | periodSeconds: 10 |
| 358 | timeoutSeconds: 1 |
| 359 | successThreshold: 1 |
| 360 | failureThreshold: 5 |
| 361 | readinessProbe: |
| 362 | httpGet: |
| 363 | # should match container.healthCheckPath |
| 364 | path: "/healthz" |
| 365 | port: 10254 |
| 366 | scheme: HTTP |
| 367 | initialDelaySeconds: 10 |
| 368 | periodSeconds: 10 |
| 369 | timeoutSeconds: 1 |
| 370 | successThreshold: 1 |
| 371 | failureThreshold: 3 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 372 | # -- Path of the health check endpoint. All requests received on the port defined by |
| 373 | # the healthz-port parameter are forwarded internally to this path. |
| 374 | healthCheckPath: "/healthz" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 375 | # -- Address to bind the health check endpoint. |
| 376 | # It is better to set this option to the internal node address |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 377 | # if the Ingress-Nginx Controller is running in the `hostNetwork: true` mode. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 378 | healthCheckHost: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 379 | # -- Annotations to be added to controller pods |
| 380 | ## |
| 381 | podAnnotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 382 | replicaCount: 1 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 383 | # -- Minimum available pods set in PodDisruptionBudget. |
| 384 | # Define either 'minAvailable' or 'maxUnavailable', never both. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 385 | minAvailable: 1 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 386 | # -- Maximum unavailable pods set in PodDisruptionBudget. If set, 'minAvailable' is ignored. |
| 387 | # maxUnavailable: 1 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 388 | # -- Eviction policy for unhealthy pods guarded by PodDisruptionBudget. |
| 389 | # Ref: https://kubernetes.io/blog/2023/01/06/unhealthy-pod-eviction-policy-for-pdbs/ |
| 390 | unhealthyPodEvictionPolicy: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 391 | ## Define requests resources to avoid probe issues due to CPU utilization in busy nodes |
| 392 | ## ref: https://github.com/kubernetes/ingress-nginx/issues/4735#issuecomment-551204903 |
| 393 | ## Ideally, there should be no limits. |
| 394 | ## https://engineering.indeedblog.com/blog/2019/12/cpu-throttling-regression-fix/ |
| 395 | resources: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 396 | ## limits: |
| 397 | ## cpu: 100m |
| 398 | ## memory: 90Mi |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 399 | requests: |
| 400 | cpu: 100m |
| 401 | memory: 90Mi |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 402 | # Mutually exclusive with keda autoscaling |
| 403 | autoscaling: |
| 404 | enabled: false |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 405 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 406 | minReplicas: 1 |
| 407 | maxReplicas: 11 |
| 408 | targetCPUUtilizationPercentage: 50 |
| 409 | targetMemoryUtilizationPercentage: 50 |
| 410 | behavior: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 411 | # scaleDown: |
| 412 | # stabilizationWindowSeconds: 300 |
| 413 | # policies: |
| 414 | # - type: Pods |
| 415 | # value: 1 |
| 416 | # periodSeconds: 180 |
| 417 | # scaleUp: |
| 418 | # stabilizationWindowSeconds: 300 |
| 419 | # policies: |
| 420 | # - type: Pods |
| 421 | # value: 2 |
| 422 | # periodSeconds: 60 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 423 | autoscalingTemplate: [] |
| 424 | # Custom or additional autoscaling metrics |
| 425 | # ref: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/#support-for-custom-metrics |
| 426 | # - type: Pods |
| 427 | # pods: |
| 428 | # metric: |
| 429 | # name: nginx_ingress_controller_nginx_process_requests_total |
| 430 | # target: |
| 431 | # type: AverageValue |
| 432 | # averageValue: 10000m |
| 433 | |
| 434 | # Mutually exclusive with hpa autoscaling |
| 435 | keda: |
| 436 | apiVersion: "keda.sh/v1alpha1" |
| 437 | ## apiVersion changes with keda 1.x vs 2.x |
| 438 | ## 2.x = keda.sh/v1alpha1 |
| 439 | ## 1.x = keda.k8s.io/v1alpha1 |
| 440 | enabled: false |
| 441 | minReplicas: 1 |
| 442 | maxReplicas: 11 |
| 443 | pollingInterval: 30 |
| 444 | cooldownPeriod: 300 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 445 | # fallback: |
| 446 | # failureThreshold: 3 |
| 447 | # replicas: 11 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 448 | restoreToOriginalReplicaCount: false |
| 449 | scaledObject: |
| 450 | annotations: {} |
| 451 | # Custom annotations for ScaledObject resource |
| 452 | # annotations: |
| 453 | # key: value |
| 454 | triggers: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 455 | # - type: prometheus |
| 456 | # metadata: |
| 457 | # serverAddress: http://<prometheus-host>:9090 |
| 458 | # metricName: http_requests_total |
| 459 | # threshold: '100' |
| 460 | # query: sum(rate(http_requests_total{deployment="my-deployment"}[2m])) |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 461 | |
| 462 | behavior: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 463 | # scaleDown: |
| 464 | # stabilizationWindowSeconds: 300 |
| 465 | # policies: |
| 466 | # - type: Pods |
| 467 | # value: 1 |
| 468 | # periodSeconds: 180 |
| 469 | # scaleUp: |
| 470 | # stabilizationWindowSeconds: 300 |
| 471 | # policies: |
| 472 | # - type: Pods |
| 473 | # value: 2 |
| 474 | # periodSeconds: 60 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 475 | # -- Enable mimalloc as a drop-in replacement for malloc. |
| 476 | ## ref: https://github.com/microsoft/mimalloc |
| 477 | ## |
| 478 | enableMimalloc: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 479 | ## Override NGINX template |
| 480 | customTemplate: |
| 481 | configMapName: "" |
| 482 | configMapKey: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 483 | service: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 484 | # -- Enable controller services or not. This does not influence the creation of either the admission webhook or the metrics service. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 485 | enabled: true |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 486 | external: |
| 487 | # -- Enable the external controller service or not. Useful for internal-only deployments. |
| 488 | enabled: true |
| 489 | # -- Annotations to be added to the external controller service. See `controller.service.internal.annotations` for annotations to be added to the internal controller service. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 490 | annotations: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 491 | # -- Labels to be added to both controller services. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 492 | labels: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 493 | # -- Type of the external controller service. |
| 494 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types |
| 495 | type: LoadBalancer |
| 496 | # -- Pre-defined cluster internal IP address of the external controller service. Take care of collisions with existing services. |
| 497 | # This value is immutable. Set once, it can not be changed without deleting and re-creating the service. |
| 498 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#choosing-your-own-ip-address |
| 499 | clusterIP: "" |
| 500 | # -- List of node IP addresses at which the external controller service is available. |
| 501 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#external-ips |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 502 | externalIPs: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 503 | # -- Deprecated: Pre-defined IP address of the external controller service. Used by cloud providers to connect the resulting load balancer service to a pre-existing static IP. |
| 504 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer |
| 505 | loadBalancerIP: "" |
| 506 | # -- Restrict access to the external controller service. Values must be CIDRs. Allows any source address by default. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 507 | loadBalancerSourceRanges: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 508 | # -- Load balancer class of the external controller service. Used by cloud providers to select a load balancer implementation other than the cloud provider default. |
| 509 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#load-balancer-class |
| 510 | loadBalancerClass: "" |
| 511 | # -- Enable node port allocation for the external controller service or not. Applies to type `LoadBalancer` only. |
| 512 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#load-balancer-nodeport-allocation |
| 513 | # allocateLoadBalancerNodePorts: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 514 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 515 | # -- External traffic policy of the external controller service. Set to "Local" to preserve source IP on providers supporting it. |
| 516 | # Ref: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip |
| 517 | externalTrafficPolicy: "" |
| 518 | # -- Session affinity of the external controller service. Must be either "None" or "ClientIP" if set. Defaults to "None". |
| 519 | # Ref: https://kubernetes.io/docs/reference/networking/virtual-ips/#session-affinity |
| 520 | sessionAffinity: "" |
| 521 | # -- Specifies the health check node port (numeric port number) for the external controller service. |
| 522 | # If not specified, the service controller allocates a port from your cluster's node port range. |
| 523 | # Ref: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 524 | # healthCheckNodePort: 0 |
| 525 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 526 | # -- Represents the dual-stack capabilities of the external controller service. Possible values are SingleStack, PreferDualStack or RequireDualStack. |
| 527 | # Fields `ipFamilies` and `clusterIP` depend on the value of this field. |
| 528 | # Ref: https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services |
| 529 | ipFamilyPolicy: SingleStack |
| 530 | # -- List of IP families (e.g. IPv4, IPv6) assigned to the external controller service. This field is usually assigned automatically based on cluster configuration and the `ipFamilyPolicy` field. |
| 531 | # Ref: https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 532 | ipFamilies: |
| 533 | - IPv4 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 534 | # -- Enable the HTTP listener on both controller services or not. |
| 535 | enableHttp: true |
| 536 | # -- Enable the HTTPS listener on both controller services or not. |
| 537 | enableHttps: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 538 | ports: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 539 | # -- Port the external HTTP listener is published with. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 540 | http: 80 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 541 | # -- Port the external HTTPS listener is published with. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 542 | https: 443 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 543 | targetPorts: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 544 | # -- Port of the ingress controller the external HTTP listener is mapped to. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 545 | http: http |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 546 | # -- Port of the ingress controller the external HTTPS listener is mapped to. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 547 | https: https |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 548 | # -- Declare the app protocol of the external HTTP and HTTPS listeners or not. Supersedes provider-specific annotations for declaring the backend protocol. |
| 549 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#application-protocol |
| 550 | appProtocol: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 551 | nodePorts: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 552 | # -- Node port allocated for the external HTTP listener. If left empty, the service controller allocates one from the configured node port range. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 553 | http: "" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 554 | # -- Node port allocated for the external HTTPS listener. If left empty, the service controller allocates one from the configured node port range. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 555 | https: "" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 556 | # -- Node port mapping for external TCP listeners. If left empty, the service controller allocates them from the configured node port range. |
| 557 | # Example: |
| 558 | # tcp: |
| 559 | # 8080: 30080 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 560 | tcp: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 561 | # -- Node port mapping for external UDP listeners. If left empty, the service controller allocates them from the configured node port range. |
| 562 | # Example: |
| 563 | # udp: |
| 564 | # 53: 30053 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 565 | udp: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 566 | internal: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 567 | # -- Enable the internal controller service or not. Remember to configure `controller.service.internal.annotations` when enabling this. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 568 | enabled: false |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 569 | # -- Annotations to be added to the internal controller service. Mandatory for the internal controller service to be created. Varies with the cloud service. |
| 570 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#internal-load-balancer |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 571 | annotations: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 572 | # -- Type of the internal controller service. |
| 573 | # Defaults to the value of `controller.service.type`. |
| 574 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types |
| 575 | type: "" |
| 576 | # -- Pre-defined cluster internal IP address of the internal controller service. Take care of collisions with existing services. |
| 577 | # This value is immutable. Set once, it can not be changed without deleting and re-creating the service. |
| 578 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#choosing-your-own-ip-address |
| 579 | clusterIP: "" |
| 580 | # -- List of node IP addresses at which the internal controller service is available. |
| 581 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#external-ips |
| 582 | externalIPs: [] |
| 583 | # -- Deprecated: Pre-defined IP address of the internal controller service. Used by cloud providers to connect the resulting load balancer service to a pre-existing static IP. |
| 584 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer |
| 585 | loadBalancerIP: "" |
| 586 | # -- Restrict access to the internal controller service. Values must be CIDRs. Allows any source address by default. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 587 | loadBalancerSourceRanges: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 588 | # -- Load balancer class of the internal controller service. Used by cloud providers to select a load balancer implementation other than the cloud provider default. |
| 589 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#load-balancer-class |
| 590 | loadBalancerClass: "" |
| 591 | # -- Enable node port allocation for the internal controller service or not. Applies to type `LoadBalancer` only. |
| 592 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#load-balancer-nodeport-allocation |
| 593 | # allocateLoadBalancerNodePorts: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 594 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 595 | # -- External traffic policy of the internal controller service. Set to "Local" to preserve source IP on providers supporting it. |
| 596 | # Ref: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip |
| 597 | externalTrafficPolicy: "" |
| 598 | # -- Session affinity of the internal controller service. Must be either "None" or "ClientIP" if set. Defaults to "None". |
| 599 | # Ref: https://kubernetes.io/docs/reference/networking/virtual-ips/#session-affinity |
| 600 | sessionAffinity: "" |
| 601 | # -- Specifies the health check node port (numeric port number) for the internal controller service. |
| 602 | # If not specified, the service controller allocates a port from your cluster's node port range. |
| 603 | # Ref: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip |
| 604 | # healthCheckNodePort: 0 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 605 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 606 | # -- Represents the dual-stack capabilities of the internal controller service. Possible values are SingleStack, PreferDualStack or RequireDualStack. |
| 607 | # Fields `ipFamilies` and `clusterIP` depend on the value of this field. |
| 608 | # Ref: https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services |
| 609 | ipFamilyPolicy: SingleStack |
| 610 | # -- List of IP families (e.g. IPv4, IPv6) assigned to the internal controller service. This field is usually assigned automatically based on cluster configuration and the `ipFamilyPolicy` field. |
| 611 | # Ref: https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services |
| 612 | ipFamilies: |
| 613 | - IPv4 |
| 614 | ports: {} |
| 615 | # -- Port the internal HTTP listener is published with. |
| 616 | # Defaults to the value of `controller.service.ports.http`. |
| 617 | # http: 80 |
| 618 | # -- Port the internal HTTPS listener is published with. |
| 619 | # Defaults to the value of `controller.service.ports.https`. |
| 620 | # https: 443 |
| 621 | |
| 622 | targetPorts: {} |
| 623 | # -- Port of the ingress controller the internal HTTP listener is mapped to. |
| 624 | # Defaults to the value of `controller.service.targetPorts.http`. |
| 625 | # http: http |
| 626 | # -- Port of the ingress controller the internal HTTPS listener is mapped to. |
| 627 | # Defaults to the value of `controller.service.targetPorts.https`. |
| 628 | # https: https |
| 629 | |
| 630 | # -- Declare the app protocol of the internal HTTP and HTTPS listeners or not. Supersedes provider-specific annotations for declaring the backend protocol. |
| 631 | # Ref: https://kubernetes.io/docs/concepts/services-networking/service/#application-protocol |
| 632 | appProtocol: true |
| 633 | nodePorts: |
| 634 | # -- Node port allocated for the internal HTTP listener. If left empty, the service controller allocates one from the configured node port range. |
| 635 | http: "" |
| 636 | # -- Node port allocated for the internal HTTPS listener. If left empty, the service controller allocates one from the configured node port range. |
| 637 | https: "" |
| 638 | # -- Node port mapping for internal TCP listeners. If left empty, the service controller allocates them from the configured node port range. |
| 639 | # Example: |
| 640 | # tcp: |
| 641 | # 8080: 30080 |
| 642 | tcp: {} |
| 643 | # -- Node port mapping for internal UDP listeners. If left empty, the service controller allocates them from the configured node port range. |
| 644 | # Example: |
| 645 | # udp: |
| 646 | # 53: 30053 |
| 647 | udp: {} |
| 648 | # shareProcessNamespace enables process namespace sharing within the pod. |
| 649 | # This can be used for example to signal log rotation using `kill -USR1` from a sidecar. |
| 650 | shareProcessNamespace: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 651 | # -- Additional containers to be added to the controller pod. |
| 652 | # See https://github.com/lemonldap-ng-controller/lemonldap-ng-controller as example. |
| 653 | extraContainers: [] |
| 654 | # - name: my-sidecar |
| 655 | # image: nginx:latest |
| 656 | # - name: lemonldap-ng-controller |
| 657 | # image: lemonldapng/lemonldap-ng-controller:0.2.0 |
| 658 | # args: |
| 659 | # - /lemonldap-ng-controller |
| 660 | # - --alsologtostderr |
| 661 | # - --configmap=$(POD_NAMESPACE)/lemonldap-ng-configuration |
| 662 | # env: |
| 663 | # - name: POD_NAME |
| 664 | # valueFrom: |
| 665 | # fieldRef: |
| 666 | # fieldPath: metadata.name |
| 667 | # - name: POD_NAMESPACE |
| 668 | # valueFrom: |
| 669 | # fieldRef: |
| 670 | # fieldPath: metadata.namespace |
| 671 | # volumeMounts: |
| 672 | # - name: copy-portal-skins |
| 673 | # mountPath: /srv/var/lib/lemonldap-ng/portal/skins |
| 674 | |
| 675 | # -- Additional volumeMounts to the controller main container. |
| 676 | extraVolumeMounts: [] |
| 677 | # - name: copy-portal-skins |
| 678 | # mountPath: /var/lib/lemonldap-ng/portal/skins |
| 679 | |
| 680 | # -- Additional volumes to the controller pod. |
| 681 | extraVolumes: [] |
| 682 | # - name: copy-portal-skins |
| 683 | # emptyDir: {} |
| 684 | |
| 685 | # -- Containers, which are run before the app containers are started. |
| 686 | extraInitContainers: [] |
| 687 | # - name: init-myservice |
| 688 | # image: busybox |
| 689 | # command: ['sh', '-c', 'until nslookup myservice; do echo waiting for myservice; sleep 2; done;'] |
| 690 | |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 691 | # -- Modules, which are mounted into the core nginx image. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 692 | extraModules: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 693 | # - name: mytestmodule |
| 694 | # image: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 695 | # # registry: registry.k8s.io |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 696 | # image: ingress-nginx/mytestmodule |
| 697 | # ## for backwards compatibility consider setting the full image url via the repository value below |
| 698 | # ## use *either* current default registry/image or repository format or installing chart by providing the values.yaml will fail |
| 699 | # ## repository: |
| 700 | # tag: "v1.0.0" |
| 701 | # digest: "" |
| 702 | # distroless: false |
| 703 | # containerSecurityContext: |
| 704 | # runAsNonRoot: true |
| 705 | # runAsUser: <user-id> |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 706 | # runAsGroup: <group-id> |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 707 | # allowPrivilegeEscalation: false |
| 708 | # seccompProfile: |
| 709 | # type: RuntimeDefault |
| 710 | # capabilities: |
| 711 | # drop: |
| 712 | # - ALL |
| 713 | # readOnlyRootFilesystem: true |
| 714 | # resources: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 715 | # |
| 716 | # The image must contain a `/usr/local/bin/init_module.sh` executable, which |
| 717 | # will be executed as initContainers, to move its config files within the |
| 718 | # mounted volume. |
| 719 | |
| 720 | admissionWebhooks: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 721 | name: admission |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 722 | annotations: {} |
| 723 | # ignore-check.kube-linter.io/no-read-only-rootfs: "This deployment needs write access to root filesystem". |
| 724 | |
| 725 | ## Additional annotations to the admission webhooks. |
| 726 | ## These annotations will be added to the ValidatingWebhookConfiguration and |
| 727 | ## the Jobs Spec of the admission webhooks. |
| 728 | enabled: true |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 729 | # -- Additional environment variables to set |
| 730 | extraEnvs: [] |
| 731 | # extraEnvs: |
| 732 | # - name: FOO |
| 733 | # valueFrom: |
| 734 | # secretKeyRef: |
| 735 | # key: FOO |
| 736 | # name: secret-resource |
| 737 | # -- Admission Webhook failure policy to use |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 738 | failurePolicy: Fail |
| 739 | # timeoutSeconds: 10 |
| 740 | port: 8443 |
| 741 | certificate: "/usr/local/certificates/cert" |
| 742 | key: "/usr/local/certificates/key" |
| 743 | namespaceSelector: {} |
| 744 | objectSelector: {} |
| 745 | # -- Labels to be added to admission webhooks |
| 746 | labels: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 747 | service: |
| 748 | annotations: {} |
| 749 | # clusterIP: "" |
| 750 | externalIPs: [] |
| 751 | # loadBalancerIP: "" |
| 752 | loadBalancerSourceRanges: [] |
| 753 | servicePort: 443 |
| 754 | type: ClusterIP |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 755 | createSecretJob: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 756 | name: create |
| 757 | # -- Security context for secret creation containers |
| 758 | securityContext: |
| 759 | runAsNonRoot: true |
| 760 | runAsUser: 65532 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 761 | runAsGroup: 65532 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 762 | allowPrivilegeEscalation: false |
| 763 | seccompProfile: |
| 764 | type: RuntimeDefault |
| 765 | capabilities: |
| 766 | drop: |
| 767 | - ALL |
| 768 | readOnlyRootFilesystem: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 769 | resources: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 770 | # limits: |
| 771 | # cpu: 10m |
| 772 | # memory: 20Mi |
| 773 | # requests: |
| 774 | # cpu: 10m |
| 775 | # memory: 20Mi |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 776 | patchWebhookJob: |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 777 | name: patch |
| 778 | # -- Security context for webhook patch containers |
| 779 | securityContext: |
| 780 | runAsNonRoot: true |
| 781 | runAsUser: 65532 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 782 | runAsGroup: 65532 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 783 | allowPrivilegeEscalation: false |
| 784 | seccompProfile: |
| 785 | type: RuntimeDefault |
| 786 | capabilities: |
| 787 | drop: |
| 788 | - ALL |
| 789 | readOnlyRootFilesystem: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 790 | resources: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 791 | patch: |
| 792 | enabled: true |
| 793 | image: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 794 | # registry: registry.k8s.io |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 795 | image: ingress-nginx/kube-webhook-certgen |
| 796 | ## for backwards compatibility consider setting the full image url via the repository value below |
| 797 | ## use *either* current default registry/image or repository format or installing chart by providing the values.yaml will fail |
| 798 | ## repository: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 799 | tag: v1.5.2 |
| 800 | digest: sha256:e8825994b7a2c7497375a9b945f386506ca6a3eda80b89b74ef2db743f66a5ea |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 801 | pullPolicy: IfNotPresent |
| 802 | # -- Provide a priority class name to the webhook patching job |
| 803 | ## |
| 804 | priorityClassName: "" |
| 805 | podAnnotations: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 806 | # NetworkPolicy for webhook patch |
| 807 | networkPolicy: |
| 808 | # -- Enable 'networkPolicy' or not |
| 809 | enabled: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 810 | nodeSelector: |
| 811 | kubernetes.io/os: linux |
| 812 | tolerations: [] |
| 813 | # -- Labels to be added to patch job resources |
| 814 | labels: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 815 | # -- Security context for secret creation & webhook patch pods |
| 816 | securityContext: {} |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 817 | # -- Admission webhook patch job RBAC |
| 818 | rbac: |
| 819 | # -- Create RBAC or not |
| 820 | create: true |
| 821 | # -- Admission webhook patch job service account |
| 822 | serviceAccount: |
| 823 | # -- Create a service account or not |
| 824 | create: true |
| 825 | # -- Custom service account name |
| 826 | name: "" |
| 827 | # -- Auto-mount service account token or not |
| 828 | automountServiceAccountToken: true |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 829 | # Use certmanager to generate webhook certs |
| 830 | certManager: |
| 831 | enabled: false |
| 832 | # self-signed root certificate |
| 833 | rootCert: |
| 834 | # default to be 5y |
| 835 | duration: "" |
| 836 | admissionCert: |
| 837 | # default to be 1y |
| 838 | duration: "" |
| 839 | # issuerRef: |
| 840 | # name: "issuer" |
| 841 | # kind: "ClusterIssuer" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 842 | metrics: |
| 843 | port: 10254 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 844 | portName: metrics |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 845 | # if this port is changed, change healthz-port: in extraArgs: accordingly |
| 846 | enabled: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 847 | service: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 848 | # -- Enable the metrics service or not. |
| 849 | enabled: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 850 | annotations: {} |
| 851 | # prometheus.io/scrape: "true" |
| 852 | # prometheus.io/port: "10254" |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 853 | # -- Labels to be added to the metrics service resource |
| 854 | labels: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 855 | # clusterIP: "" |
| 856 | |
| 857 | # -- List of IP addresses at which the stats-exporter service is available |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 858 | ## Ref: https://kubernetes.io/docs/concepts/services-networking/service/#external-ips |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 859 | ## |
| 860 | externalIPs: [] |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 861 | # loadBalancerIP: "" |
| 862 | loadBalancerSourceRanges: [] |
| 863 | servicePort: 10254 |
| 864 | type: ClusterIP |
| 865 | # externalTrafficPolicy: "" |
| 866 | # nodePort: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 867 | serviceMonitor: |
| 868 | enabled: false |
| 869 | additionalLabels: {} |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 870 | # -- Annotations to be added to the ServiceMonitor. |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 871 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 872 | ## The label to use to retrieve the job name from. |
| 873 | ## jobLabel: "app.kubernetes.io/name" |
| 874 | namespace: "" |
| 875 | namespaceSelector: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 876 | ## Default: scrape .Release.Namespace or namespaceOverride only |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 877 | ## To scrape all, use the following: |
| 878 | ## namespaceSelector: |
| 879 | ## any: true |
| 880 | scrapeInterval: 30s |
| 881 | # honorLabels: true |
| 882 | targetLabels: [] |
| 883 | relabelings: [] |
| 884 | metricRelabelings: [] |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 885 | prometheusRule: |
| 886 | enabled: false |
| 887 | additionalLabels: {} |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 888 | # -- Annotations to be added to the PrometheusRule. |
| 889 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 890 | # namespace: "" |
| 891 | rules: [] |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 892 | # # These are just examples rules, please adapt them to your needs |
| 893 | # - alert: NGINXConfigFailed |
| 894 | # expr: count(nginx_ingress_controller_config_last_reload_successful == 0) > 0 |
| 895 | # for: 1s |
| 896 | # labels: |
| 897 | # severity: critical |
| 898 | # annotations: |
| 899 | # description: bad ingress config - nginx config test failed |
| 900 | # summary: uninstall the latest ingress changes to allow config reloads to resume |
| 901 | # # By default a fake self-signed certificate is generated as default and |
| 902 | # # it is fine if it expires. If `--default-ssl-certificate` flag is used |
| 903 | # # and a valid certificate passed please do not filter for `host` label! |
| 904 | # # (i.e. delete `{host!="_"}` so also the default SSL certificate is |
| 905 | # # checked for expiration) |
| 906 | # - alert: NGINXCertificateExpiry |
| 907 | # expr: (avg(nginx_ingress_controller_ssl_expire_time_seconds{host!="_"}) by (host) - time()) < 604800 |
| 908 | # for: 1s |
| 909 | # labels: |
| 910 | # severity: critical |
| 911 | # annotations: |
| 912 | # description: ssl certificate(s) will expire in less then a week |
| 913 | # summary: renew expiring certificates to avoid downtime |
| 914 | # - alert: NGINXTooMany500s |
| 915 | # expr: 100 * ( sum( nginx_ingress_controller_requests{status=~"5.+"} ) / sum(nginx_ingress_controller_requests) ) > 5 |
| 916 | # for: 1m |
| 917 | # labels: |
| 918 | # severity: warning |
| 919 | # annotations: |
| 920 | # description: Too many 5XXs |
| 921 | # summary: More than 5% of all requests returned 5XX, this requires your attention |
| 922 | # - alert: NGINXTooMany400s |
| 923 | # expr: 100 * ( sum( nginx_ingress_controller_requests{status=~"4.+"} ) / sum(nginx_ingress_controller_requests) ) > 5 |
| 924 | # for: 1m |
| 925 | # labels: |
| 926 | # severity: warning |
| 927 | # annotations: |
| 928 | # description: Too many 4XXs |
| 929 | # summary: More than 5% of all requests returned 4XX, this requires your attention |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 930 | # -- Improve connection draining when ingress controller pod is deleted using a lifecycle hook: |
| 931 | # With this new hook, we increased the default terminationGracePeriodSeconds from 30 seconds |
| 932 | # to 300, allowing the draining of connections up to five minutes. |
| 933 | # If the active connections end before that, the pod will terminate gracefully at that time. |
| 934 | # To effectively take advantage of this feature, the Configmap feature |
| 935 | # worker-shutdown-timeout new value is 240s instead of 10s. |
| 936 | ## |
| 937 | lifecycle: |
| 938 | preStop: |
| 939 | exec: |
| 940 | command: |
| 941 | - /wait-shutdown |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 942 | priorityClassName: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 943 | # -- Rollback limit |
| 944 | ## |
| 945 | revisionHistoryLimit: 10 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 946 | ## Default 404 backend |
| 947 | ## |
| 948 | defaultBackend: |
| 949 | ## |
| 950 | enabled: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 951 | name: defaultbackend |
| 952 | image: |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 953 | # registry: registry.k8s.io |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 954 | image: defaultbackend-amd64 |
| 955 | ## for backwards compatibility consider setting the full image url via the repository value below |
| 956 | ## use *either* current default registry/image or repository format or installing chart by providing the values.yaml will fail |
| 957 | ## repository: |
| 958 | tag: "1.5" |
| 959 | pullPolicy: IfNotPresent |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 960 | runAsNonRoot: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 961 | # nobody user -> uid 65534 |
| 962 | runAsUser: 65534 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 963 | runAsGroup: 65534 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 964 | allowPrivilegeEscalation: false |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 965 | seccompProfile: |
| 966 | type: RuntimeDefault |
| 967 | readOnlyRootFilesystem: true |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 968 | extraArgs: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 969 | serviceAccount: |
| 970 | create: true |
| 971 | name: "" |
| 972 | automountServiceAccountToken: true |
| 973 | # -- Additional environment variables to set for defaultBackend pods |
| 974 | extraEnvs: [] |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 975 | port: 8080 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 976 | ## Readiness and liveness probes for default backend |
| 977 | ## Ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/ |
| 978 | ## |
| 979 | livenessProbe: |
| 980 | failureThreshold: 3 |
| 981 | initialDelaySeconds: 30 |
| 982 | periodSeconds: 10 |
| 983 | successThreshold: 1 |
| 984 | timeoutSeconds: 5 |
| 985 | readinessProbe: |
| 986 | failureThreshold: 6 |
| 987 | initialDelaySeconds: 0 |
| 988 | periodSeconds: 5 |
| 989 | successThreshold: 1 |
| 990 | timeoutSeconds: 5 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 991 | # -- The update strategy to apply to the Deployment or DaemonSet |
| 992 | ## |
| 993 | updateStrategy: {} |
| 994 | # rollingUpdate: |
| 995 | # maxUnavailable: 1 |
| 996 | # type: RollingUpdate |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 997 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 998 | # -- `minReadySeconds` to avoid killing pods before we are ready |
| 999 | ## |
| 1000 | minReadySeconds: 0 |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1001 | # -- Node tolerations for server scheduling to nodes with taints |
| 1002 | ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ |
| 1003 | ## |
| 1004 | tolerations: [] |
| 1005 | # - key: "key" |
| 1006 | # operator: "Equal|Exists" |
| 1007 | # value: "value" |
| 1008 | # effect: "NoSchedule|PreferNoSchedule|NoExecute(1.6 only)" |
| 1009 | |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 1010 | # -- Affinity and anti-affinity rules for server scheduling to nodes |
| 1011 | ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1012 | affinity: {} |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 1013 | # # An example of preferred pod anti-affinity, weight is in the range 1-100 |
| 1014 | # podAntiAffinity: |
| 1015 | # preferredDuringSchedulingIgnoredDuringExecution: |
| 1016 | # - weight: 100 |
| 1017 | # podAffinityTerm: |
| 1018 | # labelSelector: |
| 1019 | # matchExpressions: |
| 1020 | # - key: app.kubernetes.io/name |
| 1021 | # operator: In |
| 1022 | # values: |
| 1023 | # - '{{ include "ingress-nginx.name" . }}' |
| 1024 | # - key: app.kubernetes.io/instance |
| 1025 | # operator: In |
| 1026 | # values: |
| 1027 | # - '{{ .Release.Name }}' |
| 1028 | # - key: app.kubernetes.io/component |
| 1029 | # operator: In |
| 1030 | # values: |
| 1031 | # - default-backend |
| 1032 | # topologyKey: kubernetes.io/hostname |
| 1033 | |
| 1034 | # # An example of required pod anti-affinity |
| 1035 | # podAntiAffinity: |
| 1036 | # requiredDuringSchedulingIgnoredDuringExecution: |
| 1037 | # - labelSelector: |
| 1038 | # matchExpressions: |
| 1039 | # - key: app.kubernetes.io/name |
| 1040 | # operator: In |
| 1041 | # values: |
| 1042 | # - '{{ include "ingress-nginx.name" . }}' |
| 1043 | # - key: app.kubernetes.io/instance |
| 1044 | # operator: In |
| 1045 | # values: |
| 1046 | # - '{{ .Release.Name }}' |
| 1047 | # - key: app.kubernetes.io/component |
| 1048 | # operator: In |
| 1049 | # values: |
| 1050 | # - default-backend |
| 1051 | # topologyKey: kubernetes.io/hostname |
| 1052 | |
| 1053 | # -- Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in. |
| 1054 | # Ref.: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/ |
| 1055 | topologySpreadConstraints: [] |
| 1056 | # - labelSelector: |
| 1057 | # matchLabels: |
| 1058 | # app.kubernetes.io/name: '{{ include "ingress-nginx.name" . }}' |
| 1059 | # app.kubernetes.io/instance: '{{ .Release.Name }}' |
| 1060 | # app.kubernetes.io/component: default-backend |
| 1061 | # matchLabelKeys: |
| 1062 | # - pod-template-hash |
| 1063 | # topologyKey: topology.kubernetes.io/zone |
| 1064 | # maxSkew: 1 |
| 1065 | # whenUnsatisfiable: ScheduleAnyway |
| 1066 | # - labelSelector: |
| 1067 | # matchLabels: |
| 1068 | # app.kubernetes.io/name: '{{ include "ingress-nginx.name" . }}' |
| 1069 | # app.kubernetes.io/instance: '{{ .Release.Name }}' |
| 1070 | # app.kubernetes.io/component: default-backend |
| 1071 | # matchLabelKeys: |
| 1072 | # - pod-template-hash |
| 1073 | # topologyKey: kubernetes.io/hostname |
| 1074 | # maxSkew: 1 |
| 1075 | # whenUnsatisfiable: ScheduleAnyway |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1076 | # -- Security context for default backend pods |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1077 | podSecurityContext: {} |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1078 | # -- Security context for default backend containers |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1079 | containerSecurityContext: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1080 | # -- Labels to add to the pod container metadata |
| 1081 | podLabels: {} |
| 1082 | # key: value |
| 1083 | |
| 1084 | # -- Node labels for default backend pod assignment |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1085 | ## Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1086 | ## |
| 1087 | nodeSelector: |
| 1088 | kubernetes.io/os: linux |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1089 | # -- Annotations to be added to default backend pods |
| 1090 | ## |
| 1091 | podAnnotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1092 | replicaCount: 1 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 1093 | # -- Minimum available pods set in PodDisruptionBudget. |
| 1094 | # Define either 'minAvailable' or 'maxUnavailable', never both. |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1095 | minAvailable: 1 |
Yaguang Tang | 806de73 | 2025-03-25 14:24:29 +0800 | [diff] [blame^] | 1096 | # -- Maximum unavailable pods set in PodDisruptionBudget. If set, 'minAvailable' is ignored. |
| 1097 | # maxUnavailable: 1 |
| 1098 | # -- Eviction policy for unhealthy pods guarded by PodDisruptionBudget. |
| 1099 | # Ref: https://kubernetes.io/blog/2023/01/06/unhealthy-pod-eviction-policy-for-pdbs/ |
| 1100 | unhealthyPodEvictionPolicy: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1101 | resources: {} |
| 1102 | # limits: |
| 1103 | # cpu: 10m |
| 1104 | # memory: 20Mi |
| 1105 | # requests: |
| 1106 | # cpu: 10m |
| 1107 | # memory: 20Mi |
| 1108 | |
| 1109 | extraVolumeMounts: [] |
| 1110 | ## Additional volumeMounts to the default backend container. |
| 1111 | # - name: copy-portal-skins |
| 1112 | # mountPath: /var/lib/lemonldap-ng/portal/skins |
| 1113 | |
| 1114 | extraVolumes: [] |
| 1115 | ## Additional volumes to the default backend pod. |
| 1116 | # - name: copy-portal-skins |
| 1117 | # emptyDir: {} |
| 1118 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1119 | extraConfigMaps: [] |
| 1120 | ## Additional configmaps to the default backend pod. |
| 1121 | # - name: my-extra-configmap-1 |
| 1122 | # labels: |
| 1123 | # type: config-1 |
| 1124 | # data: |
| 1125 | # extra_file_1.html: | |
| 1126 | # <!-- Extra HTML content for ConfigMap 1 --> |
| 1127 | # - name: my-extra-configmap-2 |
| 1128 | # labels: |
| 1129 | # type: config-2 |
| 1130 | # data: |
| 1131 | # extra_file_2.html: | |
| 1132 | # <!-- Extra HTML content for ConfigMap 2 --> |
| 1133 | |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1134 | autoscaling: |
| 1135 | annotations: {} |
| 1136 | enabled: false |
| 1137 | minReplicas: 1 |
| 1138 | maxReplicas: 2 |
| 1139 | targetCPUUtilizationPercentage: 50 |
| 1140 | targetMemoryUtilizationPercentage: 50 |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1141 | # NetworkPolicy for default backend component. |
| 1142 | networkPolicy: |
| 1143 | # -- Enable 'networkPolicy' or not |
| 1144 | enabled: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1145 | service: |
| 1146 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1147 | # clusterIP: "" |
| 1148 | |
| 1149 | # -- List of IP addresses at which the default backend service is available |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1150 | ## Ref: https://kubernetes.io/docs/concepts/services-networking/service/#external-ips |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1151 | ## |
| 1152 | externalIPs: [] |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1153 | # loadBalancerIP: "" |
| 1154 | loadBalancerSourceRanges: [] |
| 1155 | servicePort: 80 |
| 1156 | type: ClusterIP |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1157 | priorityClassName: "" |
| 1158 | # -- Labels to be added to the default backend resources |
| 1159 | labels: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1160 | ## Enable RBAC as per https://github.com/kubernetes/ingress-nginx/blob/main/docs/deploy/rbac.md and https://github.com/kubernetes/ingress-nginx/issues/266 |
| 1161 | rbac: |
| 1162 | create: true |
| 1163 | scope: false |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1164 | serviceAccount: |
| 1165 | create: true |
| 1166 | name: "" |
| 1167 | automountServiceAccountToken: true |
| 1168 | # -- Annotations for the controller service account |
| 1169 | annotations: {} |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1170 | # -- Optional array of imagePullSecrets containing private registry credentials |
| 1171 | ## Ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ |
| 1172 | imagePullSecrets: [] |
| 1173 | # - name: secretName |
| 1174 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1175 | # -- TCP service key-value pairs |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1176 | ## Ref: https://github.com/kubernetes/ingress-nginx/blob/main/docs/user-guide/exposing-tcp-udp-services.md |
| 1177 | ## |
| 1178 | tcp: {} |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 1179 | # "8080": "default/example-tcp-svc:9000" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1180 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1181 | # -- UDP service key-value pairs |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1182 | ## Ref: https://github.com/kubernetes/ingress-nginx/blob/main/docs/user-guide/exposing-tcp-udp-services.md |
| 1183 | ## |
| 1184 | udp: {} |
Mohammed Naser | 7d1623e | 2024-06-17 09:12:39 -0400 | [diff] [blame] | 1185 | # "53": "kube-system/kube-dns:53" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1186 | |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1187 | # -- Prefix for TCP and UDP ports names in ingress controller service |
| 1188 | ## Some cloud providers, like Yandex Cloud may have a requirements for a port name regex to support cloud load balancer integration |
| 1189 | portNamePrefix: "" |
Mohammed Naser | 9ad0d46 | 2023-01-15 20:36:37 -0500 | [diff] [blame] | 1190 | # -- (string) A base64-encoded Diffie-Hellman parameter. |
| 1191 | # This can be generated with: `openssl dhparam 4096 2> /dev/null | base64` |
| 1192 | ## Ref: https://github.com/kubernetes/ingress-nginx/tree/main/docs/examples/customization/ssl-dh-param |
Mohammed Naser | 65cda13 | 2024-05-02 14:34:08 -0400 | [diff] [blame] | 1193 | dhParam: "" |