From faa594796313846b46c090391b296d3ed60e6272 Mon Sep 17 00:00:00 2001 From: Simon L Date: Wed, 7 Jun 2023 14:43:09 +0200 Subject: [PATCH 1/6] update to ES 8 and add necessary adjustements to its config Signed-off-by: Simon L --- Containers/fulltextsearch/Dockerfile | 2 +- php/containers.json | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Containers/fulltextsearch/Dockerfile b/Containers/fulltextsearch/Dockerfile index 65a772c0..0130c3b4 100644 --- a/Containers/fulltextsearch/Dockerfile +++ b/Containers/fulltextsearch/Dockerfile @@ -1,5 +1,5 @@ # Probably from here https://github.com/elastic/elasticsearch/blob/main/distribution/docker/src/docker/Dockerfile -FROM elasticsearch:7.17.10 +FROM elasticsearch:8.7.1 USER root diff --git a/php/containers.json b/php/containers.json index f72fb3f2..40cb0eca 100644 --- a/php/containers.json +++ b/php/containers.json @@ -499,10 +499,18 @@ ], "internal_port": "9200", "environment": [ + "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", + "ES_JAVA_OPTS=-Xms1024M -Xmx1024M -Des.enforce.bootstrap.checks=true", + "xpack.license.self_generated.type=basic", + "xpack.security.enabled=false", + "xpack.watcher.enabled=false", + "xpack.graph.enabled=false", + "xpack.ml.enabled=false", + "bootstrap.memory_lock=true", + "cluster.name=nextcloud-aio", "discovery.type=single-node", - "ES_JAVA_OPTS=-Xms1024M -Xmx1024M", - "POSTGRES_HOST=nextcloud-aio-database" + "thread_pool.write.queue_size=1000" ], "volumes": [ { From 2dfab2941bf12fad53045c236bcbb6842c5d3948 Mon Sep 17 00:00:00 2001 From: Simon L Date: Tue, 27 Jun 2023 11:51:53 +0200 Subject: [PATCH 2/6] adjust a few things Signed-off-by: Simon L --- Containers/fulltextsearch/Dockerfile | 2 +- Containers/nextcloud/entrypoint.sh | 2 +- php/containers.json | 21 ++++++++++++--------- 3 files changed, 14 insertions(+), 11 deletions(-) diff --git a/Containers/fulltextsearch/Dockerfile b/Containers/fulltextsearch/Dockerfile index 0130c3b4..b76277c2 100644 --- a/Containers/fulltextsearch/Dockerfile +++ b/Containers/fulltextsearch/Dockerfile @@ -1,5 +1,5 @@ # Probably from here https://github.com/elastic/elasticsearch/blob/main/distribution/docker/src/docker/Dockerfile -FROM elasticsearch:8.7.1 +FROM elasticsearch:8.8.0 USER root diff --git a/Containers/nextcloud/entrypoint.sh b/Containers/nextcloud/entrypoint.sh index cb6e3a9b..446dab30 100644 --- a/Containers/nextcloud/entrypoint.sh +++ b/Containers/nextcloud/entrypoint.sh @@ -677,7 +677,7 @@ if [ "$FULLTEXTSEARCH_ENABLED" = 'yes' ]; then php /var/www/html/occ app:update files_fulltextsearch fi php /var/www/html/occ fulltextsearch:configure '{"search_platform":"OCA\\FullTextSearch_Elasticsearch\\Platform\\ElasticSearchPlatform"}' - php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" + php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://elastic:$ELASTIC_PASSWORD@$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" php /var/www/html/occ files_fulltextsearch:configure "{\"files_pdf\":\"1\",\"files_office\":\"1\"}" # Do the index diff --git a/php/containers.json b/php/containers.json index 40cb0eca..756b0809 100644 --- a/php/containers.json +++ b/php/containers.json @@ -113,7 +113,8 @@ "REDIS_PASSWORD", "NEXTCLOUD_PASSWORD", "TURN_SECRET", - "SIGNALING_SECRET" + "SIGNALING_SECRET", + "ELASTIC_PASSWORD" ], "volumes": [ { @@ -180,7 +181,8 @@ "INSTALL_LATEST_MAJOR=%INSTALL_LATEST_MAJOR%", "TALK_RECORDING_ENABLED=%TALK_RECORDING_ENABLED%", "RECORDING_SECRET=%RECORDING_SECRET%", - "TALK_RECORDING_HOST=nextcloud-aio-talk-recording" + "TALK_RECORDING_HOST=nextcloud-aio-talk-recording", + "ELASTIC_PASSWORD=%ELASTIC_PASSWORD%" ], "restart": "unless-stopped", "devices": [ @@ -501,16 +503,14 @@ "environment": [ "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", - "ES_JAVA_OPTS=-Xms1024M -Xmx1024M -Des.enforce.bootstrap.checks=true", - "xpack.license.self_generated.type=basic", - "xpack.security.enabled=false", - "xpack.watcher.enabled=false", - "xpack.graph.enabled=false", - "xpack.ml.enabled=false", + "ELASTIC_PASSWORD=%ELASTIC_PASSWORD%", + "ES_JAVA_OPTS=-Xms512M -Xmx512M -Des.enforce.bootstrap.checks=true", "bootstrap.memory_lock=true", "cluster.name=nextcloud-aio", "discovery.type=single-node", - "thread_pool.write.queue_size=1000" + "http.port=9200", + "xpack.license.self_generated.type=basic", + "xpack.security.enabled=false" ], "volumes": [ { @@ -525,6 +525,9 @@ ], "networks": [ "nextcloud-aio" + ], + "secrets": [ + "ELASTIC_PASSWORD" ] } ] From dedc25dc514436d98dba150a34e380ba8d2316f8 Mon Sep 17 00:00:00 2001 From: Simon L Date: Tue, 27 Jun 2023 11:53:06 +0200 Subject: [PATCH 3/6] some more adjustments Signed-off-by: Simon L --- php/containers.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/php/containers.json b/php/containers.json index 756b0809..b66d4612 100644 --- a/php/containers.json +++ b/php/containers.json @@ -504,10 +504,11 @@ "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", "ELASTIC_PASSWORD=%ELASTIC_PASSWORD%", - "ES_JAVA_OPTS=-Xms512M -Xmx512M -Des.enforce.bootstrap.checks=true", + "ES_JAVA_OPTS=-Xms512M -Xmx512M", "bootstrap.memory_lock=true", "cluster.name=nextcloud-aio", "discovery.type=single-node", + "logger.org.elasticsearch.discovery=WARN", "http.port=9200", "xpack.license.self_generated.type=basic", "xpack.security.enabled=false" From 443fb67465d504dcf72beb4c5897c8477c6f12c2 Mon Sep 17 00:00:00 2001 From: Simon L Date: Tue, 27 Jun 2023 11:56:54 +0200 Subject: [PATCH 4/6] adjust detail Signed-off-by: Simon L --- Containers/nextcloud/entrypoint.sh | 2 +- php/containers.json | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Containers/nextcloud/entrypoint.sh b/Containers/nextcloud/entrypoint.sh index 446dab30..6ca3004a 100644 --- a/Containers/nextcloud/entrypoint.sh +++ b/Containers/nextcloud/entrypoint.sh @@ -677,7 +677,7 @@ if [ "$FULLTEXTSEARCH_ENABLED" = 'yes' ]; then php /var/www/html/occ app:update files_fulltextsearch fi php /var/www/html/occ fulltextsearch:configure '{"search_platform":"OCA\\FullTextSearch_Elasticsearch\\Platform\\ElasticSearchPlatform"}' - php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://elastic:$ELASTIC_PASSWORD@$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" + php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://elastic:$FULLTEXTSEARCH_PASSWORD@$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" php /var/www/html/occ files_fulltextsearch:configure "{\"files_pdf\":\"1\",\"files_office\":\"1\"}" # Do the index diff --git a/php/containers.json b/php/containers.json index b66d4612..b87ee337 100644 --- a/php/containers.json +++ b/php/containers.json @@ -114,7 +114,7 @@ "NEXTCLOUD_PASSWORD", "TURN_SECRET", "SIGNALING_SECRET", - "ELASTIC_PASSWORD" + "FULLTEXTSEARCH_PASSWORD" ], "volumes": [ { @@ -182,7 +182,7 @@ "TALK_RECORDING_ENABLED=%TALK_RECORDING_ENABLED%", "RECORDING_SECRET=%RECORDING_SECRET%", "TALK_RECORDING_HOST=nextcloud-aio-talk-recording", - "ELASTIC_PASSWORD=%ELASTIC_PASSWORD%" + "FULLTEXTSEARCH_PASSWORD=%FULLTEXTSEARCH_PASSWORD%" ], "restart": "unless-stopped", "devices": [ @@ -503,7 +503,7 @@ "environment": [ "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", - "ELASTIC_PASSWORD=%ELASTIC_PASSWORD%", + "FULLTEXTSEARCH_PASSWORD=%FULLTEXTSEARCH_PASSWORD%", "ES_JAVA_OPTS=-Xms512M -Xmx512M", "bootstrap.memory_lock=true", "cluster.name=nextcloud-aio", @@ -528,7 +528,7 @@ "nextcloud-aio" ], "secrets": [ - "ELASTIC_PASSWORD" + "FULLTEXTSEARCH_PASSWORD" ] } ] From e4f68f763640ab5a0022281dff3747f634c6ac71 Mon Sep 17 00:00:00 2001 From: Simon L Date: Wed, 19 Jul 2023 14:09:49 +0200 Subject: [PATCH 5/6] remove FTS_PASSWORD again Signed-off-by: Simon L --- Containers/nextcloud/entrypoint.sh | 2 +- php/containers.json | 10 ++-------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/Containers/nextcloud/entrypoint.sh b/Containers/nextcloud/entrypoint.sh index 6ca3004a..cb6e3a9b 100644 --- a/Containers/nextcloud/entrypoint.sh +++ b/Containers/nextcloud/entrypoint.sh @@ -677,7 +677,7 @@ if [ "$FULLTEXTSEARCH_ENABLED" = 'yes' ]; then php /var/www/html/occ app:update files_fulltextsearch fi php /var/www/html/occ fulltextsearch:configure '{"search_platform":"OCA\\FullTextSearch_Elasticsearch\\Platform\\ElasticSearchPlatform"}' - php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://elastic:$FULLTEXTSEARCH_PASSWORD@$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" + php /var/www/html/occ fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http://$FULLTEXTSEARCH_HOST:9200\",\"elastic_index\":\"nextcloud-aio\"}" php /var/www/html/occ files_fulltextsearch:configure "{\"files_pdf\":\"1\",\"files_office\":\"1\"}" # Do the index diff --git a/php/containers.json b/php/containers.json index b87ee337..9e3b9cc4 100644 --- a/php/containers.json +++ b/php/containers.json @@ -113,8 +113,7 @@ "REDIS_PASSWORD", "NEXTCLOUD_PASSWORD", "TURN_SECRET", - "SIGNALING_SECRET", - "FULLTEXTSEARCH_PASSWORD" + "SIGNALING_SECRET" ], "volumes": [ { @@ -181,8 +180,7 @@ "INSTALL_LATEST_MAJOR=%INSTALL_LATEST_MAJOR%", "TALK_RECORDING_ENABLED=%TALK_RECORDING_ENABLED%", "RECORDING_SECRET=%RECORDING_SECRET%", - "TALK_RECORDING_HOST=nextcloud-aio-talk-recording", - "FULLTEXTSEARCH_PASSWORD=%FULLTEXTSEARCH_PASSWORD%" + "TALK_RECORDING_HOST=nextcloud-aio-talk-recording" ], "restart": "unless-stopped", "devices": [ @@ -503,7 +501,6 @@ "environment": [ "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", - "FULLTEXTSEARCH_PASSWORD=%FULLTEXTSEARCH_PASSWORD%", "ES_JAVA_OPTS=-Xms512M -Xmx512M", "bootstrap.memory_lock=true", "cluster.name=nextcloud-aio", @@ -526,9 +523,6 @@ ], "networks": [ "nextcloud-aio" - ], - "secrets": [ - "FULLTEXTSEARCH_PASSWORD" ] } ] From 7c38050f58763d1d178fc9324da7ecbe28f5be5d Mon Sep 17 00:00:00 2001 From: Simon L Date: Wed, 19 Jul 2023 14:12:13 +0200 Subject: [PATCH 6/6] adjust a detail Signed-off-by: Simon L --- php/containers.json | 1 - 1 file changed, 1 deletion(-) diff --git a/php/containers.json b/php/containers.json index 9e3b9cc4..569cd208 100644 --- a/php/containers.json +++ b/php/containers.json @@ -499,7 +499,6 @@ ], "internal_port": "9200", "environment": [ - "POSTGRES_HOST=nextcloud-aio-database", "TZ=%TIMEZONE%", "ES_JAVA_OPTS=-Xms512M -Xmx512M", "bootstrap.memory_lock=true",