Browse Source

Build fix.

pull/509/head
Sebastian 6 years ago
parent
commit
593f2d6196
  1. 12
      frontend/app-config/webpack.config.js

12
frontend/app-config/webpack.config.js

@ -10,6 +10,14 @@ function root() {
return path.join.apply(path, [appRoot].concat(newArgs));
};
function tryGetFile(file) {
try {
return fs.readFileSync(path.resolve(__dirname, file));
} catch (ex) {
return undefined;
}
}
const plugins = {
// https://github.com/webpack-contrib/mini-css-extract-plugin
MiniCssExtractPlugin: require('mini-css-extract-plugin'),
@ -211,8 +219,8 @@ module.exports = function (env) {
'Access-Control-Allow-Origin': '*'
},
https: {
key: fs.readFileSync(path.resolve(__dirname, 'localhost-key.pem')),
cert: fs.readFileSync(path.resolve(__dirname, 'localhost.pem')),
key: tryGetFile('localhost-key.pem'),
cert: tryGetFile('localhost.pem'),
},
historyApiFallback: true,
}

Loading…
Cancel
Save