Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Support pod priorityClassName #181

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/bindplane/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: bindplane
description: BindPlane OP is an observability pipeline.
type: application
# The chart's version
version: 1.20.8
version: 1.20.9
# The BindPlane OP tagged release. If the user does not
# set the `image.tag` values option, this version is used.
appVersion: 1.82.0
Expand Down
34 changes: 20 additions & 14 deletions charts/bindplane/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# bindplane

![Version: 1.20.8](https://img.shields.io/badge/Version-1.20.8-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.82.0](https://img.shields.io/badge/AppVersion-1.82.0-informational?style=flat-square)
![Version: 1.20.9](https://img.shields.io/badge/Version-1.20.9-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.82.0](https://img.shields.io/badge/AppVersion-1.82.0-informational?style=flat-square)

BindPlane OP is an observability pipeline.

Expand All @@ -19,10 +19,10 @@ BindPlane OP is an observability pipeline.
|-----|------|---------|-------------|
| affinity | object | `{"bindplane":{},"jobs":{},"nats":{},"prometheus":{},"transform_agent":{}}` | Configure the affinity for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods. |
| affinity.bindplane | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane deployment pods. |
| affinity.jobs | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane Jobs pod. The jobs pod is a single pod deployment. |
| affinity.nats | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane NATS statefulset pods, if NATS is enabled. |
| affinity.prometheus | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane Prometheus pod. The Prometheus pod is a single pod deployment. |
| affinity.transform_agent | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane transform agent pod. The transform agent pod is a single pod deployment. |
| affinity.jobs | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane Jobs pod. |
| affinity.nats | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane NATS statefulset or deployment pods, if NATS is enabled. |
| affinity.prometheus | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane Prometheus pod. |
| affinity.transform_agent | object | `{}` | This is for configuring spec.template.spec.affinity on the BindPlane transform agent pod. |
| auth.google.clientid | string | `""` | Google OAUTH clientid |
| auth.ldap.baseDN | string | `""` | Base DN to use when looking up users. Example: `ou=users,dc=stage,dc=net`. |
| auth.ldap.bindCredentialSecret.name | string | `""` | Kubernetes secret name that contains the bind username and password. |
Expand Down Expand Up @@ -117,12 +117,18 @@ BindPlane OP is an observability pipeline.
| nats.resources.requests.cpu | string | `"1000m"` | CPU request for the NATs server pods, when event bus type is `nats`. |
| nats.resources.requests.memory | string | `"1000Mi"` | Memory request for the NATs server pods, when event bus type is `nats`. |
| nodeSelector | object | `{"bindplane":{},"jobs":{},"nats":{},"prometheus":{},"transform_agent":{}}` | Configure the nodeSelector for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods. |
| nodeSelector.bindplane | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane deployment pods when using the bbolt backend. |
| nodeSelector.jobs | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane Jobs pod. The jobs pod is a single pod deployment. |
| nodeSelector.nats | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane NATS statefulset pods, if NATS is enabled. |
| nodeSelector.prometheus | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane Prometheus pod. The Prometheus pod is a single pod deployment. |
| nodeSelector.transform_agent | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane transform agent pod. The transform agent pod is a single pod deployment. |
| nodeSelector.bindplane | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane deployment pod when using the bbolt backend. |
| nodeSelector.jobs | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane Jobs pod. |
| nodeSelector.nats | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane NATS statefulset or deployment pods, if NATS is enabled. |
| nodeSelector.prometheus | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane Prometheus pod. |
| nodeSelector.transform_agent | object | `{}` | This is for configuring spec.template.spec.nodeSelector on the BindPlane transform agent pod. |
| podSecurityContext | object | `{"fsGroup":65534}` | The Pod spec's securityContext: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod. |
| priorityClassName | object | `{"bindplane":"","jobs":"","nats":"","prometheus":"","transform_agent":""}` | Configure the priorityClassName for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods. |
| priorityClassName.bindplane | string | `""` | This is for configuring spec.template.spec.priorityClassName on the BindPlane deployment pods. |
| priorityClassName.jobs | string | `""` | This is for configuring spec.template.spec.priorityClassName on the BindPlane Jobs pod. |
| priorityClassName.nats | string | `""` | This is for configuring spec.template.spec.priorityClassName on the BindPlane NATS statefulset or deployment pods, if NATS is enabled. |
| priorityClassName.prometheus | string | `""` | This is for configuring spec.template.spec.priorityClassName on the BindPlane Prometheus pod. |
| priorityClassName.transform_agent | string | `""` | This is for configuring spec.template.spec.priorityClassName on the BindPlane transform agent pod. |
| prometheus.auth.password | string | `""` | Prometheus basic authentication password. |
| prometheus.auth.type | string | `"none"` | Prometheus authentication. Supported options include `none` and `basic`. |
| prometheus.auth.username | string | `""` | Prometheus basic authentication username. |
Expand Down Expand Up @@ -156,10 +162,10 @@ BindPlane OP is an observability pipeline.
| service.annotations | object | `{}` | Custom annotations which will be added to the service object. Useful for specifying things such as `cloud.google.com/backend-config`. |
| tolerations | object | `{}` | The Pod's tolerations |
| topologySpreadConstraints.bindplane | list | `[]` | spec.template.spec.topologySpreadConstraints on the BindPlane deployment pods. |
| topologySpreadConstraints.jobs | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Jobs pod. The jobs pod is a single pod deployment. |
| topologySpreadConstraints.nats | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane NATS statefulset pods, if NATS is enabled. |
| topologySpreadConstraints.prometheus | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Prometheus pod. The Prometheus pod is a single pod deployment. |
| topologySpreadConstraints.transform_agent | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane transform agent pod. The transform agent pod is a single pod deployment. |
| topologySpreadConstraints.jobs | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Jobs pod. |
| topologySpreadConstraints.nats | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane NATS statefulset or deployment pods, if NATS is enabled. |
| topologySpreadConstraints.prometheus | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Prometheus pod. |
| topologySpreadConstraints.transform_agent | list | `[]` | This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane transform agent pod. |
| trace.otlp.endpoint | string | `""` | Endpoint of the OTLP gRPC trace receiver. Should be in the form of ip:port or host:port. |
| trace.otlp.insecure | bool | `false` | Set to `true` to disable TLS. Set to false if TLS is in use by the OTLP trace receiver. |
| trace.otlp.samplingRate | string | `"1"` | Sampling rate between 0 and 1. 1 being 100% of traces are sent. |
Expand Down
1 change: 1 addition & 0 deletions charts/bindplane/templates/bindplane-jobs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ spec:
{{- toYaml .Values.extraPodLabels | nindent 8 }}
{{- end }}
spec:
priorityClassName: {{ .Values.priorityClassName.jobs }}
serviceAccountName: {{ include "bindplane.fullname" . }}
{{- with .Values.podSecurityContext }}
securityContext:
Expand Down
1 change: 1 addition & 0 deletions charts/bindplane/templates/bindplane-nats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ spec:
{{- toYaml .Values.extraPodLabels | nindent 8 }}
{{- end }}
spec:
priorityClassName: {{ .Values.priorityClassName.nats }}
serviceAccountName: {{ include "bindplane.fullname" . }}
{{- with .Values.podSecurityContext }}
securityContext:
Expand Down
1 change: 1 addition & 0 deletions charts/bindplane/templates/bindplane.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ spec:
{{- toYaml .Values.extraPodLabels | nindent 8 }}
{{- end }}
spec:
priorityClassName: {{ .Values.priorityClassName.bindplane }}
{{- if and (eq .Values.backend.type "bbolt") (.Values.nodeSelector.bindplane) }}
nodeSelector:
{{- toYaml .Values.nodeSelector.bindplane | nindent 8 }}
Expand Down
1 change: 1 addition & 0 deletions charts/bindplane/templates/prometheus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ spec:
{{- toYaml .Values.prometheus.extraPodLabels | nindent 8 }}
{{- end }}
spec:
priorityClassName: {{ .Values.priorityClassName.prometheus }}
securityContext:
fsGroup: 65534
{{- with .Values.prometheus.tolerations }}
Expand Down
1 change: 1 addition & 0 deletions charts/bindplane/templates/transform-agent.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ spec:
app.kubernetes.io/component: transform-agent
app.kubernetes.io/instance: {{ .Release.Name }}
spec:
priorityClassName: {{ .Values.priorityClassName.transform_agent }}
{{- if .Values.nodeSelector.transform_agent }}
nodeSelector:
{{- toYaml .Values.nodeSelector.transform_agent | nindent 8 }}
Expand Down
31 changes: 18 additions & 13 deletions charts/bindplane/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -431,54 +431,59 @@ metrics:
# -- Number of replicas to use for the BindPlane server. Should not be set if `autoscaling.enable` is set to `true`. 0 means this option will not be set.
replicas: 0

# -- Configure the priorityClassName for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods.
priorityClassName:
# -- This is for configuring spec.template.spec.priorityClassName on the BindPlane deployment pods.
bindplane: ""
# -- This is for configuring spec.template.spec.priorityClassName on the BindPlane NATS statefulset or deployment
# pods, if NATS is enabled.
nats: ""
# -- This is for configuring spec.template.spec.priorityClassName on the BindPlane Jobs pod.
jobs: ""
# -- This is for configuring spec.template.spec.priorityClassName on the BindPlane Prometheus pod.
prometheus: ""
# -- This is for configuring spec.template.spec.priorityClassName on the BindPlane transform agent pod.
transform_agent: ""

# -- Configure the nodeSelector for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods.
nodeSelector:
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane deployment pods when using the bbolt backend.
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane deployment pod when using the bbolt backend.
bindplane: {}
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane NATS statefulset
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane NATS statefulset or deployment
# pods, if NATS is enabled.
nats: {}
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane Jobs pod.
# The jobs pod is a single pod deployment.
jobs: {}
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane Prometheus pod.
# The Prometheus pod is a single pod deployment.
prometheus: {}
# -- This is for configuring spec.template.spec.nodeSelector on the BindPlane transform agent pod.
# The transform agent pod is a single pod deployment.
transform_agent: {}

# -- Configure the affinity for BindPlane, BindPlane NATS, BindPlane Jobs, and BindPlane Prometheus pods.
affinity:
# -- This is for configuring spec.template.spec.affinity on the BindPlane deployment pods.
bindplane: {}
# -- This is for configuring spec.template.spec.affinity on the BindPlane NATS statefulset
# -- This is for configuring spec.template.spec.affinity on the BindPlane NATS statefulset or deployment
# pods, if NATS is enabled.
nats: {}
# -- This is for configuring spec.template.spec.affinity on the BindPlane Jobs pod.
# The jobs pod is a single pod deployment.
jobs: {}
# -- This is for configuring spec.template.spec.affinity on the BindPlane Prometheus pod.
# The Prometheus pod is a single pod deployment.
prometheus: {}
# -- This is for configuring spec.template.spec.affinity on the BindPlane transform agent pod.
# The transform agent pod is a single pod deployment.
transform_agent: {}

topologySpreadConstraints:
# -- spec.template.spec.topologySpreadConstraints on the BindPlane deployment pods.
bindplane: []
# -- This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane NATS statefulset
# -- This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane NATS statefulset or deployment
# pods, if NATS is enabled.
nats: []
# -- This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Jobs pod.
# The jobs pod is a single pod deployment.
jobs: []
# -- This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane Prometheus pod.
# The Prometheus pod is a single pod deployment.
prometheus: []
# -- This is for configuring spec.template.spec.topologySpreadConstraints on the BindPlane transform agent pod.
# The transform agent pod is a single pod deployment.
transform_agent: []

autoscaling:
Expand Down
7 changes: 7 additions & 0 deletions test/cases/all/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,3 +172,10 @@ nodeSelector:
kubernetes.io/hostname: minikube
transform_agent:
kubernetes.io/hostname: minikube

priorityClassName:
bindplane: "high-priority"
nats: "high-priority"
jobs: "high-priority"
prometheus: "high-priority"
transform_agent: "high-priority"
Loading