Skip to content

Commit 542b433

Browse files
yxiecalguohan
authored andcommitted
[hwsku-init] Introduce mechanism to run HWSKU specific initialization code (#2072)
When there is HWSKU specific initialization needs to be performed, please add hwsku-init script under device folder, it will be invoked by swss before any subsequent initializations. Signed-off-by: Ying Xie <[email protected]>
1 parent 9b2a594 commit 542b433

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

dockers/docker-orchagent/start.sh

+5
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ sonic-cfggen -d -t /usr/share/sonic/templates/switch.json.j2 > /etc/swss/config.
66
sonic-cfggen -d -t /usr/share/sonic/templates/ipinip.json.j2 > /etc/swss/config.d/ipinip.json
77
sonic-cfggen -d -t /usr/share/sonic/templates/ports.json.j2 > /etc/swss/config.d/ports.json
88

9+
# Executed HWSKU specific initialization tasks.
10+
if [ -x /usr/share/sonic/hwsku/hwsku-init ]; then
11+
/usr/share/sonic/hwsku/hwsku-init
12+
fi
13+
914
export platform=`sonic-cfggen -H -v DEVICE_METADATA.localhost.platform`
1015

1116
rm -f /var/run/rsyslogd.pid

0 commit comments

Comments
 (0)