mirror of
https://github.com/fosrl/pangolin.git
synced 2026-05-26 18:52:41 +00:00
Add port and icmp information to api endpoint
This commit is contained in:
@@ -156,6 +156,9 @@ export async function getUserResources(
|
|||||||
enabled: boolean;
|
enabled: boolean;
|
||||||
alias: string | null;
|
alias: string | null;
|
||||||
aliasAddress: string | null;
|
aliasAddress: string | null;
|
||||||
|
tcpPortRangeString: string | null;
|
||||||
|
udpPortRangeString: string | null;
|
||||||
|
disableIcmp: boolean | null;
|
||||||
}> = [];
|
}> = [];
|
||||||
if (accessibleSiteResourceIds.length > 0) {
|
if (accessibleSiteResourceIds.length > 0) {
|
||||||
siteResourcesData = await db
|
siteResourcesData = await db
|
||||||
@@ -170,7 +173,10 @@ export async function getUserResources(
|
|||||||
fullDomain: siteResources.fullDomain,
|
fullDomain: siteResources.fullDomain,
|
||||||
enabled: siteResources.enabled,
|
enabled: siteResources.enabled,
|
||||||
alias: siteResources.alias,
|
alias: siteResources.alias,
|
||||||
aliasAddress: siteResources.aliasAddress
|
aliasAddress: siteResources.aliasAddress,
|
||||||
|
tcpPortRangeString: siteResources.tcpPortRangeString,
|
||||||
|
udpPortRangeString: siteResources.udpPortRangeString,
|
||||||
|
disableIcmp: siteResources.disableIcmp
|
||||||
})
|
})
|
||||||
.from(siteResources)
|
.from(siteResources)
|
||||||
.where(
|
.where(
|
||||||
@@ -260,6 +266,9 @@ export async function getUserResources(
|
|||||||
enabled: siteResource.enabled,
|
enabled: siteResource.enabled,
|
||||||
alias: siteResource.alias,
|
alias: siteResource.alias,
|
||||||
aliasAddress: siteResource.aliasAddress,
|
aliasAddress: siteResource.aliasAddress,
|
||||||
|
tcpPortRangeString: siteResource.tcpPortRangeString,
|
||||||
|
udpPortRangeString: siteResource.udpPortRangeString,
|
||||||
|
disableIcmp: siteResource.disableIcmp,
|
||||||
type: "site" as const
|
type: "site" as const
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
@@ -302,6 +311,9 @@ export type GetUserResourcesResponse = {
|
|||||||
destination: string;
|
destination: string;
|
||||||
mode: string;
|
mode: string;
|
||||||
protocol: string | null;
|
protocol: string | null;
|
||||||
|
tcpPortRangeString: string | null;
|
||||||
|
udpPortRangeString: string | null;
|
||||||
|
disableIcmp: boolean | null;
|
||||||
ssl: boolean;
|
ssl: boolean;
|
||||||
fullDomain: string | null;
|
fullDomain: string | null;
|
||||||
enabled: boolean;
|
enabled: boolean;
|
||||||
|
|||||||
Reference in New Issue
Block a user