--- Begin Message ---
+ minimal module
Signed-off-by: lou lecrivain <lou.lecriv...@wdz.de>
---
src/PVE/Network/SDN/Ipams/NautobotPlugin.pm | 22 ---------------------
src/PVE/Network/SDN/Ipams/NetboxPlugin.pm | 2 +-
2 files changed, 1 insertion(+), 23 deletions(-)
diff --git a/src/PVE/Network/SDN/Ipams/NautobotPlugin.pm
b/src/PVE/Network/SDN/Ipams/NautobotPlugin.pm
index 03bd3de..6597bfe 100644
--- a/src/PVE/Network/SDN/Ipams/NautobotPlugin.pm
+++ b/src/PVE/Network/SDN/Ipams/NautobotPlugin.pm
@@ -12,26 +12,4 @@ sub type {
return 'nautobot';
}
-sub verify_api {
- my ($class, $plugin_config) = @_;
-
- my $url = $plugin_config->{url};
- my $token = $plugin_config->{token};
- my $headers = [ 'Authorization' => "token $token", 'Accept' =>
"application/json; indent=4" ];
-
- eval {
- PVE::Network::SDN::api_request("GET", "$url/ipam/namespaces", $headers);
- };
- if ($@) {
- die "Can't connect to nautobot api: $@";
- }
-}
-
-# helpers
-sub on_update_hook {
- my ($class, $plugin_config) = @_;
-
- PVE::Network::SDN::Ipams::NautobotPlugin::verify_api($class,
$plugin_config);
-}
-
1;
diff --git a/src/PVE/Network/SDN/Ipams/NetboxPlugin.pm
b/src/PVE/Network/SDN/Ipams/NetboxPlugin.pm
index d923269..7efccaf 100644
--- a/src/PVE/Network/SDN/Ipams/NetboxPlugin.pm
+++ b/src/PVE/Network/SDN/Ipams/NetboxPlugin.pm
@@ -240,7 +240,7 @@ sub verify_api {
eval {
- PVE::Network::SDN::api_request("GET", "$url/ipam/aggregates/",
$headers);
+ PVE::Network::SDN::api_request("GET", "$url/ipam/prefixes/", $headers);
};
if ($@) {
die "Can't connect to netbox api: $@";
--
2.39.5
--- End Message ---
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel