Closed finnlewis closed 1 year ago
OK so I created the branch, bit hard to review. My only question on creating it was naming. It seems we want more than one core the lando way is to spin up another solr! So solr
as the name for the container, and lando
for the core might be ambiguous. Might be better solr_sitewide
and sitewide
or something?
I went for service name: solr-sitewide; and core name: sitewide. I've updated the PR on localgov_search for the same defaults.
@stephen-cox we're keen to get this merged in to crack on with the search improvements and a default solr setup.
Some tests are failing on various other projects... which I will add issue for, but hoping we can merge this and resolve those on other projects.
Just wondering about the best way to handle the Solr core config. This will change with updates to the Drupal Solr module. Adding this to the project will also mean that it gets included with every composer install, which means it's being pulled into all sites whether they use Lando and Solr or not.
In don't think there's a straightforward way to automatically fetch up to date Solr config, so we'll have to stick it somewhere. Maybe a better place for it is the module that defines the Solr server?
Would also be nice to get the code depredations fixed https://github.com/localgovdrupal/localgov_services/issues/170
Discussing at Merge Monday:
@ekes will look and see if we can wiring in a drush command to deploy the config from the right place.
Using drush search-api-solr:get-server-config
we can get the zip of the configuration and unzip it.
But... when... what triggers us doing this?
It has to be after the site is installed, and the appropriate module (eg. localgov_search is enabled) but it's something specific to the project and it then being run in lando. A post install hook that checks the environment it's running in, somehow..? Even where to put it? There's nothing that could implement a hook like that here?
This could just be added as an extra command into the Lando tools section. Anyone using Solr would have to run the command to download and install the config. The other issue is once the config is in place it's necessary to restart Solr. Although we may need to rebuild Lando (this should be checked).
Just discussing the search working group.
@ekes hopes to find time to write a drush command to deal with the config extraction and placement.
We will thus be relying on drush, within Lando, which seems fine for our support dev setup. We can also add documentation for how to do this manually.
So it sounds like the plan is to generate our own config with some magic.
Should we close this in preference to f https://github.com/localgovdrupal/localgov_search_solr/issues/2 or is there another ticket, or tickets, we should open to cover this?
Closing this in favour of a new hope! See https://github.com/localgovdrupal/localgov_project/issues/86
@ekes just creating this to see the changes and discuss.... personally I think it would be good to have in the default Lando for people to play with.