title: logback externalization
body: <p>Currently I have logback configuration file i.e <code>logback.xml</code>  which is <code>src/main/resources</code>. I want to set the logging level but i want control outside of war.</p>
  <p>One solution which i could think of is to externalize it in properties file, load it on server startup and substitute the placeholder. Is there any better way of doing it ? Can't we keep <code>logback.xml</code> outside of war file ?</p>
  <pre class="lang-xml prettyprint-override"><code>    &lt;configuration&gt;
      &lt;appender name=&quot;FILE&quot; class=&quot;ch.qos.logback.core.rolling.RollingFileAppender&quot;&gt;
          &lt;file&gt;${catalina.base}/logs/logFile.log&lt;/file&gt;
          &lt;rollingPolicy class=&quot;ch.qos.logback.core.rolling.TimeBasedRollingPolicy&quot;&gt;
              &lt;!-- daily rollover --&gt;
              &lt;fileNamePattern&gt;logFile.%d{yyyy-MM-dd}.log&lt;/fileNamePattern&gt;
              &lt;!-- keep 7 days' worth of history --&gt;
              &lt;maxHistory&gt;7&lt;/maxHistory&gt;
          &lt;/rollingPolicy&gt;
          &lt;encoder&gt;
              &lt;pattern&gt;%date [%thread] %-5level %logger{35} - %msg%n&lt;/pattern&gt;
          &lt;/encoder&gt;
      &lt;/appender&gt;
      
      &lt;root level=&quot;DEBUG&quot;&gt;
          &lt;appender-ref ref=&quot;FILE&quot;/&gt;
      &lt;/root&gt;
  &lt;/configuration&gt;
  </code></pre>