mirror of
https://github.com/fosrl/pangolin.git
synced 2026-08-27 22:44:59 +02:00
Send updates when the full domain changes
This commit is contained in:
@@ -730,8 +730,10 @@ export async function handleMessagingForUpdatedSiteResource(
|
|||||||
updatedSiteResource.destinationPort;
|
updatedSiteResource.destinationPort;
|
||||||
const aliasChanged =
|
const aliasChanged =
|
||||||
existingSiteResource &&
|
existingSiteResource &&
|
||||||
(existingSiteResource.alias !== updatedSiteResource.alias ||
|
existingSiteResource.alias !== updatedSiteResource.alias;
|
||||||
existingSiteResource.fullDomain !== updatedSiteResource.fullDomain); // because the full domain gets sent down to the stuff as an alias
|
const fullDomainChanged =
|
||||||
|
existingSiteResource &&
|
||||||
|
existingSiteResource.fullDomain !== updatedSiteResource.fullDomain;
|
||||||
const portRangesChanged =
|
const portRangesChanged =
|
||||||
existingSiteResource &&
|
existingSiteResource &&
|
||||||
(existingSiteResource.tcpPortRangeString !==
|
(existingSiteResource.tcpPortRangeString !==
|
||||||
@@ -746,6 +748,7 @@ export async function handleMessagingForUpdatedSiteResource(
|
|||||||
if (
|
if (
|
||||||
destinationChanged ||
|
destinationChanged ||
|
||||||
aliasChanged ||
|
aliasChanged ||
|
||||||
|
fullDomainChanged ||
|
||||||
portRangesChanged ||
|
portRangesChanged ||
|
||||||
destinationPortChanged
|
destinationPortChanged
|
||||||
) {
|
) {
|
||||||
@@ -766,6 +769,7 @@ export async function handleMessagingForUpdatedSiteResource(
|
|||||||
if (
|
if (
|
||||||
destinationChanged ||
|
destinationChanged ||
|
||||||
portRangesChanged ||
|
portRangesChanged ||
|
||||||
|
fullDomainChanged || // if the domain changes we need to update the certs and stuff
|
||||||
destinationPortChanged
|
destinationPortChanged
|
||||||
) {
|
) {
|
||||||
const oldTargets = await generateSubnetProxyTargetV2(
|
const oldTargets = await generateSubnetProxyTargetV2(
|
||||||
@@ -844,7 +848,7 @@ export async function handleMessagingForUpdatedSiteResource(
|
|||||||
])
|
])
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
aliasChanged
|
aliasChanged || fullDomainChanged // the full domain is sent down as an alias
|
||||||
? {
|
? {
|
||||||
oldAliases: generateAliasConfig([
|
oldAliases: generateAliasConfig([
|
||||||
existingSiteResource
|
existingSiteResource
|
||||||
|
|||||||
Reference in New Issue
Block a user