]> git.proxmox.com Git - mirror_frr.git/commitdiff
sharpd/vtysh: Allow sharpd to use nexthop-groups
authorDonald Sharp <sharpd@cumulusnetworks.com>
Mon, 31 Dec 2018 22:48:36 +0000 (17:48 -0500)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 2 Jan 2019 14:46:33 +0000 (09:46 -0500)
Allow the sharp daemon to understand and use nexthop-groups.

This commit is merely to allow sharpd to understand them
when accepted in a future commit

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
sharpd/sharp_main.c
vtysh/extract.pl.in
vtysh/vtysh.c

index 34b84f6062e91c174432638ea4de1b302b98031f..175a276089b6962b1e0ad8a3cdc707c3501411e3 100644 (file)
@@ -151,6 +151,7 @@ int main(int argc, char **argv, char **envp)
 
        master = frr_init();
 
+       nexthop_group_init(NULL, NULL, NULL, NULL);
        vrf_init(NULL, NULL, NULL, NULL, NULL);
 
        access_list_init();
index 596f01738ad19a09bd8fe904d82a3a2dcad4e844..2b48f1f3609a2f91bd9f0af912a811ec3a073de9 100755 (executable)
@@ -109,7 +109,7 @@ sub scan_file {
             $protocol = "VTYSH_ZEBRA";
         }
        elsif ($file =~ /lib\/nexthop_group\.c$/) {
-           $protocol = "VTYSH_PBRD";
+           $protocol = "VTYSH_PBRD | VTYSH_SHARPD";
        }
         elsif ($file =~ /lib\/plist\.c$/) {
             if ($defun_array[1] =~ m/ipv6/) {
index 2327f2b46d7e04219518ab89d5d7fe849d307db9..6cf45789dd97459ea5aa216c39e0139fd86c1059 100644 (file)
@@ -2110,7 +2110,7 @@ DEFSH(VTYSH_ZEBRA, vtysh_no_logicalrouter_cmd,
       "The Name Space\n"
       "The file name in " NS_RUN_DIR ", or a full pathname\n")
 
-DEFUNSH(VTYSH_PBRD, vtysh_nexthop_group, vtysh_nexthop_group_cmd,
+DEFUNSH(VTYSH_PBRD | VTYSH_SHARPD, vtysh_nexthop_group, vtysh_nexthop_group_cmd,
        "nexthop-group NAME",
        "Nexthop Group configuration\n"
        "Name of the Nexthop Group\n")
@@ -2119,7 +2119,8 @@ DEFUNSH(VTYSH_PBRD, vtysh_nexthop_group, vtysh_nexthop_group_cmd,
        return CMD_SUCCESS;
 }
 
-DEFSH(VTYSH_PBRD, vtysh_no_nexthop_group_cmd, "no nexthop-group NAME",
+DEFSH(VTYSH_PBRD | VTYSH_SHARPD, vtysh_no_nexthop_group_cmd,
+      "no nexthop-group NAME",
       NO_STR
       "Nexthop Group Configuration\n"
       "Name of the Nexthop Group\n")