title: How to deploy an Angular 4 app with server-side rendering on prod server
body: <p>I've been looking for about 3 hours for hosting an Angular 4 app on a server with "server-side rendering" enabled. 
  For note - I have a AWS server which has Apache installed (Ubuntu).</p>
  
  <p>First of all, I already know how can we host an Angular 4 app (without server-side rendering). But here my major concern is that I want to enable my app to be enabled for - server-side rendering.</p>
  
  <p>In my local, I use <code>npm start</code> command, which automatically serves the app (with server-side rendering enabled) on - <code>http://localhost:4000</code></p>
  
  <p>My <code>package.json</code> file looks like this:</p>
  
  <pre><code>...
  "scripts": {
      "serve": "ng serve",
      "prestart": "ng build --prod &amp;&amp; ngc &amp;&amp; webpack",
      "start": "node dist/server.js",
      "build": "ng build"
  },
  ...
  </code></pre>
  
  <p>These all commands are working fine. But I'm confused that should I again run</p>
  
  <pre><code>npm start
  </code></pre>
  
  <p>on a production server, so that it also requires <code>node_modules</code> to install. Which doesn't seems the right way to me?</p>
  
  <p>Can anyone please help me with hosting my app with "server-side rendering" enabled.</p>