<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/zeit/next.js/issues?q=is%3Aissue">issues</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<p dir="auto">Sorry in advance if I didn't find any informations. If this behavior is actually possible, please specify it in the README.</p>
<h2 dir="auto">Expected Behavior</h2>
<p dir="auto">Being able to use an IP (10.x.x.x) instead of localhost while using next dev.</p>


<h2 dir="auto">Current Behavior</h2>
<p dir="auto">Dev server launch on localhost.</p>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/zeit/next.js/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h2 dir="auto">Expected Behavior</h2>
<p dir="auto">I try to do</p>
<ul dir="auto">
<li>Run production build use custom server with express</li>
<li>Jest Test</li>
</ul>
<h2 dir="auto">Current Behavior</h2>
<ul dir="auto">
<li>I can run next in development mode with <code class="notranslate">node server.js</code></li>
<li>Jest Test ( Jest is ok, run normally)</li>
</ul>
<p dir="auto">After next build, I try to start custom server with express with<br>
<code class="notranslate">NODE_ENV=production node server.js</code></p>
<p dir="auto">This is log</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TypeError: Cannot read property 'toLowerCase' of undefined
    at a.renderDOM (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:391)
    at a.render (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:228)
    at a.read (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:35:250)
    at renderToStaticMarkup (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:44:75)
    at _callee3$ (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/next/dist/server/render.js:223:100)
    at tryCatch (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:62:40)
    at Generator.invoke [as _invoke] (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:296:22)
    at Generator.prototype.(anonymous function) [as next] (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:114:21)
    at step (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
    at /home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/babel-runtime/helpers/asyncToGenerator.js:28:13
    at &lt;anonymous&gt;"><pre class="notranslate"><code class="notranslate">TypeError: Cannot read property 'toLowerCase' of undefined
    at a.renderDOM (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:391)
    at a.render (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:228)
    at a.read (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:35:250)
    at renderToStaticMarkup (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:44:75)
    at _callee3$ (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/next/dist/server/render.js:223:100)
    at tryCatch (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:62:40)
    at Generator.invoke [as _invoke] (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:296:22)
    at Generator.prototype.(anonymous function) [as next] (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/regenerator-runtime/runtime.js:114:21)
    at step (/home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
    at /home/naijab/freelance/neogamer/frontend/gamerui/src/node_modules/babel-runtime/helpers/asyncToGenerator.js:28:13
    at &lt;anonymous&gt;
</code></pre></div>
<h2 dir="auto">Steps to Reproduce (for bugs)</h2>
<ol dir="auto">
<li><code class="notranslate">yarn build</code> --&gt; <code class="notranslate">next build</code></li>
<li><code class="notranslate">yarn start</code> --&gt; <code class="notranslate">NODE_ENV=production node server.js</code></li>
<li>Point a browser to <a href="http://localhost:3000" rel="nofollow">http://localhost:3000</a></li>
<li>Show 500 errors flash An unexpected error has occurred.</li>
</ol>
<h2 dir="auto">Context</h2>
<p dir="auto">When start production build, internal server errors cause an unwanted flash of content.</p>


<h2 dir="auto">Your Environment</h2>

<table role="table">
<thead>
<tr>
<th>Tech</th>
<th>Version</th>
</tr>
</thead>
<tbody>
<tr>
<td>next</td>
<td>5.0</td>
</tr>
<tr>
<td>node</td>
<td>8.9</td>
</tr>
<tr>
<td>OS</td>
<td>Ubuntu</td>
</tr>
<tr>
<td>browser</td>
<td>Chrome 64</td>
</tr>
<tr>
<td>etc</td>
<td></td>
</tr>
</tbody>
</table>