title: class path resource [public] cannot be resolved to URL because it does not exist (SPARK)
body: <p>I'm obtaining the following error when I run my server in Spark:</p>
  
  <p><a href="https://i.stack.imgur.com/swNe5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/swNe5.png" alt="enter image description here"></a></p>
  
  <p>My main looks like that:</p>
  
  <p><a href="https://i.stack.imgur.com/PEegX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PEegX.png" alt="enter image description here"></a></p>
  
  <p>And this is my project structure</p>
  
  <p><a href="https://i.stack.imgur.com/MDxgX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/MDxgX.png" alt="enter image description here"></a></p>
  
  <p>And I added this to build in pom.xml file:</p>
  
  <pre><code>        &lt;resources&gt;
              &lt;resource&gt;
                  &lt;filtering&gt;false&lt;/filtering&gt;
                  &lt;directory&gt;src/main/resources&lt;/directory&gt;
              &lt;/resource&gt;
          &lt;/resources&gt;
  </code></pre>
  
  <p>Before I added this lines, I couldn't render index.html because it couldn't find it in resources folder, but after I added this to pom.xml, it found it and it's rendered correctly.</p>
  
  <p>Server is running fine, but I can't set the location of static files to folder '/public', that is inside resources, so when I try to load 'favicon.png', from index.html, it try to find it inside '/index/favicon.png'but I would want to go it to 'resources/public/favicon.png'</p>