]> git.proxmox.com Git - mirror_frr.git/commitdiff
snapcraft: Add bfdd to snap package
authorMartin Winter <mwinter@opensourcerouting.org>
Tue, 14 Aug 2018 20:31:54 +0000 (13:31 -0700)
committerMartin Winter <mwinter@opensourcerouting.org>
Tue, 14 Aug 2018 20:31:54 +0000 (13:31 -0700)
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
snapcraft/README.usage.md
snapcraft/defaults/bfdd.conf.default [new file with mode: 0644]
snapcraft/scripts/Makefile
snapcraft/scripts/bfdd-service [new file with mode: 0644]
snapcraft/snapcraft.yaml.in

index 28d2395455f541e04772c3d228dc4730d198e000..50711b13b727309b23e8bf4e44d24afdd4f9325d 100644 (file)
@@ -18,7 +18,7 @@ ie for `ospf6d` (OSPFv3):
     systemctl enable snap.frr.ospf6d.service
 
 The daemons are: `ripd`, `ripngd`, `ospfd`, `ospf6d`, `isisd`, `bgpd`, 
-`pimd`, `zebra`
+`pimd`, `ldpd`, `eigrpd`, `babeld`, `nhrpd`, `bfdd`, `zebra`
 
 Commands defined by this snap
 -----------------------------
@@ -53,7 +53,19 @@ depend on them). These are mainly intended to debug the Snap
 - `frr.pimd-debug`:
        Starts pimd daemon in foreground
 - `frr.ldpd-debug`:
-    Starts ldpd daemon in foreground
+        Starts ldpd daemon in foreground
+- `frr.nhrpd-debug`:
+        Starts nhrpd daemon in foreground
+- `frr.babeld-debug`:
+        Starts babeld daemon in foreground
+- `frr.eigrpd-debug`:
+        Starts eigrpd daemon in foreground
+- `frr.pbrd-debug`:
+        Starts pbrd daemon in foreground
+- `frr.staticd-debug`:
+        Starts staticd daemon in foreground
+- `frr.bfdd-debug`:
+        Starts bfdd daemon in foreground
 
 MPLS (LDP)
 ----------
@@ -108,7 +120,7 @@ FAQ
     - Define `VTYSH_PAGER` to `cat` (default is `more`). (Ie add 
       `export VTYSH_PAGER=cat` to the end of your `.profile`)
 
-- ospfd / ospf6d are not running after installation
+- bfdd / ospfd / ospf6d / nhrpd are not running after installation
     - Installing a new snap starts the daemons, but at this time they
       may not have the required privileged access. Make sure you 
       issue the `snap connect` command as given above (can be verified
diff --git a/snapcraft/defaults/bfdd.conf.default b/snapcraft/defaults/bfdd.conf.default
new file mode 100644 (file)
index 0000000..e69de29
index 9a476c6e58d6d4bf162fd375654fea4c9e553cdd..e3a7708f23043d59454fc3862375f84ed9f3ddb7 100644 (file)
@@ -16,6 +16,7 @@ install:
        install -D -m 0755 eigrpd-service $(DESTDIR)/bin/
        install -D -m 0755 pbrd-service $(DESTDIR)/bin/
        install -D -m 0755 staticd-service $(DESTDIR)/bin/
+       install -D -m 0755 bfdd-service $(DESTDIR)/bin/
        install -D -m 0755 set-options $(DESTDIR)/bin/
        install -D -m 0755 show_version $(DESTDIR)/bin/
 
diff --git a/snapcraft/scripts/bfdd-service b/snapcraft/scripts/bfdd-service
new file mode 100644 (file)
index 0000000..f94a7ab
--- /dev/null
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+set -e -x
+
+if ! [ -e $SNAP_DATA/bfdd.conf ]; then
+    cp $SNAP/etc/frr/bfdd.conf.default $SNAP_DATA/bfdd.conf
+fi
+exec $SNAP/sbin/bfdd \
+    -f $SNAP_DATA/bfdd.conf \
+    --pid_file $SNAP_DATA/bfdd.pid \
+    --socket $SNAP_DATA/zsock \
+    --vty_socket $SNAP_DATA \
+    --bfdctl $SNAP_DATA/bfdd.sock
+
index 48dc69278b629333385f58fd9fe3809ffae21024..563a05c5a790cf6f33bfe4b60491c4149b0fe19d 100644 (file)
@@ -1,10 +1,10 @@
 name: frr
 version: @VERSION@
-summary: FRRouting BGP/OSPFv2/OSPFv3/ISIS/RIP/RIPng/PIM/LDP routing daemon
-description: BGP/OSPFv2/OSPFv3/ISIS/RIP/RIPng/PIM routing daemon
+summary: FRRouting BGP/OSPFv2/OSPFv3/ISIS/RIP/RIPng/PIM/LDP/EIGRP/BFD routing daemon
+description: BGP/OSPFv2/OSPFv3/ISIS/RIP/RIPng/PIM/LDP/EIGRP/BFD routing daemon
  FRRouting (FRR) is free software which manages TCP/IP based routing 
  protocols. It supports BGP4, BGP4+, OSPFv2, OSPFv3, IS-IS, RIPv1, RIPv2, 
- RIPng, PIM, LDP, Babel, EIGRP and PBR (Policy-based routing) as well as
+ RIPng, PIM, LDP, Babel, EIGRP, PBR (Policy-based routing) and BFD as well as
  the IPv6 versions of these.
  FRRouting (frr) is a fork of Quagga.
 confinement: strict
@@ -120,6 +120,13 @@ apps:
             - network
             - network-bind
             - network-control
+    bfdd:
+        command: bin/bfdd-service
+        daemon: simple
+        plugs:
+            - network
+            - network-bind
+            - network-control
     set:
         command: bin/set-options
     zebra-debug:
@@ -202,6 +209,16 @@ apps:
             - network-control
     staticd-debug:
         command: sbin/staticd -f $SNAP_DATA/staticd.conf --pid_file $SNAP_DATA/staticd.pid --socket $SNAP_DATA/zsock --vty_socket $SNAP_DATA
+        plugs:
+            - network
+            - network-bind
+            - network-control
+    bfdd-debug:
+        command: sbin/bfdd -f $SNAP_DATA/bfdd.conf --pid_file $SNAP_DATA/bfdd.pid --socket $SNAP_DATA/zsock --vty_socket $SNAP_DATA --bfdctl $SNAP_DATA/bfdd.sock
+        plugs:
+            - network
+            - network-bind
+            - network-control
 
 parts:
     frr: 
@@ -283,6 +300,7 @@ parts:
             babeld.conf.default: etc/frr/babeld.conf.default
             eigrpd.conf.default: etc/frr/eigrpd.conf.default
             pbrd.conf.default: etc/frr/pbrd.conf.default
+            bfdd.conf.default: etc/frr/bfdd.conf.default
             vtysh.conf.default: etc/frr/vtysh.conf.default
     frr-scripts:
         plugin: make