title: Docker tomcat WARNING: Unable to load server configuration from [/usr/local/tomcat/conf/server.xml]
body: <p>I have a slightly complicated setup. I first built and ran a tomcat docker container as root. I had mounted server.xml (as I had custom configuration). It ran fine and served our traffic for months.</p>
  
  <p>I then decided not to run it as root and created a user to run the docker container. I removed the previous docker container, including the docker tomcat image. And I built a new image and ran the tomcat container with the new user using --user $(id -u ). The server.xml is mounted, the file is owned by the new user I have created. However, the tomcat container wouldn't start. I see the error message below with no exception or stack trace:</p>
  
  <pre><code>Using CATALINA_BASE:   /usr/local/tomcat &lt;br&gt;
  Using CATALINA_HOME:   /usr/local/tomcat &lt;br&gt;
  Using CATALINA_TMPDIR: /usr/local/tomcat/temp&lt;br&gt;
  Using JRE_HOME:        /usr/lib/jvm/java-8-openjdk-amd64/jre&lt;br&gt;
  Using CLASSPATH:       /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar&lt;br&gt;
  tomcat WARNING: Unable to load server configuration from &gt;[/usr/local/tomcat/conf/server.xml]&lt;br&gt;
  SEVERE: Cannot start server. Server instance is not configured.&lt;br&gt;
  </code></pre>