Modify the unix script#3059
Conversation
Modifies the line containing `CLASSPATH=` in generated unix script file and add entries for 1. $APP_HOME/ext-lib/* - To be used to add extra jars to classpath 2. $APP_HOME/config - To be used to add custom application.conf
| } | ||
| } | ||
| } | ||
| } |
There was a problem hiding this comment.
I googled for a bit and stumbled upon:
startScripts {
classpath += files('ext-libs/*', 'config')
}There seems to be a possibility to do this other than manipulating raw lines (which feels a bit rough). I'd need to look further into this, since gradle seems to apply some sanitizing unfortunately.
There was a problem hiding this comment.
Thanks @markusthoemmes for looking into this. I also saw that but it does not work as expected. Have a look at links provided in #3057 for background and hence used this approach
There was a problem hiding this comment.
@chetanmeh oh sorry, should've checked. Yeah your observations are exactly the same as mine, so we're clear on that 👍
|
|
||
| // Get original line and append it | ||
| // with the configuration directory. | ||
| original += ":\$APP_HOME/ext-lib/*:\$APP_HOME/config" |
There was a problem hiding this comment.
Could use single quotes to circumenvent character escaping?
There was a problem hiding this comment.
Good point. This was leftover of previous attempt which was also using a variable for path separator. With that not used we can use single quote. Updated that.
…rojects like controller and invoker
markusthoemmes
left a comment
There was a problem hiding this comment.
Some spelling mistakes left. Thanks for adding documentation on this 👍
|
|
||
| ## Including the implementation | ||
|
|
||
| Base openwhisk docker images provide 2 extension points in classpath for including the implementation |
There was a problem hiding this comment.
- in the classpath
- missing
.at the end.
|
|
||
| ### Application Jars | ||
|
|
||
| The application jars can be added to `$APP_HOME/ext-lib` for e.g. in `openwhisk/controller` image the implementation jars can be added to `/controller/ext-lib` folder and for `openwhisk/invoker` they can be added to `/invoker/ext-lib` folder |
There was a problem hiding this comment.
- to
/controller/ext-libfolder - to
/invoker/ext-libfolder - Missing
.at the end.
|
|
||
| ### Application Configuration | ||
|
|
||
| The configuration files can be added to `$APP_HOME/config` folder |
There was a problem hiding this comment.
folder- Missing
.at the end.
|
Updated docs as per feedback |
Modifies the line containing `CLASSPATH=` in generated unix script file and add entries for 1. $APP_HOME/ext-lib/* - To be used to add extra jars to classpath 2. $APP_HOME/config - To be used to add custom application.conf
Modifies the line containing
CLASSPATH=in generated unix script file and add entries for$APP_HOME/ext-lib/*- To be used to add extra jars to classpath$APP_HOME/config- To be used to add custom application.confThis PR is for issue #3057