mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-22 18:29:19 +02:00
Move endpoint to per site
This commit is contained in:
parent
d1404a2b07
commit
1a9de1e5c5
7 changed files with 208 additions and 108 deletions
|
@ -157,9 +157,6 @@ export const handleGetConfigMessage: MessageHandler = async (context) => {
|
|||
if (!client.clients.subnet) {
|
||||
return false;
|
||||
}
|
||||
if (!client.clients.endpoint) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
})
|
||||
.map(async (client) => {
|
||||
|
@ -215,7 +212,7 @@ export const handleGetConfigMessage: MessageHandler = async (context) => {
|
|||
allowedIps: [`${client.clients.subnet.split("/")[0]}/32`], // we want to only allow from that client
|
||||
endpoint: client.clientSites.isRelayed
|
||||
? ""
|
||||
: client.clients.endpoint! // if its relayed it should be localhost
|
||||
: client.clientSites.endpoint! // if its relayed it should be localhost
|
||||
};
|
||||
})
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue