solr: add -server flag and JAVA_OPTS env variable

Closes #18163.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>