title: put a html file into a docker image and run a container
body: <p>I'm hitting an issue.</p>
  <p>I'm trying to copy an html file into a docker image and run a container with that image.</p>
  <p>This is my Dockerfile</p>
  <pre class="lang-sh prettyprint-override"><code>FROM php:7.0-apache
  
  COPY index.html /var/www/html/
  
  EXPOSE 80
  
  RUN echo &quot;ServerName localhost&quot; &gt;&gt; /etc/apache2/apache2.conf
  
  CMD [&quot;/usr/sbin/apache2ctl&quot;, &quot;-D&quot;, &quot;FOREGROUND&quot;]
  </code></pre>
  <p>This is my HTML file</p>
  <pre class="lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
     &lt;head&gt;
        &lt;title&gt;Page Title&lt;/title&gt;
     &lt;/head&gt;
     &lt;body&gt;
        &lt;h1 style=&quot;color: #5e9ca0;&quot;&gt;You can edit &lt;span style=&quot;color: #2b2301;&quot;&gt;this demo&lt;/span&gt; text!&lt;/h1&gt;
        &lt;h2 style=&quot;color: #2e6c80;&quot;&gt;How to use the editor:&lt;/h2&gt;
        &lt;h2 style=&quot;color: #2e6c80;&quot;&gt;Cleaning options.&lt;/h2&gt;
        &lt;p&gt;&amp;nbsp;&lt;/p&gt;
        &lt;p&gt;&lt;strong&gt;&amp;nbsp;&lt;/strong&gt;&lt;/p&gt;
     &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  <p>Note: I've put my html file in the same folder as my Dockerfile.</p>
  <p>I build my image <code>docker build -t my_2nd_img .</code> then I run it <code>docker run --name sec my_2nd_img</code>.</p>
  <p>Issue is I have a <code>404 page not found</code> when I tried to reach it on my browser with <code>http://localhost</code>.</p>
  <p>I tried to see if there was an issue with the logs by running <code>docker logs &lt;id_of_my_container&gt;</code></p>
  <p>Nothing in the logs, as you can see below.</p>
  <pre><code>[Sun Apr 11 17:36:06.140641 2021] [mpm_prefork:notice] [pid 8] AH00163: Apache/2.4.25 (Debian) PHP/7.0.33 configured -- resuming normal operations
  [Sun Apr 11 17:36:06.140806 2021] [core:notice] [pid 8] AH00094: Command line: '/usr/sbin/apache2 -D FOREGROUND'
  </code></pre>
  <p>Any ideas are welcomed as I do not see what is incorrect.</p>