I am trying to build an executeable JAR with a custom config file.
In Eclpise all is working fine but in the jar file the config file is missing.
I tried it in different ways. I put the application.conf in directory "Conf" and in "Resources". In addition to that I tried with following Statements in the code-section.
Does anyone have an Idea?
PS. The application.conf of Jooby is based on this:
https://github.com/lightbend/config
PS2:
I let the config write out to the console. How expected, in Eclipse all custom settings are set. In my Jar File the Configuration only contains things like port and name of application and tons of system settings (Java version, Path xyz, ...). So it does not merge my custom config settings to the system-settings :(
//Config conf = ConfigFactory.parseResources("application.conf");
Config conf = require(Config.class);
//Config conf = ConfigFactory.load();
//Config conf = App.class.getResourceAsStream("application.conf");