Skip to content

Commit

Permalink
feat(admission controller): Add new webhook settings (#1564)
Browse files Browse the repository at this point in the history
Signed-off-by: Wassim DHIF <[email protected]>
  • Loading branch information
wdhif authored Nov 13, 2024
1 parent 995a087 commit 81548e0
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 2 deletions.
4 changes: 4 additions & 0 deletions charts/datadog/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Datadog changelog

## 3.80.0

* Add `datadog.admissionController.validation` and `datadog.admissionController.mutation` to enable/disable the admission controller validation and mutation webhooks.

## 3.79.1

* Document how to use `datadog.envDict` option with the `--set` helm's flag.
Expand Down
2 changes: 1 addition & 1 deletion charts/datadog/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v1
name: datadog
version: 3.79.1
version: 3.80.0
appVersion: "7"
description: Datadog Agent
keywords:
Expand Down
6 changes: 5 additions & 1 deletion charts/datadog/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Datadog

![Version: 3.79.1](https://img.shields.io/badge/Version-3.79.1-informational?style=flat-square) ![AppVersion: 7](https://img.shields.io/badge/AppVersion-7-informational?style=flat-square)
![Version: 3.80.0](https://img.shields.io/badge/Version-3.80.0-informational?style=flat-square) ![AppVersion: 7](https://img.shields.io/badge/AppVersion-7-informational?style=flat-square)

[Datadog](https://www.datadoghq.com/) is a hosted infrastructure monitoring platform. This chart adds the Datadog Agent to all nodes in your cluster via a DaemonSet. It also optionally depends on the [kube-state-metrics chart](https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-state-metrics). For more information about monitoring Kubernetes with Datadog, please refer to the [Datadog documentation website](https://docs.datadoghq.com/agent/basic_agent_usage/kubernetes/).

Expand Down Expand Up @@ -574,8 +574,12 @@ helm install <RELEASE_NAME> \
| clusterAgent.admissionController.enabled | bool | `true` | Enable the admissionController to be able to inject APM/Dogstatsd config and standard tags (env, service, version) automatically into your pods |
| clusterAgent.admissionController.failurePolicy | string | `"Ignore"` | Set the failure policy for dynamic admission control.' |
| clusterAgent.admissionController.mutateUnlabelled | bool | `false` | Enable injecting config without having the pod label 'admission.datadoghq.com/enabled="true"' |
| clusterAgent.admissionController.mutation | object | `{"enabled":true}` | Mutation Webhook configuration options |
| clusterAgent.admissionController.mutation.enabled | bool | `true` | Enabled enables the Admission Controller mutation webhook. Default: true. (Requires Agent 7.59.0+). |
| clusterAgent.admissionController.port | int | `8000` | Set port of cluster-agent admission controller service |
| clusterAgent.admissionController.remoteInstrumentation.enabled | bool | `false` | Enable polling and applying library injection using Remote Config. # This feature is in beta, and enables Remote Config in the Cluster Agent. It also requires Cluster Agent version 7.43+. # Enabling this feature grants the Cluster Agent the permissions to patch Deployment objects in the cluster. |
| clusterAgent.admissionController.validation | object | `{"enabled":true}` | Validation Webhook configuration options |
| clusterAgent.admissionController.validation.enabled | bool | `true` | Enabled enables the Admission Controller validation webhook. Default: true. (Requires Agent 7.59.0+). |
| clusterAgent.admissionController.webhookName | string | `"datadog-webhook"` | Name of the validatingwebhookconfiguration and mutatingwebhookconfiguration created by the cluster-agent |
| clusterAgent.advancedConfd | object | `{}` | Provide additional cluster check configurations. Each key is an integration containing several config files. |
| clusterAgent.affinity | object | `{}` | Allow the Cluster Agent Deployment to schedule using affinity rules |
Expand Down
4 changes: 4 additions & 0 deletions charts/datadog/templates/cluster-agent-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,10 @@ spec:
{{- if .Values.clusterAgent.admissionController.enabled }}
- name: DD_ADMISSION_CONTROLLER_ENABLED
value: {{ .Values.clusterAgent.admissionController.enabled | quote }}
- name: DD_ADMISSION_CONTROLLER_VALIDATION_ENABLED
value: {{ .Values.clusterAgent.admissionController.validation.enabled | quote }}
- name: DD_ADMISSION_CONTROLLER_MUTATION_ENABLED
value: {{ .Values.clusterAgent.admissionController.mutation.enabled | quote }}
- name: DD_ADMISSION_CONTROLLER_WEBHOOK_NAME
value: {{ .Values.clusterAgent.admissionController.webhookName | quote }}
- name: DD_ADMISSION_CONTROLLER_MUTATE_UNLABELLED
Expand Down
10 changes: 10 additions & 0 deletions charts/datadog/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1147,6 +1147,16 @@ clusterAgent:
# clusterAgent.admissionController.enabled -- Enable the admissionController to be able to inject APM/Dogstatsd config and standard tags (env, service, version) automatically into your pods
enabled: true

# clusterAgent.admissionController.validation -- Validation Webhook configuration options
validation:
# clusterAgent.admissionController.validation.enabled -- Enabled enables the Admission Controller validation webhook. Default: true. (Requires Agent 7.59.0+).
enabled: true

# clusterAgent.admissionController.mutation -- Mutation Webhook configuration options
mutation:
# clusterAgent.admissionController.mutation.enabled -- Enabled enables the Admission Controller mutation webhook. Default: true. (Requires Agent 7.59.0+).
enabled: true

# clusterAgent.admissionController.webhookName -- Name of the validatingwebhookconfiguration and mutatingwebhookconfiguration created by the cluster-agent
webhookName: datadog-webhook

Expand Down

0 comments on commit 81548e0

Please sign in to comment.