Skip to content

Commit 48dadf6

Browse files
authored
Release Wazuh version 2.3.0 (#92)
* [wazuh]: update OpenSearch configuration to use dynamic SECURITY_NODES_DN variable in indexer templates Signed-off-by: Mohamad Berjawi <[email protected]> * [wazuh]: update manager and worker service templates to support external traffic policy and annotations Signed-off-by: Mohamad Berjawi <[email protected]> * [wazuh]: bump chart version to 2.3.0 and add nodesDN configuration for certificate management Signed-off-by: Mohamad Berjawi <[email protected]> * [wazuh](wazuh-service.yaml): fix missing newline Signed-off-by: Mohamad Berjawi <[email protected]> --------- Signed-off-by: Mohamad Berjawi <[email protected]>
1 parent 630d6b1 commit 48dadf6

File tree

9 files changed

+59
-47
lines changed

9 files changed

+59
-47
lines changed

charts/wazuh/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ type: application
1515
# This is the chart version. This version number should be incremented each time you make changes
1616
# to the chart and its templates, including the app version.
1717
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18-
version: 2.2.1
18+
version: 2.3.0
1919

2020
# This is the version number of the application being deployed. This version number should be
2121
# incremented each time you make changes to the application. Versions are not expected to

charts/wazuh/configs/indexer_conf/opensearch.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ plugins.security.authcz.admin_dn:
2222
plugins.security.check_snapshot_restore_write_privileges: true
2323
plugins.security.enable_snapshot_restore_privilege: true
2424
plugins.security.nodes_dn:
25-
- CN=*.wazuh-indexer,O=Company,L=California,C=US
25+
- CN=${SECURITY_NODES_DN}
2626
plugins.security.restapi.roles_enabled:
2727
- "all_access"
2828
- "security_rest_api_access"

charts/wazuh/templates/indexer/indexer-sts.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ spec:
8181
value: {{ include "wazuh.fullname" . }}-indexer
8282
- name: SECURITY_AUTHCZ_ADMIN_DN
8383
value: {{ .Values.tls.certManager.commonName }}
84+
- name: SECURITY_NODES_DN
85+
value: {{ .Values.indexer.config.nodesDN | default (printf "*.%s" (include "wazuh.fullname" .)) }}
8486
- name: KUBERNETES_NAMESPACE
8587
valueFrom:
8688
fieldRef:
@@ -246,6 +248,8 @@ spec:
246248
value: {{ include "wazuh.fullname" . }}-indexer
247249
- name: SECURITY_AUTHCZ_ADMIN_DN
248250
value: {{ .Values.tls.certManager.commonName }}
251+
- name: SECURITY_NODES_DN
252+
value: {{ .Values.indexer.config.nodesDN | default (printf "*.%s" (include "wazuh.fullname" .)) }}
249253
- name: KUBERNETES_NAMESPACE
250254
valueFrom:
251255
fieldRef:

charts/wazuh/templates/manager/wazuh-master-sts.yaml

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ spec:
1515
{{- include "wazuh.selectorLabels" . | nindent 6 }}
1616
template:
1717
metadata:
18+
name: {{ include "wazuh.fullname" . }}-manager-master
1819
{{- with .Values.manager.master.podAnnotations }}
1920
annotations:
2021
{{- toYaml . | nindent 8 }}
@@ -114,26 +115,6 @@ spec:
114115
mountPath: /wazuh-config-mount/etc/authd.pass
115116
subPath: authd.pass
116117
readOnly: true
117-
- name: manager-certs
118-
mountPath: /wazuh-config-mount/etc/sslmanager.cert
119-
subPath: server.cert
120-
readOnly: true
121-
- name: manager-certs
122-
mountPath: /wazuh-config-mount/etc/sslmanager.key
123-
subPath: server.key
124-
readOnly: true
125-
- name: manager-certs
126-
mountPath: /wazuh-config-mount/api/configuration/ssl/server.crt
127-
subPath: server.cert
128-
readOnly: true
129-
- name: manager-certs
130-
mountPath: /wazuh-config-mount/api/configuration/ssl/server.key
131-
subPath: server.key
132-
readOnly: true
133-
- name: filebeat-certs
134-
mountPath: /wazuh-config-mount/api/configuration/ssl/ca.crt
135-
subPath: root-ca.pem
136-
readOnly: true
137118
- name: wazuh-manager-master
138119
mountPath: /var/ossec/api/configuration
139120
subPath: wazuh/var/ossec/api/configuration

charts/wazuh/templates/manager/wazuh-master-svc.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,20 @@
1+
{{- if .Values.manager.master.service.enabled }}
12
apiVersion: v1
23
kind: Service
34
metadata:
45
name: {{ include "wazuh.fullname" . }}-master
56
labels:
67
app: {{ include "wazuh.fullname" . }}-manager
78
{{- include "wazuh.labels" . | nindent 4 }}
9+
{{- with .Values.manager.master.service.annotations }}
10+
annotations:
11+
{{- toYaml . | nindent 4 }}
12+
{{- end }}
813
spec:
9-
type: ClusterIP
14+
type: {{ .Values.manager.master.service.type }}
15+
{{- if .Values.manager.master.service.externalTrafficPolicy }}
16+
externalTrafficPolicy: {{ .Values.manager.master.service.externalTrafficPolicy }}
17+
{{- end }}
1018
ports:
1119
- port: 1515
1220
targetPort: 1515
@@ -20,3 +28,4 @@ spec:
2028
app: {{ include "wazuh.fullname" . }}-manager
2129
node-type: master
2230
{{- include "wazuh.selectorLabels" . | nindent 4 }}
31+
{{- end }}

charts/wazuh/templates/manager/wazuh-service.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.manager.service.enabled }}
12
apiVersion: v1
23
kind: Service
34
metadata:
@@ -11,6 +12,9 @@ metadata:
1112
{{- end }}
1213
spec:
1314
type: {{ .Values.manager.service.type }}
15+
{{- if .Values.manager.service.externalTrafficPolicy }}
16+
externalTrafficPolicy: {{ .Values.manager.service.externalTrafficPolicy }}
17+
{{- end }}
1418
ports:
1519
- port: 1515
1620
targetPort: 1515
@@ -26,4 +30,5 @@ spec:
2630
name: api
2731
selector:
2832
app: {{ include "wazuh.fullname" . }}-manager
29-
{{- include "wazuh.selectorLabels" . | nindent 4 }}
33+
{{- include "wazuh.selectorLabels" . | nindent 4 }}
34+
{{- end }}

charts/wazuh/templates/manager/wazuh-worker-sts.yaml

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ spec:
1515
{{- include "wazuh.selectorLabels" . | nindent 6 }}
1616
template:
1717
metadata:
18+
name: {{ include "wazuh.fullname" . }}-manager-worker
1819
{{- with .Values.manager.workers.podAnnotations }}
1920
annotations:
2021
{{- toYaml . | nindent 8 }}
@@ -107,26 +108,6 @@ spec:
107108
mountPath: /wazuh-config-mount/etc/ossec.conf
108109
subPath: worker.conf
109110
readOnly: true
110-
- name: manager-certs
111-
mountPath: /wazuh-config-mount/etc/sslmanager.cert
112-
subPath: server.cert
113-
readOnly: true
114-
- name: manager-certs
115-
mountPath: /wazuh-config-mount/etc/sslmanager.key
116-
subPath: server.key
117-
readOnly: true
118-
- name: manager-certs
119-
mountPath: /wazuh-config-mount/api/configuration/ssl/server.crt
120-
subPath: server.cert
121-
readOnly: true
122-
- name: manager-certs
123-
mountPath: /wazuh-config-mount/api/configuration/ssl/server.key
124-
subPath: server.key
125-
readOnly: true
126-
- name: filebeat-certs
127-
mountPath: /wazuh-config-mount/api/configuration/ssl/ca.crt
128-
subPath: root-ca.pem
129-
readOnly: true
130111
- name: wazuh-manager-worker
131112
mountPath: /var/ossec/api/configuration
132113
subPath: wazuh/var/ossec/api/configuration

charts/wazuh/templates/manager/wazuh-workers-svc.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,20 @@
1+
{{- if .Values.manager.workers.service.enabled }}
12
apiVersion: v1
23
kind: Service
34
metadata:
45
name: {{ include "wazuh.fullname" . }}-workers
56
labels:
67
app: {{ include "wazuh.fullname" . }}-manager
78
{{- include "wazuh.labels" . | nindent 4 }}
9+
{{- with .Values.manager.workers.service.annotations }}
10+
annotations:
11+
{{- toYaml . | nindent 4 }}
12+
{{- end }}
813
spec:
9-
type: ClusterIP
14+
type: {{ .Values.manager.workers.service.type }}
15+
{{- if .Values.manager.workers.service.externalTrafficPolicy }}
16+
externalTrafficPolicy: {{ .Values.manager.workers.service.externalTrafficPolicy }}
17+
{{- end }}
1018
ports:
1119
- port: 1514
1220
targetPort: 1514
@@ -16,3 +24,4 @@ spec:
1624
app: {{ include "wazuh.fullname" . }}-manager
1725
node-type: worker
1826
{{- include "wazuh.selectorLabels" . | nindent 4 }}
27+
{{- end }}

charts/wazuh/values.yaml

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,14 @@ indexer:
115115
# Must have the key "internal_users.yml"
116116
# Please read https://documentation.wazuh.com/current/deployment-options/docker/wazuh-container.html#change-the-password-of-wazuh-users
117117
indexerInternalUsersSecretName: ""
118+
# Distinguished Name (DN) pattern for node certificates in plugins.security.nodes_dn
119+
# This whitelist controls which certificates are trusted for node-to-node communication.
120+
# Must match the CN (Common Name) in your node certificates issued by cert-manager.
121+
# Default: "*.{release-name}" (e.g., "*.wazuh" for release "wazuh")
122+
# Example: If your cert-manager issues certs with CN=wazuh, set this to "wazuh"
123+
# Example: If your cert-manager issues certs with CN=*.wazuh-indexer, set this to "*.wazuh-indexer"
124+
# Leave empty to auto-generate based on release name
125+
nodesDN: ""
118126

119127
imagePullSecrets: []
120128

@@ -234,11 +242,14 @@ manager:
234242
# authd.pass
235243
existingSecretName: ""
236244

237-
## The manager service that is going to be responsible for the agent registration
238-
## and the agent events
245+
## Exposes the whole manager stack (master and workers) to agents and users under a single service.
246+
## Port 1515 registers agents (master pods), port 55000 serves the Wazuh API (master pods)
247+
## and port 1514 receives agent events (worker pods)
239248
service:
249+
enabled: true
240250
type: LoadBalancer
241251
annotations: {}
252+
externalTrafficPolicy: Cluster
242253

243254
master:
244255
podSecurityContext:
@@ -308,6 +319,12 @@ manager:
308319
size: "25Gi"
309320
existingClaim: ""
310321

322+
service:
323+
enabled: true
324+
type: ClusterIP
325+
annotations: {}
326+
externalTrafficPolicy: ""
327+
311328
workers:
312329
replicaCount: 1
313330

@@ -378,6 +395,12 @@ manager:
378395
size: "25Gi"
379396
existingClaim: ""
380397

398+
service:
399+
enabled: true
400+
type: ClusterIP
401+
annotations: {}
402+
externalTrafficPolicy: ""
403+
381404
dashboard:
382405
replicaCount: 1
383406

0 commit comments

Comments
 (0)