Add back port restrictions

This commit is contained in:
Owen
2026-08-06 14:55:07 -04:00
parent a4d77a4fd3
commit 751d1b083d
2 changed files with 12 additions and 6 deletions
@@ -605,7 +605,7 @@ export async function createSiteResource(
}
let tcpPortRangeStringAdjusted = tcpPortRangeString;
if (mode === "http") {
if (mode === "http" || mode === "inference") {
tcpPortRangeStringAdjusted = "443,80";
} else if (mode === "ssh") {
tcpPortRangeStringAdjusted = destinationPort
@@ -628,12 +628,14 @@ export async function createSiteResource(
aliasAddress,
tcpPortRangeString: tcpPortRangeStringAdjusted,
udpPortRangeString:
mode == "http" || mode == "ssh"
mode == "http" || mode == "ssh" || mode == "inference"
? ""
: udpPortRangeString,
disableIcmp:
disableIcmp ||
(mode == "http" || mode == "ssh" ? true : false), // default to true for http resources, otherwise false
(mode == "http" || mode == "ssh" || mode == "inference"
? true
: false), // default to true for http resources, otherwise false
domainId,
subdomain: finalSubdomain,
fullDomain,