From ef1952b6d89f2326c56932bfc07e19ff7f713a01 Mon Sep 17 00:00:00 2001 From: Yuya Kusakabe Date: Sat, 22 Jul 2017 22:31:25 +0900 Subject: Run script with vyattacfg group --- spec/bgp4/vyos2_script.sh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'spec/bgp4/vyos2_script.sh') diff --git a/spec/bgp4/vyos2_script.sh b/spec/bgp4/vyos2_script.sh index 1be2c7e..7cb0586 100644 --- a/spec/bgp4/vyos2_script.sh +++ b/spec/bgp4/vyos2_script.sh @@ -1,5 +1,9 @@ #!/bin/vbash +if [ "$(id -g -n)" != 'vyattacfg' ] ; then + exec sg vyattacfg -c "/bin/vbash $(readlink -f $0) $@" +fi + source /opt/vyatta/etc/functions/script-template set protocols bgp 65537 neighbor 10.0.1.11 ebgp-multihop 2 -- cgit v1.2.3