Skip to content

Commit 99d00c9

Browse files
author
Bryan Kendall
committed
slightly better check for 443
1 parent 24af0ba commit 99d00c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/models/redis/hosts.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ Hosts.prototype.upsertHostForContainerPort =
9898
var actualPort = container.ports[containerPort][0].HostPort;
9999
var parsedDockerHost = url.parse(container.dockerHost);
100100
var backendUrl = url.format({
101-
protocol: (containerPort.toString() === '443') ? 'https:' : 'http:',
101+
protocol: /^443\/.+/.test(containerPort) ? 'https:' : 'http:',
102102
slashes: true,
103103
hostname: parsedDockerHost.hostname,
104104
port: actualPort

0 commit comments

Comments
 (0)