ezsystems / launchpad

CLI tool to bootstrap an eZ Platform project Docker stack | #justcode
https://ezsystems.github.io/launchpad
MIT License
22 stars 27 forks source link

Cores not created on solr entrypoint.sh #49

Closed xserna closed 5 years ago

xserna commented 5 years ago

On solr entry point, solr engine is run in 'foreground' mode, in this line:

https://github.com/ezsystems/launchpad/blob/a386c2d5a58123e105eaabdb439a218de8bb68f1/payload/dev/solr/entrypoint.bash#L12

due to this, the solr core creation loop present after this line is never executed, I'm right?

Thanks!

Plopix commented 5 years ago

Hum, yes you are right.

I think it is working because it is done here: https://github.com/ezsystems/launchpad/blob/master/payload/recipes/ez_install_solr.bash#L45 as well.

Thing is Solr has to run to execute the Core creation in the entrypoint.

So I think we could just remove those lines. @florianalexandre what do you think?

xserna commented 5 years ago

Hi @Plopix sorry for the delay, I was on vacation. Please correct me if I'm wrong: the lines you referred are called only on ez init/create when creating the docker environment. But if you change the settings after that, you need to create the cores on service start (this is how I've found the issue, updating settings after environment was already created). I have an updated entrypoint.bash for the solr service that checks if any solr core is missing and if required starts a background solr, create cores, stop it from bg, and start on fg as a final step. Can try to add as PR if sounds interesting for others.

Regards,

Plopix commented 5 years ago

Hey @xserna, you are totally right. The trick you mentioned sounds exactly what eZ Launchpad needs. If you want to share it and become a eZ Launchpad contributor you are more than welcome!

If you don't have the time to do a PR just copy/paste here, and I will do the rest ;)

xserna commented 5 years ago

@Plopix PR #55 added :)

xserna commented 5 years ago

This issue is closed after the merge of #55