|
|
@ -37,7 +37,7 @@ module.exports = function budoExpress(options = {}) {
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
if (process.env.BUDO_BUILD === "1") {
|
|
|
|
if (process.env.BUDO_BUILD === "1") {
|
|
|
|
bundle(context);
|
|
|
|
return bundle(context);
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
let productionHost = defaultValue(options.host, "::");
|
|
|
|
let productionHost = defaultValue(options.host, "::");
|
|
|
|
let developmentHost = (options.allowUnsafeHost) ? productionHost : "127.0.0.1";
|
|
|
|
let developmentHost = (options.allowUnsafeHost) ? productionHost : "127.0.0.1";
|
|
|
@ -46,12 +46,12 @@ module.exports = function budoExpress(options = {}) {
|
|
|
|
let developmentMode = getDevelopmentMode(developmentModeSetting);
|
|
|
|
let developmentMode = getDevelopmentMode(developmentModeSetting);
|
|
|
|
|
|
|
|
|
|
|
|
if (developmentMode) {
|
|
|
|
if (developmentMode) {
|
|
|
|
developmentServer({
|
|
|
|
return developmentServer({
|
|
|
|
... context,
|
|
|
|
... context,
|
|
|
|
host: developmentHost
|
|
|
|
host: developmentHost
|
|
|
|
});
|
|
|
|
});
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
productionServer({
|
|
|
|
return productionServer({
|
|
|
|
... context,
|
|
|
|
... context,
|
|
|
|
host: productionHost
|
|
|
|
host: productionHost
|
|
|
|
});
|
|
|
|
});
|
|
|
|