ieugen edited a comment on pull request #246:
URL: https://github.com/apache/ofbiz-framework/pull/246#issuecomment-758586824


   Hi @danwatford , 
   
   I think trying to meddle with those configs at build time is brittle and 
would complicate the build.
   I don't know about deploy via gradle, but to help with deploying via 
application plugin (ofbiz.tar) 
   it would help to have the ability to add things to the classpath.
   
   If you could add this to `build.gradle` then people can add files to 
`config/` and `lib-extra/` directories and they will be available for ofbiz 
when it starts.
   
   I've tested this and it works for my ofbiz docker build (I'm planning an 
article these next 2 days and will share it. Spoiler: it works on ARM - 
raspberry pi 4 ;) ).
   
   I'm also adding the database drivers post build to `lib-extra` . 
   
   That way I can keep the ofbiz source unchanged and still get what I need. 
   
   (I don't have windows to test the classpath ). 
   
   ```
   tasks.startScripts {
       doLast {
           // Alter the start script for Unix systems.
           unixScript.text =
                   unixScript.text.replace('CLASSPATH=$APP_HOME/lib',
                           
'CLASSPATH=$APP_HOME/config/:$APP_HOME/lib-extra/*:$APP_HOME/lib')
   
           // Alter the start script for Windows systems.
   //        windowsScript.text =
   //                windowsScript.text.replace('CLASSPATH=$APP_HOME/lib',
   //                        
'CLASSPATH=$APP_HOME\\conf\\:$APP_HOME/lib-extra/*:$APP_HOME/lib')
       }
   }
   ```


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to