]> git.proxmox.com Git - mirror_frr.git/blobdiff - tools/frrcommon.sh.in
watchfrr: build in defaults for -r/-s/-k
[mirror_frr.git] / tools / frrcommon.sh.in
index 588aa6d103e10a086c3e1dcedeb63114fb53adf2..37abfeb30d2eec16c1b92d58f2bb6cdab598cd5d 100644 (file)
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
 #
 # This is a "library" of sorts for use by the other FRR shell scripts.  It
 # has most of the daemon start/stop logic, but expects the following shell
@@ -288,6 +288,13 @@ load_old_config "$C_PATH/daemons.conf"
 load_old_config "/etc/default/frr"
 load_old_config "/etc/sysconfig/frr"
 
+if declare -p watchfrr_options | grep -q '^declare \-a'; then
+       log_warning_msg "watchfrr_options contains a bash array value." \
+               "The configured value is intentionally ignored since it is likely wrong." \
+               "Please remove or fix the setting."
+       unset watchfrr_options
+fi
+
 #
 # other defaults and dispatch
 #