Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add solr core reload/optimize #215

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,14 @@ run-islandora-migrations:
solr-cores:
docker-compose exec -T drupal with-contenv bash -lc "for_all_sites create_solr_core_with_default_config"

# Reloads solr-cores with current live configurations and then optimizes it. This assumes the solr-core is named ISLANDORA.
.PHONY: solr-reload-cores
.SILENT: solr-reload-cores
solr-reload-cores:
curl $(shell grep -Fxq "EXPOSE_SOLR=true" .env && echo "http://$(shell docker inspect -f "{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}" $(shell docker ps --format "{{.Names}}" | grep solr)):8983/solr/admin/cores?action=RELOAD\&core=ISLANDORA")
curl $(shell grep -Fxq "EXPOSE_SOLR=true" .env && echo "http://$(shell docker inspect -f "{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}" $(shell docker ps --format "{{.Names}}" | grep solr)):8983/solr/ISLANDORA/update?optimize=true")
echo "Can be verified at http://$(shell docker inspect -f "{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}" $(shell docker ps --format "{{.Names}}" | grep solr)):8983/solr/#/~cores/ISLANDORA"

# Creates namespaces in Blazegraph according to the environment variables.
.PHONY: namespaces
.SILENT: namespaces
Expand Down