Minimal edits made, but not working atm

This commit is contained in:
John Furrow
2017-07-14 05:49:14 -07:00
parent 3788a63f2c
commit b577b7087b
17 changed files with 15969 additions and 17 deletions
+5 -3
View File
@@ -31,6 +31,8 @@ const paths = require('../config/paths');
const config = require('../config/webpack.config.dev');
const createDevServerConfig = require('../config/webpackDevServer.config');
const userConfig = require('../../config');
const useYarn = fs.existsSync(paths.yarnLockFile);
const isInteractive = process.stdout.isTTY;
@@ -40,8 +42,8 @@ if (!checkRequiredFiles([paths.appHtml, paths.appIndexJs])) {
}
// Tools like Cloud9 rely on this.
const DEFAULT_PORT = parseInt(process.env.PORT, 10) || 3000;
const HOST = process.env.HOST || '0.0.0.0';
const DEFAULT_PORT = parseInt(process.env.DEV_SERVER_PORT, 10) || 4200;
const HOST = process.env.DEV_SERVER_HOST || '0.0.0.0';
// We attempt to use the default port but if it is busy, we offer the user to
// run on a different port. `detect()` Promise resolves to the next free port.
@@ -51,7 +53,7 @@ choosePort(HOST, DEFAULT_PORT)
// We have not found a port.
return;
}
const protocol = process.env.HTTPS === 'true' ? 'https' : 'http';
const protocol = process.env.DEV_SERVER_HTTPS === 'true' ? 'https' : 'http';
const appName = require(paths.appPackageJson).name;
const urls = prepareUrls(protocol, HOST, port);
// Create a webpack compiler that is configured with custom messages.