2017-05-08 17:43:31 -05:00
|
|
|
#!/usr/bin/env bash
|
2016-07-26 14:01:58 -05:00
|
|
|
|
2017-05-08 17:43:31 -05:00
|
|
|
mkdir -p /etc/swss/config.d/
|
2017-04-21 16:28:30 -05:00
|
|
|
|
2018-11-28 00:02:30 -06:00
|
|
|
sonic-cfggen -d -y /etc/sonic/sonic_version.yml -t /usr/share/sonic/templates/switch.json.j2 > /etc/swss/config.d/switch.json
|
2017-11-23 18:31:37 -06:00
|
|
|
sonic-cfggen -d -t /usr/share/sonic/templates/ipinip.json.j2 > /etc/swss/config.d/ipinip.json
|
|
|
|
sonic-cfggen -d -t /usr/share/sonic/templates/ports.json.j2 > /etc/swss/config.d/ports.json
|
2020-07-31 16:14:21 -05:00
|
|
|
sonic-cfggen -d -t /usr/share/sonic/templates/copp.json.j2 > /etc/swss/config.d/00-copp.config.json
|
2017-02-02 22:34:34 -06:00
|
|
|
|
2018-09-24 16:56:37 -05:00
|
|
|
# Executed HWSKU specific initialization tasks.
|
|
|
|
if [ -x /usr/share/sonic/hwsku/hwsku-init ]; then
|
|
|
|
/usr/share/sonic/hwsku/hwsku-init
|
|
|
|
fi
|
|
|
|
|
2017-05-15 19:06:19 -05:00
|
|
|
# Start arp_update when VLAN exists
|
2017-09-12 16:13:27 -05:00
|
|
|
VLAN=`sonic-cfggen -d -v 'VLAN.keys() | join(" ") if VLAN'`
|
2017-05-15 19:06:19 -05:00
|
|
|
if [ "$VLAN" != "" ]; then
|
2020-09-17 20:33:10 -05:00
|
|
|
cp /usr/share/sonic/templates/arp_update.conf /etc/supervisor/conf.d/
|
2017-05-15 19:06:19 -05:00
|
|
|
fi
|
2020-05-15 19:09:16 -05:00
|
|
|
|
|
|
|
exec /usr/bin/supervisord
|