• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Orckestra / orc-scripts / 92132

15 Nov 2023 09:44PM UTC coverage: 35.465% (+0.3%) from 35.144%
92132

push

Azure Pipelines

web-flow
Fix local web server (#1192)

#74976

153 of 418 branches covered (0.0%)

Branch coverage included in aggregate %.

0 of 5 new or added lines in 1 file covered. (0.0%)

274 of 786 relevant lines covered (34.86%)

4.31 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/scripts/start.js
NEW
1
const DevServer = require("webpack-dev-server");
×
2
const webpack = require("webpack");
×
3

4
const HOST = process.env.HOSTNAME || "localhost";
×
5

6
const args = process.argv.slice(2);
×
7
const argPort = args.indexOf("--port") !== -1 ? args[args.indexOf("--port") + 1] : null;
×
8
const PORT = argPort || process.env.PORT || 5000;
×
9

10
const config = require("../config/webpack.config.js");
×
11
const options = {
×
12
        historyApiFallback: true,
13
        hot: "only",
14
        port: PORT,
15
        host: HOST,
16
        static: './dist',
17
        devMiddleware: {
18
                publicPath: process.env.WEBPACK_PUBLIC_PATH || "/",
×
19
        },
20
};
21

22
if (HOST !== "localhost") {
×
23
        options.public = HOST;
×
24
}
25
if (HOST !== "localhost" || args.indexOf("--https") !== -1 || process.env.HTTPS) {
×
NEW
26
        options.server = 'https';
×
27
}
28

29
const compiler = webpack(config);
×
30

NEW
31
const server = new DevServer(options, compiler);
×
32

NEW
33
(async () => {
×
NEW
34
        await server.start();
×
35
})();
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc