You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "janhoy (via GitHub)" <gi...@apache.org> on 2023/02/09 18:19:10 UTC

[GitHub] [solr] janhoy opened a new pull request, #1346: SOLR-16457 Add symbolic link version of solr.install.dir to security.policy

janhoy opened a new pull request, #1346:
URL: https://github.com/apache/solr/pull/1346

   I.e. typically til will allow /opt/solr/... in addition to /opt/solr-X.Y.Z/...
   
   I file this PR on https://issues.apache.org/jira/browse/SOLR-16457 since it is related and still un-released.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


[GitHub] [solr] risdenk commented on a diff in pull request #1346: SOLR-16457 Add symbolic link version of solr.install.dir to security.policy

Posted by "risdenk (via GitHub)" <gi...@apache.org>.
risdenk commented on code in PR #1346:
URL: https://github.com/apache/solr/pull/1346#discussion_r1101861421


##########
solr/bin/solr.cmd:
##########
@@ -1397,15 +1397,15 @@ IF "%FG%"=="1" (
   "%JAVA%" %SERVEROPT% %SOLR_JAVA_MEM% %START_OPTS% ^
     -Dlog4j.configurationFile="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^
     -Dsolr.solr.home="%SOLR_HOME%" -Dsolr.install.dir="%SOLR_TIP%" -Dsolr.default.confdir="%DEFAULT_CONFDIR%" ^
-    -Djetty.port=%SOLR_PORT% -Djetty.home="%SOLR_SERVER_DIR%" ^
+    -Djetty.port=%SOLR_PORT% -Djetty.home="%SOLR_SERVER_DIR%" -Dsolr.install.symDir="%SOLR_TIP%" ^
     -Djava.io.tmpdir="%SOLR_SERVER_DIR%\tmp" -jar start.jar %SOLR_JETTY_CONFIG% "%SOLR_JETTY_ADDL_CONFIG%"
 ) ELSE (
   START /B "Solr-%SOLR_PORT%" /D "%SOLR_SERVER_DIR%" ^
     "%JAVA%" %SERVEROPT% %SOLR_JAVA_MEM% %START_OPTS% ^
     -Dlog4j.configurationFile="%LOG4J_CONFIG%" -DSTOP.PORT=!STOP_PORT! -DSTOP.KEY=%STOP_KEY% ^
     -Dsolr.log.muteconsole ^
     -Dsolr.solr.home="%SOLR_HOME%" -Dsolr.install.dir="%SOLR_TIP%" -Dsolr.default.confdir="%DEFAULT_CONFDIR%" ^
-    -Djetty.port=%SOLR_PORT% -Djetty.home="%SOLR_SERVER_DIR%" ^
+    -Djetty.port=%SOLR_PORT% -Djetty.home="%SOLR_SERVER_DIR%" -Dsolr.install.symDir="%SOLR_TIP%" ^

Review Comment:
   I think it would make more sense next to `solr.install.dir` on the line above similar to the `bin/solr` script. This goes for line 1400 as well.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


[GitHub] [solr] janhoy merged pull request #1346: SOLR-16457 Add symbolic link version of solr.install.dir to security.policy

Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy merged PR #1346:
URL: https://github.com/apache/solr/pull/1346


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


[GitHub] [solr] janhoy commented on pull request #1346: SOLR-16457 Add symbolic link version of solr.install.dir to security.policy

Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #1346:
URL: https://github.com/apache/solr/pull/1346#issuecomment-1424675324

   Found a bug while testing. Need to resolve `pwd -L` on the original script path, not on the already normalized physical `SOLR_TIP`. After fixing that it woks. I tested with:
   
   ```bash
   cd ~/git/solr/
   gw dev
   cd /tmp/
   # Create a symlink to solr to simulate how the installer does it, and the docker image
   ln -s ~/git/solr/solr/packaging/build/dev symdev
   cd symdev
   # add some lib folder to shared lib, using symlink path
   bin/solr -c -Dsolr.sharedLib=/tmp/symdev/modules/extraction/lib
   # Create collection with a config that contains /update/extract but no <lib> directives (hacked techproducts sample)
   bin/solr create -c tech -d /path/to/techproducts
   # Post a PDF, it will fail with classNotFound
   bin/post -c tech example/exampledocs/solr-word.pdf
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org