title: reload nginx container on content change
body: <p>I'm setting up nginx server using Docker. If I add a new file/directory to all-html,is that content need to loaded to nginx dynamically(without reloading the nginx)?</p>
  
  <p>I can able to load the new contents only If rebuilding the image again (without cache). is there any way to setup the nginx configuration to dynamically load the content without rebuilding the docker image?</p>
  
  <p>Dockerfile</p>
  
  <pre><code>FROM ubuntu:latest
  
  RUN apt-get update
  RUN apt-get install -y nginx
  RUN rm /etc/nginx/nginx.conf
  
  ADD nginx.conf /etc/nginx/
  
  ADD web /usr/share/nginx/html/
  ADD web /var/www/html/
  
  RUN echo "daemon off;" &gt;&gt; /etc/nginx/nginx.conf
  EXPOSE 90
  
  CMD service nginx start
  </code></pre>
  
  <p>nginx.conf</p>
  
  <pre><code>worker_processes 1;
  
  events { worker_connections 1024; }
  
  http {
      include    mime.types;
      sendfile on;
      server {
          root /usr/share/nginx/html/;
          index index.html;
          server_name localhost;
          listen 90;
          location /all-html {
                 autoindex on;
          }
      }
  
  }
  </code></pre>
  
  <pre><code>ls  web/
  all-html    icons       index.html  mime.types
  </code></pre>
  
  <pre><code>ls  web/all-html/
  1.html  ntf.zip 2.html
  </code></pre>