File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed
Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 6868 sed -i '/VectorSearch/d' config/bundles.php
6969
7070 deploy : |
71+ OPENSEARCH_URL="http://opensearch.internal:9200"
72+ # Check the number of nodes in the cluster
73+ NODE_COUNT=$(curl -s "$OPENSEARCH_URL/_cat/nodes?h=name" | wc -l)
74+
75+ if [ "$NODE_COUNT" -eq 1 ]; then
76+ echo "This is a single-node OpenSearch cluster. Proceeding with the settings change."
77+
78+ # Change the setting plugins.ml_commons.only_run_on_ml_node to false
79+ curl -X PUT "$OPENSEARCH_URL/_cluster/settings" \
80+ -H "Content-Type: application/json" \
81+ -d '{ "persistent": { "plugins.ml_commons.only_run_on_ml_node": false}}'
82+ echo "Setting updated successfully."
83+ else
84+ echo "This is a multi-node OpenSearch cluster. No changes made."
85+ fi
86+ # Change the setting plugins.ml_commons.disk_free_space_threshold to -1 to avoid Disk Circuit Breaker
87+ curl -X PUT "$OPENSEARCH_URL/_cluster/settings" \
88+ -H "Content-Type: application/json" \
89+ -d '{ "persistent": { "plugins.ml_commons.disk_free_space_threshold": -1}}'
7190 bin/console --env=prod cache:clear
7291 bin/console doctrine:migrations:migrate -n --allow-no-migration
7392
You can’t perform that action at this time.
0 commit comments