From 1346a104771af73fd66441dd87b903c56a66e539 Mon Sep 17 00:00:00 2001 From: Victor Carlos Erenu Date: Tue, 17 Mar 2026 01:41:56 +0700 Subject: [PATCH 1/4] Delete docker unused volumes and change user and password for healthcheck --- multi-node/docker-compose.yml | 8 +++----- single-node/docker-compose.yml | 3 +-- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/multi-node/docker-compose.yml b/multi-node/docker-compose.yml index 257d9a1a..6d14c958 100644 --- a/multi-node/docker-compose.yml +++ b/multi-node/docker-compose.yml @@ -110,7 +110,7 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u $$INDEXER_USERNAME:$$INDEXER_PASSWORD https://localhost:9200/_cluster/health" ] + test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] interval: 10s timeout: 5s retries: 10 @@ -150,7 +150,7 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u $$INDEXER_USERNAME:$$INDEXER_PASSWORD https://localhost:9200/_cluster/health" ] + test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] interval: 10s timeout: 5s retries: 10 @@ -188,7 +188,7 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u $$INDEXER_USERNAME:$$INDEXER_PASSWORD https://localhost:9200/_cluster/health" ] + test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] interval: 10s timeout: 5s retries: 10 @@ -258,13 +258,11 @@ volumes: master-wazuh-logs: master-wazuh-queue: master-wazuh-var-multigroups: - master-wazuh-active-response: worker-wazuh-api-configuration: worker-wazuh-etc: worker-wazuh-logs: worker-wazuh-queue: worker-wazuh-var-multigroups: - worker-wazuh-active-response: wazuh-indexer-data-1: wazuh-indexer-data-2: wazuh-indexer-data-3: diff --git a/single-node/docker-compose.yml b/single-node/docker-compose.yml index 9dfb76c4..e4b90752 100644 --- a/single-node/docker-compose.yml +++ b/single-node/docker-compose.yml @@ -68,7 +68,7 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u $$INDEXER_USERNAME:$$INDEXER_PASSWORD https://localhost:9200/_cluster/health" ] + test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] interval: 10s timeout: 5s retries: 10 @@ -126,7 +126,6 @@ volumes: wazuh_logs: wazuh_queue: wazuh_var_multigroups: - wazuh_active_response: wazuh-indexer-data: wazuh-dashboard-config: wazuh-dashboard-custom: From 2f8503dba9191baf090fd22fd10482fb4b996eab Mon Sep 17 00:00:00 2001 From: Victor Carlos Erenu Date: Tue, 17 Mar 2026 02:06:48 +0700 Subject: [PATCH 2/4] change healthchecks --- multi-node/docker-compose.yml | 32 ++++++++++++++++---------------- single-node/docker-compose.yml | 12 ++++++------ 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/multi-node/docker-compose.yml b/multi-node/docker-compose.yml index 6d14c958..33773b07 100644 --- a/multi-node/docker-compose.yml +++ b/multi-node/docker-compose.yml @@ -9,7 +9,7 @@ services: wazuh1.indexer: condition: service_healthy healthcheck: - test: [ "CMD-SHELL", "curl -s -k -I -u $$API_USERNAME:$$API_PASSWORD https://localhost:55000/security/user/authenticate > /dev/null || exit 1" ] + test: [ "CMD-SHELL", "curl -s -k -f -I -u $$API_USERNAME:$$API_PASSWORD https://localhost:55000/security/user/authenticate > /dev/null || exit 1" ] interval: 15s timeout: 5s retries: 5 @@ -110,11 +110,11 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] - interval: 10s - timeout: 5s - retries: 10 - start_period: 30s + test: [ "CMD-SHELL", "curl -fks https://localhost:9200/_plugins/_security/health | grep -q '\"status\":\"UP\"'" ] + interval: 30s + timeout: 10s + retries: 5 + start_period: 60s volumes: - wazuh-indexer-data-1:/var/lib/wazuh-indexer - ./wazuh-certificates/root-ca.pem:/usr/share/wazuh-indexer/config/certs/root-ca.pem @@ -150,11 +150,11 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] - interval: 10s - timeout: 5s - retries: 10 - start_period: 30s + test: [ "CMD-SHELL", "curl -fks https://localhost:9200/_plugins/_security/health | grep -q '\"status\":\"UP\"'" ] + interval: 30s + timeout: 10s + retries: 5 + start_period: 60s volumes: - wazuh-indexer-data-2:/var/lib/wazuh-indexer - ./wazuh-certificates/root-ca.pem:/usr/share/wazuh-indexer/config/certs/root-ca.pem @@ -188,11 +188,11 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] - interval: 10s - timeout: 5s - retries: 10 - start_period: 30s + test: [ "CMD-SHELL", "curl -fks https://localhost:9200/_plugins/_security/health | grep -q '\"status\":\"UP\"'" ] + interval: 30s + timeout: 10s + retries: 5 + start_period: 60s volumes: - wazuh-indexer-data-3:/var/lib/wazuh-indexer - ./wazuh-certificates/root-ca.pem:/usr/share/wazuh-indexer/config/certs/root-ca.pem diff --git a/single-node/docker-compose.yml b/single-node/docker-compose.yml index e4b90752..02dbbb7e 100644 --- a/single-node/docker-compose.yml +++ b/single-node/docker-compose.yml @@ -9,7 +9,7 @@ services: wazuh.indexer: condition: service_healthy healthcheck: - test: [ "CMD-SHELL", "curl -s -k -I -u $$API_USERNAME:$$API_PASSWORD https://localhost:55000/security/user/authenticate > /dev/null || exit 1" ] + test: [ "CMD-SHELL", "curl -s -k -f -I -u $$API_USERNAME:$$API_PASSWORD https://localhost:55000/security/user/authenticate > /dev/null || exit 1" ] interval: 15s timeout: 5s retries: 5 @@ -68,11 +68,11 @@ services: soft: 65536 hard: 65536 healthcheck: - test: [ "CMD-SHELL", "curl -s -k -u test:test https://localhost:9200/_cluster/health" ] - interval: 10s - timeout: 5s - retries: 10 - start_period: 30s + test: [ "CMD-SHELL", "curl -fks https://localhost:9200/_plugins/_security/health | grep -q '\"status\":\"UP\"'" ] + interval: 30s + timeout: 10s + retries: 5 + start_period: 60s volumes: - wazuh-indexer-data:/var/lib/wazuh-indexer - ./wazuh-certificates/root-ca.pem:/usr/share/wazuh-indexer/config/certs/root-ca.pem From 8da0704978f73c9700d7bfb5841e88b052af9be5 Mon Sep 17 00:00:00 2001 From: Victor Carlos Erenu Date: Tue, 17 Mar 2026 02:09:47 +0700 Subject: [PATCH 3/4] Add changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 49e5fb9c..5eedb691 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ All notable changes to this project will be documented in this file. ### Changed +- Modify Healthchecks ([#2252](https://github.com/wazuh/wazuh-docker/pull/2252)) - Add deployment healthchecks ([#2251](https://github.com/wazuh/wazuh-docker/pull/2251)) - Update artifact generation jobs to use wz-linux dedicated runner group ([#2242](https://github.com/wazuh/wazuh-docker/pull/2242)) - Fix set_correct_permOwner function ([#2238](https://github.com/wazuh/wazuh-docker/pull/2238)) From 49375d75f7706cf151d68e15a9ad41e1c9d5d3df Mon Sep 17 00:00:00 2001 From: Victor Carlos Erenu Date: Tue, 17 Mar 2026 02:43:44 +0700 Subject: [PATCH 4/4] Delete active-response reference --- build-docker-images/build-images.yml | 1 - build-docker-images/wazuh-manager/Dockerfile | 3 --- 2 files changed, 4 deletions(-) diff --git a/build-docker-images/build-images.yml b/build-docker-images/build-images.yml index 707123b3..a7492911 100644 --- a/build-docker-images/build-images.yml +++ b/build-docker-images/build-images.yml @@ -27,7 +27,6 @@ services: - wazuh_logs:/var/wazuh-manager/logs - wazuh_queue:/var/wazuh-manager/queue - wazuh_var_multigroups:/var/wazuh-manager/var/multigroups - - wazuh_active_response:/var/wazuh-manager/active-response/bin wazuh.agent: build: diff --git a/build-docker-images/wazuh-manager/Dockerfile b/build-docker-images/wazuh-manager/Dockerfile index d4ff3e83..b7475a1a 100644 --- a/build-docker-images/wazuh-manager/Dockerfile +++ b/build-docker-images/wazuh-manager/Dockerfile @@ -39,9 +39,6 @@ COPY config/permanent_data.env config/permanent_data.sh / RUN mkdir -p /var/wazuh-manager/var/multigroups && \ chown root:wazuh-manager /var/wazuh-manager/var/multigroups && \ chmod 770 /var/wazuh-manager/var/multigroups && \ - mkdir -p /var/wazuh-manager/active-response/bin && \ - chown root:wazuh-manager /var/wazuh-manager/active-response/bin && \ - chmod 770 /var/wazuh-manager/active-response/bin && \ chmod 755 /permanent_data.sh && \ sync && /permanent_data.sh && \ sync && rm /permanent_data.sh