npm package diff
Package: @forge/tunnel
Versions: 5.4.0-next.4 - 5.4.0-next.1-experimental-264fa0f
File: package/out/command/start-tunnel-command.js
Index: package/out/command/start-tunnel-command.js
===================================================================
--- package/out/command/start-tunnel-command.js
+++ package/out/command/start-tunnel-command.js
@@ -4,9 +4,8 @@
const tslib_1 = require("tslib");
const cli_shared_1 = require("@forge/cli-shared");
const runtime_1 = require("@forge/runtime");
const node_cache_1 = tslib_1.__importDefault(require("node-cache"));
-const portfinder_1 = require("portfinder");
const servers_1 = require("../servers");
const index_1 = require("../index");
class StartTunnelCommand {
getAppConfig;
@@ -57,10 +56,9 @@
};
startResourceBasedTunnelsServers = async (resourceDetails, options) => {
const portMap = options.resourcePortMap ?? JSON.parse(process.env.RESOURCE_PORT_MAP ?? '{}');
const { permissions = {}, remotes = [] } = await this.configFile.readConfig();
- const availablePort = await (0, portfinder_1.getPortPromise)({ port: 4000 });
- const cspReporterPort = process.env.CSP_REPORTER_PORT ? parseInt(process.env.CSP_REPORTER_PORT, 10) : availablePort;
+ const cspReporterPort = parseInt(process.env.CSP_REPORTER_PORT ?? '4000', 10);
if (resourceDetails.length === 0)
return [];
this.cspReporterServer = new servers_1.CspReporterServer(cspReporterPort, this.logger, new node_cache_1.default());
await this.cspReporterServer.start();