Merge pull request #6606 from thegcat/configurable_fulltextsearch_connection

Make elasticsearch connection configurable
This commit is contained in:
Simon L. 2025-07-17 14:11:00 +02:00 committed by GitHub
commit d2c0176e11
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 14 additions and 2 deletions

View file

@ -809,7 +809,7 @@ fi
# Fulltextsearch
if [ "$FULLTEXTSEARCH_ENABLED" = 'yes' ]; then
while ! nc -z "$FULLTEXTSEARCH_HOST" 9200; do
while ! nc -z "$FULLTEXTSEARCH_HOST" "$FULLTEXTSEARCH_PORT"; do
echo "waiting for Fulltextsearch to become available..."
sleep 5
done
@ -835,7 +835,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_USER:$FULLTEXTSEARCH_PASSWORD@$FULLTEXTSEARCH_HOST:$FULLTEXTSEARCH_PORT\",\"elastic_index\":\"$FULLTEXTSEARCH_INDEX\"}"
php /var/www/html/occ files_fulltextsearch:configure "{\"files_pdf\":\"1\",\"files_office\":\"1\"}"
# Do the index