[ 
https://issues.apache.org/jira/browse/S2GRAPH-200?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Chul Kang updated S2GRAPH-200:
------------------------------
    Summary: docker image could not include extra jars  (was: docker image does 
not support JDBC driver)

> docker image could not include extra jars
> -----------------------------------------
>
>                 Key: S2GRAPH-200
>                 URL: https://issues.apache.org/jira/browse/S2GRAPH-200
>             Project: S2Graph
>          Issue Type: Improvement
>            Reporter: Chul Kang
>            Priority: Minor
>
> I created a docker image with the following command, and then launched it as 
> below with jdbc driver option.
> {code:java}
> // build docker image
> > sbt "project s2rest_play" 'set version := "latest"' docker:publishLocal
> // docker run
> docker run -it s2rest_play:latest -Dhttp.port=9000 
> -Ddb.default.driver=com.mysql.jdbc.Driver 
> -Ddb.default.url=jdbc:mysql://localhost:3306 ...
> {code}
>  
> ClassNotFoundException occurred.
> {code:java}
> Oops, cannot start the server.
> java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
> at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> {code}
> By default, mysql-connector is not included. So if we want to include the jar 
> in the classpath in current image, we need to rebuild the image.
> I think it would be nice to support the external jar to refer to the docker 
> image from outside.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to