From 6ca163fae635e20b7b02627c2d431da210b14b4a Mon Sep 17 00:00:00 2001 From: Marko Bocevski Date: Mon, 14 Sep 2020 16:33:21 +0200 Subject: [PATCH] Fix zookeeper returning true when in SolrCloud mode --- images/ckan/2.7/setup/app/prerun.py | 2 ++ images/ckan/2.8/setup/app/prerun.py | 2 ++ images/ckan/2.9/setup/app/prerun.py | 3 ++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/images/ckan/2.7/setup/app/prerun.py b/images/ckan/2.7/setup/app/prerun.py index 0dbd70e..5a19d3f 100644 --- a/images/ckan/2.7/setup/app/prerun.py +++ b/images/ckan/2.7/setup/app/prerun.py @@ -57,6 +57,8 @@ def check_solr_connection(retry=None): else: import re conn_info = connection.read() + # SolrCloud + conn_info = re.sub(r'"zkConnected":true', '"zkConnected":True', conn_info) eval(conn_info) def init_db(): diff --git a/images/ckan/2.8/setup/app/prerun.py b/images/ckan/2.8/setup/app/prerun.py index 0dbd70e..5a19d3f 100644 --- a/images/ckan/2.8/setup/app/prerun.py +++ b/images/ckan/2.8/setup/app/prerun.py @@ -57,6 +57,8 @@ def check_solr_connection(retry=None): else: import re conn_info = connection.read() + # SolrCloud + conn_info = re.sub(r'"zkConnected":true', '"zkConnected":True', conn_info) eval(conn_info) def init_db(): diff --git a/images/ckan/2.9/setup/app/prerun.py b/images/ckan/2.9/setup/app/prerun.py index 01e766e..f2ce383 100644 --- a/images/ckan/2.9/setup/app/prerun.py +++ b/images/ckan/2.9/setup/app/prerun.py @@ -57,7 +57,8 @@ def check_solr_connection(retry=None): else: import re conn_info = connection.read() - print(conn_info) + # SolrCloud + conn_info = re.sub(r'"zkConnected":true', '"zkConnected":True', conn_info) eval(conn_info) def init_db():