Issue 1:
NPM run dev throws an error

Example name

with-apollo-and-redux

Describe the bug

According to this example repo, after using npx and npm install, cant run npm run dev and it throws this error:

[ error ] ./node_modules/next/dist/client/dev/amp-dev.js Error: [BABEL] ...\with-apollo-and-redux-app\node_modules\next\dist\client\dev\amp-dev.js: Cannot find module './src/data'

Require stack: ...\with-apollo-and-redux-app\node_modules\core-js-compat\helpers.js

...\with-apollo-and-redux-app\node_modules\core-js-compat\get-modules-list-for-target-version.js

...\with-apollo-and-redux-app\node_modules\@babel\preset-env\lib\polyfills\corejs3\usage-plugin.js

...\with-apollo-and-redux-app\node_modules\@babel\preset-env\lib\index.js

...\with-apollo-and-redux-app\node_modules\next\dist\build\babel\preset.js

...\with-apollo-and-redux-app\node_modules\next\dist\build\webpack\loaders\next-babel-loader.js

...\with-apollo-and-redux-app\node_modules\loader-runner\lib\loadLoader.js

...\with-apollo-and-redux-app\node_modules\loader-runner\lib\LoaderRunner.js

...\with-apollo-and-redux-app\node_modules\webpack\lib\NormalModule.js

...\with-apollo-and-redux-app\node_modules\webpack\lib\NormalModuleFactory.js

...\with-apollo-and-redux-app\node_modules\webpack\lib\Compiler.js

...\with-apollo-and-redux-app\node_modules\webpack\lib\webpack.js

...\with-apollo-and-redux-app\node_modules\next\dist\server\hot-reloader.js

...\with-apollo-and-redux-app\node_modules\next\dist\server\next-dev-server.js

...\with-apollo-and-redux-app\node_modules\next\dist\server\next.js

...\with-apollo-and-redux-app\node_modules\next\dist\server\lib\start-server.js

...\with-apollo-and-redux-app\node_modules\next\dist\cli\next-dev.js

...\with-apollo-and-redux-app\node_modules\next\dist\bin\next

But in next@9.1.3 there is no issue and its working well.

To Reproduce

Steps to reproduce the behavior, please provide code snippets or a repository:

Run npx create-next-app --example with-apollo-and-redux with-apollo-and-redux-app

Run cd with-apollo-and-redux-app

Run npm install

Run npm run dev

The error shown in command prompt

Expected behavior

npm dev running on http://localhost:3000 ....

System information

OS: Windows 10

Version of Next.js: 9.1.4

Issue 2:
Bug report

Describe the bug

I have installed version 9.1.4 of next and now my Docker images don't build anymore! I am getting the following error.

However when I run the next build command from my own terminal it works fine so it is only happening for the Docker setup.

Error

...
> frontend@1.0.0 build /usr/src/app
> next build

Creating an optimized production build...
Attention: Next.js now collects completely anonymous telemetry regarding usage.
This information is used to shape Next.js' roadmap and prioritize features.
You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL:
https://nextjs.org/telemetry

Failed to compile.

./node_modules/next/dist/client/next.js
Error: Cannot find module './src/data'
Require stack:
- /usr/src/app/node_modules/core-js-compat/helpers.js
- /usr/src/app/node_modules/core-js-compat/get-modules-list-for-target-version.js
- /usr/src/app/node_modules/@babel/preset-env/lib/polyfills/corejs3/usage-plugin.js
- /usr/src/app/node_modules/@babel/preset-env/lib/index.js
- /usr/src/app/node_modules/@babel/core/lib/config/files/plugins.js
- /usr/src/app/node_modules/@babel/core/lib/config/files/index.js
- /usr/src/app/node_modules/@babel/core/lib/index.js
- /usr/src/app/node_modules/babel-loader/lib/index.js
- /usr/src/app/node_modules/next/dist/build/webpack/loaders/next-babel-loader.js
- /usr/src/app/node_modules/loader-runner/lib/loadLoader.js
- /usr/src/app/node_modules/loader-runner/lib/LoaderRunner.js
- /usr/src/app/node_modules/next/node_modules/webpack/lib/NormalModule.js
- /usr/src/app/node_modules/next/node_modules/webpack/lib/NormalModuleFactory.js
- /usr/src/app/node_modules/next/node_modules/webpack/lib/Compiler.js
- /usr/src/app/node_modules/next/node_modules/webpack/lib/webpack.js
- /usr/src/app/node_modules/next/dist/build/compiler.js
- /usr/src/app/node_modules/next/dist/build/index.js
- /usr/src/app/node_modules/next/dist/cli/next-build.js
- /usr/src/app/node_modules/next/dist/bin/next

> Build error occurred
Error: > Build failed because of webpack errors
at build (/usr/src/app/node_modules/next/dist/build/index.js:9:900)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! frontend@1.0.0 build: `next build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the frontend@1.0.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2019-12-02T19_02_50_506Z-debug.log
ERROR: Service 'frontend' failed to build: The command '/bin/sh -c npm run build' returned a non-zero code: 1

System information

OS: Windows 10 Home

Version of Next.js: 9.1.4