[docker-frr]: Fix frr separated and unified configuration mode (#2962)

This commit is contained in:
lguohan 2019-06-01 09:33:52 -07:00 committed by Shuotian Cheng
parent 91b1948b17
commit f40795a5be

View File

@ -8,9 +8,11 @@ if [ -z "$CONFIG_TYPE" ] || [ "$CONFIG_TYPE" == "separated" ]; then
sonic-cfggen -d -y /etc/sonic/deployment_id_asn_map.yml -t /usr/share/sonic/templates/bgpd.conf.j2 > /etc/frr/bgpd.conf
sonic-cfggen -d -t /usr/share/sonic/templates/zebra.conf.j2 > /etc/frr/zebra.conf
touch /etc/frr/vtysh.conf
rm -f /etc/frr/frr.conf
elif [ "$CONFIG_TYPE" == "unified" ]; then
sonic-cfggen -d -y /etc/sonic/deployment_id_asn_map.yml -t /usr/share/sonic/templates/frr.conf.j2 >/etc/frr/frr.conf
echo "service integrated-vtysh-config" > /etc/frr/vtysh.conf
rm -f /etc/frr/bgpd.conf /etc/frr/vtysh.conf
fi
sonic-cfggen -d -t /usr/share/sonic/templates/isolate.j2 > /usr/sbin/bgp-isolate
@ -35,7 +37,7 @@ supervisorctl start zebra
supervisorctl start staticd
supervisorctl start bgpd
if [ -z "$CONFIG_TYPE" ] || [ "$CONFIG_TYPE" == "separated" ]; then
if [ "$CONFIG_TYPE" == "unified" ]; then
supervisorctl start vtysh_b
fi