From 5b297c5cab13e3f73235a1797a644946f9abc9f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Ko=C5=82odziejczyk?= Date: Thu, 8 Jan 2026 11:24:54 +0100 Subject: [PATCH 1/2] A little bit faster startup --- environments/eck-ror/kind-cluster/ror/base/es.yml | 6 +++++- environments/eck-ror/kind-cluster/ror/base/kbn.yml | 2 +- environments/eck-ror/start.sh | 13 ++++++++----- environments/elk-ror/base.docker-compose.yml | 2 +- 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/environments/eck-ror/kind-cluster/ror/base/es.yml b/environments/eck-ror/kind-cluster/ror/base/es.yml index 2b42fb1..af49400 100644 --- a/environments/eck-ror/kind-cluster/ror/base/es.yml +++ b/environments/eck-ror/kind-cluster/ror/base/es.yml @@ -38,6 +38,8 @@ spec: secretKeyRef: name: eck-ror-kibana-user key: ${ROR_ECK_KIBANA_USER_SECRET_KEY} + - name: ES_JAVA_OPTS + value: "-Dcom.readonlyrest.settings.loading.attempts.count=0 -Dcom.readonlyrest.settings.loading.delay=0s" volumeMounts: - name: config-ror mountPath: /usr/share/elasticsearch/config/readonlyrest.yml @@ -45,10 +47,12 @@ spec: - name: config-log4j2 mountPath: /usr/share/elasticsearch/config/log4j2.properties subPath: log4j2.properties + volumes: - name: config-ror configMap: name: config-readonlyrest.yml - name: config-log4j2 configMap: - name: config-log4j2.properties.yml \ No newline at end of file + name: config-log4j2.properties.yml + \ No newline at end of file diff --git a/environments/eck-ror/kind-cluster/ror/base/kbn.yml b/environments/eck-ror/kind-cluster/ror/base/kbn.yml index 7864e3d..1469597 100644 --- a/environments/eck-ror/kind-cluster/ror/base/kbn.yml +++ b/environments/eck-ror/kind-cluster/ror/base/kbn.yml @@ -18,7 +18,7 @@ spec: cookiePass: '12312313123213123213123adadasdasdasd' logLevel: trace store_sessions_in_index: true - ${ELATICSEARCH_USER} + ${ELATICSEARCH_USER} ${ELATICSEARCH_PASSWORD} podTemplate: diff --git a/environments/eck-ror/start.sh b/environments/eck-ror/start.sh index b7cf4fe..08753e9 100755 --- a/environments/eck-ror/start.sh +++ b/environments/eck-ror/start.sh @@ -226,20 +226,23 @@ check_pods_running() { while read -r line; do ready=$(echo "$line" | awk '{print $2}') status=$(echo "$line" | awk '{print $3}') - - if [[ "$status" != "Running" || "$ready" != "1/1" ]]; then + + cur="${ready%/*}" + total="${ready#*/}" + + if [[ "$status" != "Running" || "$cur" != "$total" ]]; then all_ready=false fi done <<< "$pod_status" - echo -e "$pod_status" + echo -e "$pod_status" $all_ready && return 0 || return 1 } TIMEOUT_IN_SECONDS=300 INTERVAL_IN_SECONDS=5 -echo "Waiting for all pods to be in Running and Ready state (1/1)..." +echo "Waiting for all pods to be in Running and Ready state..." elapsed_time=0 while ! check_pods_running; do sleep $INTERVAL_IN_SECONDS @@ -250,4 +253,4 @@ while ! check_pods_running; do exit 1 fi done -echo "All pods are in Running and Ready (1/1) state." +echo "All pods are in Running and Ready state." diff --git a/environments/elk-ror/base.docker-compose.yml b/environments/elk-ror/base.docker-compose.yml index 14b8c81..4410011 100644 --- a/environments/elk-ror/base.docker-compose.yml +++ b/environments/elk-ror/base.docker-compose.yml @@ -22,7 +22,7 @@ services: - discovery.type=single-node - bootstrap.memory_lock=true # for a sake of debugging and profiling - - "ES_JAVA_OPTS=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005 -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9010 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.rmi.port=9010 -Djava.rmi.server.hostname=127.0.0.1" + - "ES_JAVA_OPTS=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005 -Dcom.readonlyrest.settings.loading.attempts.count=0 -Dcom.readonlyrest.settings.loading.delay=0s -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9010 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.rmi.port=9010 -Djava.rmi.server.hostname=127.0.0.1" # for a sake of ROR settings marked as "<-- related to ECK environment -->" - KIBANA_SERVICE_ACCOUNT_TOKEN=UNUSED - INTERNAL_PROBE_PASS=UNUSED From eea632e12d7cced941820042b5e44ab57043430b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Ko=C5=82odziejczyk?= Date: Thu, 8 Jan 2026 19:13:23 +0100 Subject: [PATCH 2/2] fix --- environments/elk-ror/start.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/environments/elk-ror/start.sh b/environments/elk-ror/start.sh index 1d5ad7d..584ba14 100755 --- a/environments/elk-ror/start.sh +++ b/environments/elk-ror/start.sh @@ -134,7 +134,7 @@ if ! docker compose $DOCKER_COMPOSE_FILES config > /dev/null; then fi handle_docker_compose_error() { - docker compose $DOCKER_COMPOSE_FILES logs -f > elk-ror.log 2>&1 & + docker compose $DOCKER_COMPOSE_FILES logs > elk-ror.log 2>&1 exit 1 }