File tree 1 file changed +8
-0
lines changed
1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 38
38
- set_fact :
39
39
num_solr_nodes : " {{groups['solr'] | default([]) | length}}"
40
40
num_zk_nodes : " {{groups['zookeeper'] | default([]) | length}}"
41
+ # if an existing set of Solr/Fusion nodes were found, throw an error
42
+ # unless the reuse_existing_nodes flag was set to 'true' or 'yes')
43
+ - block :
44
+ - name : Fail playbook run if existing nodes found and user did not request reuse
45
+ fail :
46
+ msg : " Found an existing set of nodes - {{(groups['solr'] | to_yaml).split('\n ').0}}; aborting playbook run"
47
+ when : not((reuse_existing_nodes | default(false)) | bool)
48
+ when : num_solr_nodes | int > 0
41
49
# if an external Zookeeper ensemble (or node) was not found and we're
42
50
# deploying an Solr/Fusion cluster (or multiple matching Solr/Fusion
43
51
# nodes were found), then it's an error
You can’t perform that action at this time.
0 commit comments