Open cjcodes opened 6 years ago
Thanks for the report, @cjcodes.
For the public record, I've worked around this issue (error posting schema) by copying the schema.xml file to the correct place on the filesystem. For me, this is ~/solr/solr/conf/schema.xml
.
It looks like Lando is defining the PANTHEON_ENVIRONMENT
constant as of https://github.com/lando/lando/commit/d600e1cd82c8a391a9e560ac0dccfd9f845aaf66#diff-d02f821273817782be37a9c539342257
We may want to come to a consensus with the Lando team about how best to handle this. Ideally we can supply a slug of configuration that will make it work with their local environment without any hacking needed.
@danielbachhuber Indeed copying the schema.xml helps, but there are two other issues I've run into:
@joshkoenig I'll hold on any PRs then until I hear from you--I'm happy to code up the solution by detecting PANTHEON_ENVIRONMENT
. There's some consolidation and refactoring that could also be useful related to this.
Revisiting this.
I'm running a a local Lando environment with the default pantheon
recipe. I'm currently looking into enabling Solr and was having trouble enabling the plugin. After some debugging, I noticed that the post schema task which is ran when the plugin is enabled was returning a 204. Modifying includes/includes/class-solrpower-api.php:134
to allow a 204 response allows the plugin to be installed correctly. Afterwards, I am able to successfully ping and index via the plugin settings and WP CLI.
I did not run into any cert issues. Perhaps this was fixed in a future configuration of the pantheon
Lando recipe?
When developing locally with Lando, the certs required for this plugin to work are not installed.
Temporarily, I had to comment out:
includes/class-pantheoncurl.php:27
includes/includes/class-solrpower-api.php:109
includes/includes/class-solrpower-api.php:118
(Line numbers come from the latest version released on wp.org.)
I don't yet have recommended solution steps (in crunch mode on a project), but want to create a placeholder issue or perhaps one of y'all has a good quick solution.
Alternatively, we could look into moving this issue over into the Lando repo to have certs included there, but I think it's a solvable problem on this side. (The certs are installed to /certs in the Docker container, but it's called "index.pem," not "binding.pem".)