fix merge

This commit is contained in:
miloschwartz
2026-10-15 12:01:31 -04:00
parent 89f6748a1b
commit 1f1d3d7e0f
3 changed files with 4 additions and 11 deletions
-9
View File
@@ -11,21 +11,12 @@ function makeTarget(ip: string, siteType: string): TargetWithSite {
return {
targetId: 1,
resourceId: 1,
providerId: null,
siteId: 1,
ip,
port: 8080,
internalPort: 9000,
method: "http",
enabled: true,
health: "healthy",
path: null,
pathMatchType: null,
rewritePath: null,
rewritePathType: null,
priority: 100,
mode: "http",
authToken: null,
site: {
siteId: 1,
type: siteType,
+2 -2
View File
@@ -49,7 +49,7 @@ export function buildHttpLoadBalancerServers(targets: TargetWithSite[]) {
target.site.type === "wireguard"
) {
return {
url: `${target.method}://${formatEndpoint(target.ip, target.port)}`
url: `${target.method}://${formatEndpoint(target.ip!, target.port!)}`
};
} else if (target.site.type === "newt") {
const ip = target.site.subnet!.split("/")[0];
@@ -124,7 +124,7 @@ export function buildTcpUdpLoadBalancerServers(targets: TargetWithSite[]) {
target.site.type === "wireguard"
) {
return {
address: formatEndpoint(target.ip, target.port)
address: formatEndpoint(target.ip!, target.port!)
};
} else if (target.site.type === "newt") {
const ip = target.site.subnet!.split("/")[0];
+2
View File
@@ -33,6 +33,8 @@ export type ResourceWithTargets = Pick<
| "domainId"
| "enabled"
| "stickySession"
| "loadBalancingStrategy"
| "mtlsEnabled"
| "tlsServerName"
| "setHostHeader"
| "enableProxy"