Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-15001

Docker: require init_var_solr.sh; don't init in Dockerfile

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 9.0
    • Docker
    • None

    Description

      I propose removing initialization of /var/solr from the Dockerfile, thus leaving only init_var_solr to do this. The fact that it's in two places means that the image has two solr.xml, two zoo.cfg, two log4j2.xml. This initialization itself must be maintained twice. That leads to confusion (it did with my colleagues and I) about which copy is going to be used. Imagine you are basing your company Solr Dockerfile on top of this one (i.e. official is the FROM) and need to do modifications. Do you modify /opt/solr/server/solr/solr.xml? Surprise surprise, sometimes it is copied to /var/solr/data/ by the init_var_solr script but sometimes it isn't because the Dockerfile here will do it, thus ignoring the customizations made to solr.xml in the next image layer.

      After making this change, our wonderful tests exposed that solr-demo wasn't invoking init_var_solr.

      THIS ISSUE IS COPIED FROM https://github.com/docker-solr/docker-solr/pull/354

      Attachments

        Issue Links

          Activity

            People

              dsmiley David Smiley
              dsmiley David Smiley
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 10m
                  1h 10m