title: issues configuring nginx with node.js app
body: <p>Trying to get nginx to proxy my node.js app and use a domain with it. I'm going to have many domains mapped to the server so i'm using separate <code>.conf</code> files for each server block. The issue i'm having right now is that I can only seem to get the default nginx page to show up when i go to the domain. I'll try to explain the current setup as clearly as possible, and if you need any more information please let me know.</p>
  
  <p><strong>nginx.conf changes</strong></p>
  
  <p>I set the root path to where my apps files are, <code>root /var/www;</code> so for example, an app would be deployed to the folder <code>/var/www/example.com</code>.</p>
  
  <p><strong>server block config</strong></p>
  
  <p>I created a new file for the server block <code>/etc/nginx/conf.d/example_com.conf</code> which contains</p>
  
  <pre><code>server
  {
  listen 80;
  listen [::]:80;
  server_name example.com www.example.com;
  
  location /var/www
  {
      proxy_pass http://localhost:3103;
      include /etc/nginx/proxy_params;
  }
  }
  </code></pre>
  
  <p>please note that going to my <a href="http://myip:3103" rel="nofollow noreferrer">http://myip:3103</a> renders the app as it should and the file <code>/etc/nginx/proxy_params</code> contains</p>
  
  <pre><code>proxy_buffers 16 32k;
      proxy_buffer_size 64k;
      proxy_busy_buffers_size 128k;
      proxy_cache_bypass $http_pragma $http_authorization;
      proxy_connect_timeout 59s;
      proxy_hide_header X-Powered-By;
      proxy_http_version 1.1;
      proxy_ignore_headers Cache-Control Expires;
      proxy_next_upstream error timeout invalid_header http_500 http_502 http_503 http_504 http_404;
      proxy_no_cache $http_pragma $http_authorization;
      proxy_pass_header Set-Cookie;
      proxy_read_timeout 600;
      proxy_redirect off;
      proxy_send_timeout 600;
      proxy_temp_file_write_size 64k;
      proxy_set_header Accept-Encoding '';
      proxy_set_header Cookie $http_cookie;
      proxy_set_header Host $host;
      proxy_set_header Proxy '';
      proxy_set_header Referer $http_referer;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Host $host;
      proxy_set_header X-Forwarded-Server $host;
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-Proto $scheme;
      proxy_set_header X-Original-Request $request_uri;
  </code></pre>
  
  <p>Is there anything I am doing wrong here? Do you need any more info? Please let me know! nginx is pretty new for me and i feel like i'm super close i'm just note understanding something. Thanks!</p>