Skip to content

Commit

Permalink
feat: support adding labels to APISIX Pods (#730)
Browse files Browse the repository at this point in the history
  • Loading branch information
fabio-viana authored Mar 20, 2024
1 parent a6aa358 commit a9a2ecb
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions charts/apisix/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ The command removes all the Kubernetes components associated with the chart and
| apisix.podDisruptionBudget.enabled | bool | `false` | Enable or disable podDisruptionBudget |
| apisix.podDisruptionBudget.maxUnavailable | int | `1` | Set the maxUnavailable of podDisruptionBudget |
| apisix.podDisruptionBudget.minAvailable | string | `"90%"` | Set the `minAvailable` of podDisruptionBudget. You can specify only one of `maxUnavailable` and `minAvailable` in a single PodDisruptionBudget. See [Specifying a Disruption Budget for your Application](https://kubernetes.io/docs/tasks/run-application/configure-pdb/#specifying-a-poddisruptionbudget) for more details |
| apisix.podLabels | object | `{}` | Labels to add to each pod |
| apisix.podSecurityContext | object | `{}` | Set the securityContext for Apache APISIX pods |
| apisix.priorityClassName | string | `""` | Set [priorityClassName](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#pod-priority) for Apache APISIX pods |
| apisix.proxyProtocol | object | `{"enabled":false,"listenHttpPort":9181,"listenHttpsPort":9182,"tcp":true,"upstream":true}` | Enable Proxy Protocol |
Expand Down
3 changes: 3 additions & 0 deletions charts/apisix/templates/_pod.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ metadata:
{{- end }}
labels:
{{- include "apisix.selectorLabels" . | nindent 4 }}
{{- with .Values.apisix.podLabels }}
{{ tpl (toYaml .) $ | nindent 4}}
{{- end }}
spec:
{{- with .Values.global.imagePullSecrets }}
imagePullSecrets:
Expand Down
2 changes: 2 additions & 0 deletions charts/apisix/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ apisix:
priorityClassName: ""
# -- Annotations to add to each pod
podAnnotations: {}
# -- Labels to add to each pod
podLabels: {}
# -- Set the securityContext for Apache APISIX pods
podSecurityContext: {}
# fsGroup: 2000
Expand Down

0 comments on commit a9a2ecb

Please sign in to comment.