I've done this without changing my configuration. In fact, it only took me one line of code, to be put in the initialize
method of my Application
class:
bootstrap.addBundle(new AssetsBundle("/app", "/", "index.html", "static"));
Which basically says to serve anything under /app
inside my JAR file under the URL pattern /
, with index.html
as the default file. This bundle will be named static, but you could pick whatever name you like.
Note that I'm using version 0.7.0-rc2 of Dropwizard, I'm not sure whether it works for earlier versions as well.