Commit graph

35 commits

Author SHA1 Message Date
abhishek9686
7e0ff17420 validate egress ranges with metric 2025-03-03 11:33:46 +04:00
Abhishek K
48535f7ef1
NET-1956: Async Node Status API (#3341)
* add node status api

* upsate node status api to return map data

* resolve merge conflicts
2025-02-24 08:48:24 +03:00
Yabin Ma
1d9e0f71df
add format int64 for swagger doc (#3247)
* add format int64 for swagger doc

* add format int64 for swagger doc

* add global override

* swagger doc update

* add new line for .swaggo file
2024-12-12 09:52:52 +04:00
Abhishek K
31c2311bef
NET-1782: Fetch Node Connection Status from metrics (#3237)
* add live status of node

* handle static node status

* add public IP field to server configuration

* get public Ip from config

* improve node status logic

* improvise status check

* use only checkin status on old nodes

---------

Co-authored-by: the_aceix <aceixsmartx@gmail.com>
2024-12-10 10:46:05 +04:00
abhishek9686
6c1208ad81 resolve merge conflicts 2024-10-17 15:15:54 +04:00
abhishek9686
6ccafe82ed set static nodes to list 2024-10-15 19:36:46 +04:00
abhishek9686
04b8737a02 move tags to node model 2024-09-22 13:37:58 +04:00
Max Ma
189ac27527
NET-1509:add ingresspersistentkeepalive and ingressmtu for extClient/RAC config (#3107)
* add ingresspersistentkeepalive and ingressmtu for extClient/RAC config

* add ingressmtu and PKA in api response

* add pka and mtu in api/nodes PUT call

* add default value for PKA and mtu for extClients
2024-09-12 12:19:27 +04:00
Aceix
2de3fde872
fix(NET-1280): remove RAG metadata length restriction (#2990) 2024-07-05 15:54:05 +05:30
Aceix
abf3f4f55d
feat(NET-1106): support additional RAG endpoint IPs (#2907) 2024-05-08 14:45:05 +05:30
Abhishek K
0638dcac49
NET-940: Inet Gws (#2828)
* internet gws apis

* add validate check for inet request

* add default gw changes to peer update

* update json tag

* add OS checks for inet gws

* add set defaul gw pro func

* allow disable and enable inet gw

* add inet handlers to pro

* add fields to api node

* add inet allowed ips

* add default gw to pull

* unset node inet details on deletion

* unset internet gw on network nodes

* unset inet gw fix

* unset inet gw fix

* send default gw ip

* fix inet node endpoint

* add default gw endpoint ip to pull resp

* validate after unset gws

* add inet client peer allowedips to inet node

* validate after unset gws

* fix allowed ips for inet peer and gw node

* fix allowed ips for inet peer and gw node

* fix allowed ips for inet peer and gw node

* fix allowed ips for inet peer and gw node

* fix inet gw and relayed conflict

* fix inet gw and relayed conflict

* fix update req

* fix update inet gw api

* when inet gw is peer ignore other allowedIps

* test relay

* revert test relay

* revert inet peer update changes

* channel internet traffic of relayed node to relay's inetgw

* channel internet traffic of relayed node to relay's inetgw

* channel internet traffic of relayed node to relay's inetgw

* add check for relayed node

* add inet info to peer update

* add inet info to peer update

* fix update node to persist inet info

* fix go tests

* egress ranges with inet gw fix

* egress ranges with inet gw fix

* disallow node acting using inet gw to act as inet gw

* add check to validate inet gw

* fix typos

* add firewall check

* set inetgw on ingress req on community

* set inetgw to false on community on ingress del
2024-02-28 08:46:51 +07:00
the_aceix
5882b86d40 feat(NET-709): add node metadata for remote gws 2024-01-26 10:06:36 +00:00
Abhishek K
530dbdc65c
NET-710: Internet Gws Re-Design (#2718)
* add internet gateway to client gateway

* migration func to remove internet egress range from egress gateway

* add internet gateways ranges to firewall update

* add internet gw ranges to extcleint conf

* add ipv6 internet address

* remove failover field from ingress req

* only let normal to be created on PRO (#2716)

* feat(NET-805): send internet gw props to rac

* set inet gw field on node update api

* move internet gws to EE

---------

Co-authored-by: the_aceix <aceixsmartx@gmail.com>
2023-12-06 23:57:58 +04:00
Abhishek K
b78cc0a8a1
NET-725: Failovers (#2685)
* api to  to get host relayed from client

* add auto relay to api host

* add peer nat type

* set pro field on signal

* rm net check on relay me handler

* return success response

* re-establish failover logic

* set failOver ctx

* failOver with peer pub key

* failovered peer updates

* failover handlers, reset failovered peer on deletion

* rm unused funcs

* initialize failover handler on EE

* ignore failover node on signal

* failover changes

* set host id on signal

* extend signal model to include node ids

* add backwards compatibility

* add failover as node api

* set json response on failover handers

* add failover field to api node

* fix signal data check

* initialize failover peer map

* reset failovered status when relayed or deleted

* add failover info to api node

* reset network failover

* only proceed furtuer if failover exists in the network

* set failOver node defaults

* cannot set failover node as relayed

* debug log

* debug log

* debug changes

* debug changes

* debug changes

* revert debug changes

* don't add peers to idmap when removed

* reset failed Over

* fix static checks

* rm debug log

* add check for linux host
2023-11-29 20:10:07 +04:00
Gabriel de Souza Seibel
cb4b99ffcb
[NET-562] Persistent Keep Alive from node to host (#2604)
* Move PKA field from models node to host level

* Move PKA field from api models node to host level

* Adapt logic package to node->host PKA

* Adapt migration-related code to node->host PKA

* Adapt cli code to node->host PKA

* Change host PKA default to 20s

* On IfaceDelta, check for PKA on host

* On handleHostRegister, set default PKA

* Use a default PKA

* Use int64 for api host pka

* Reorder imports

* Don't use host pka in iface delta

* Fix ConvertAPIHostToNMHost

* Add swagger doc for host PKA field

* Fix swagger.yml

* Set default PKA only for new hosts

* Remove TODO comment

* Remove redundant check

* Have api-host pka be specified in seconds
2023-10-06 10:09:19 +04:00
Abhishek K
6c2582651c
Net-137: Node relays (#2401)
* revert relays

* initial relay commit

* get relayed allowed ips

* add more relay validation checks, peer logic cleanup

* rm relayed nodes from relay node when relayed node is deleted

* fix egress updates for relayed nodes

* rm unused func

* remove  debug logs

* avoid adding egress ranges on the relayed gw node

---------

Co-authored-by: Matthew R Kasun <mkasun@nusak.ca>
2023-06-19 12:26:14 -04:00
Matthew R Kasun
78640f1342
Extclient NET-63x (#2286)
* model changes

* additional fields for extclient create

* add DNS to extclient config

* extclient name checks

* update extclient

* nmctl extclient

* final tweaks

* review comments

* add extclientdns to node on ingress creation

* fix to add ingress dns to api (#2296)

---------

Co-authored-by: Aceix <aceixsmartX@gmail.com>
2023-05-17 10:58:03 -04:00
Matthew R Kasun
828b3f7162 remove local network/range 2023-02-26 16:28:16 -05:00
0xdcarns
2f556dbcba disallowed updating of egress ranges 2023-02-09 10:27:38 -05:00
Matthew R Kasun
77cfae41ff remove postup/down 2023-02-02 11:16:54 -05:00
Anish Mukherjee
b926d393be fix node ipv6 address update 2023-01-27 10:01:54 +05:30
Aceix
bb0956f85f fix(GRA-1062): fix node expdate update 2023-01-26 14:08:02 +00:00
Aceix
a2ab933f89 fix(GRA-995): fix for update node address check 2023-01-17 10:04:12 +00:00
Abhishek Kondur
bff68bd945 rm peers from node model 2023-01-05 14:56:20 +05:30
Abhishek Kondur
2ff8684fd4 keep node level peers for now 2023-01-05 09:42:41 +05:30
Abhishek Kondur
72e4b914b9 move peers to host level 2023-01-05 09:24:46 +05:30
0xdcarns
f1f164cf35 fix host ID return for API 2023-01-03 14:17:36 -05:00
Abhishek Kondur
8a9241d5e2 fix keepalive conversion type 2022-12-30 11:43:48 +05:30
Matthew R Kasun
a371b7ae21
Merge branch 'netclient_refactor_latest' into GRA-824-getPeerUpdate 2022-12-23 15:59:55 -05:00
0xdcarns
368d01ff10 removed localaddress 2022-12-23 14:06:39 -05:00
Matthew R. Kasun
eae92470c5 refactor of peerUpdate
contains some debugging logging
2022-12-23 13:41:17 -05:00
0xdcarns
8f8335aa4f finished model conversion 2022-12-21 14:06:33 -05:00
0xdcarns
e92f524fbe finished convert api to nm node 2022-12-21 11:56:29 -05:00
Aceix
d1c51aed24 tech(GRA-823): address comments 2022-12-21 10:17:20 -05:00
Aceix
dcad50d0ee tech(GRA-823): add node DTO 2022-12-21 10:17:20 -05:00