Add jar to Apache Tomcat classpath #306
Replies: 1 comment
-
Writing a buildpack can be a simple as a couple shell scripts, one to detect and one to build. See if that is of interest, https://buildpacks.io/docs/for-buildpack-authors/tutorials/basic-buildpack/ You could also use an inline buildpack, which is a bit smaller. See https://buildpacks.io/docs/for-app-developers/how-to/build-inputs/use-inline-buildpacks/. In either case, this is how you'd go about setting the env variable: https://github.com/buildpacks/spec/blob/main/buildpack.md#provided-by-the-buildpacks The main reason for using a buildpack here is because you also need to supply the JAR file and ensure it's in the container. A buildpack can do that easily. |
Beta Was this translation helpful? Give feedback.
-
Is there any easier way to add a jar to Tomcat classpath in Tomcat buildpack.
I need to contribute a RewriteMap implementation class, which Tomcat rewrite valve can use to lookup keys.
Tomcat buildpack documentation specifies a BPI_TOMCAT_ADDITIONAL_JARS env variable, but apparently it's useful only for building other buildpacks. Looks like an overkill for contributing a single jar.
Please advise.
Beta Was this translation helpful? Give feedback.
All reactions