-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add docker configuration for saiserver-brcm (#44)
- Loading branch information
1 parent
9820799
commit 4757147
Showing
4 changed files
with
78 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
FROM docker-base | ||
|
||
RUN apt-get update | ||
|
||
COPY ["/deps/libsaibcm*.deb","/deps/libopennsl_*.deb","/deps/python-sdk-api_*.deb", "/deps/iproute2_*.deb", "/deps/libthrift-0.9.3_*.deb", "/deps/libnl-3-200_*.deb", "/deps/libnl-genl-3-200_*.deb", "/deps/libnl-route-3-200_*.deb", "/deps/"] | ||
|
||
RUN dpkg_apt() { [ -f $1 ] && { dpkg -i $1 || apt-get -y install -f; } || return 1; }; \ | ||
dpkg_apt /deps/libopennsl_*.deb \ | ||
&& dpkg_apt /deps/libsaibcm_*.deb \ | ||
&& dpkg_apt /deps/libthrift-0.9.3_*.deb \ | ||
&& dpkg_apt /deps/libnl-3-200_*.deb \ | ||
&& dpkg_apt /deps/libnl-genl-3-200_*.deb \ | ||
&& dpkg_apt /deps/libnl-route-3-200_*.deb | ||
|
||
COPY ["deps/saiserver", "start.sh", "/usr/bin/"] | ||
|
||
COPY ["profile.ini", "portmap.ini", "/etc/sai/"] | ||
|
||
## Clean up | ||
RUN apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y | ||
RUN rm -rf /deps | ||
|
||
ENTRYPOINT ["/bin/bash"] | ||
CMD ["/usr/bin/start.sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# alias lanes | ||
Ethernet0 29,30,31,32 | ||
Ethernet4 25,26,27,28 | ||
Ethernet8 37,38,39,40 | ||
Ethernet12 33,34,35,36 | ||
Ethernet16 41,42,43,44 | ||
Ethernet20 45,46,47,48 | ||
Ethernet24 5,6,7,8 | ||
Ethernet28 1,2,3,4 | ||
Ethernet32 9,10,11,12 | ||
Ethernet36 13,14,15,16 | ||
Ethernet40 21,22,23,24 | ||
Ethernet44 17,18,19,20 | ||
Ethernet48 49,50,51,52 | ||
Ethernet52 53,54,55,56 | ||
Ethernet56 61,62,63,64 | ||
Ethernet60 57,58,59,60 | ||
Ethernet64 65,66,67,68 | ||
Ethernet68 69,70,71,72 | ||
Ethernet72 77,78,79,80 | ||
Ethernet76 73,74,75,76 | ||
Ethernet80 105,106,107,108 | ||
Ethernet84 109,110,111,112 | ||
Ethernet88 117,118,119,120 | ||
Ethernet92 113,114,115,116 | ||
Ethernet96 121,122,123,124 | ||
Ethernet100 125,126,127,128 | ||
Ethernet104 85,86,87,88 | ||
Ethernet108 81,82,83,84 | ||
Ethernet112 89,90,91,92 | ||
Ethernet116 93,94,95,96 | ||
Ethernet120 97,98,99,100 | ||
Ethernet124 101,102,103,104 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
SAI_INIT_CONFIG_FILE=/etc/bcm/td2-s6000-32x40G.config.bcm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/bin/bash | ||
|
||
function clean_up { | ||
service rsyslog stop | ||
} | ||
|
||
start_bcm() | ||
{ | ||
[ -e /dev/linux-bcm-knet ] || mknod /dev/linux-bcm-knet c 122 0 | ||
[ -e /dev/linux-user-bde ] || mknod /dev/linux-user-bde c 126 0 | ||
[ -e /dev/linux-kernel-bde ] || mknod /dev/linux-kernel-bde c 127 0 | ||
} | ||
|
||
trap clean_up SIGTERM SIGKILL | ||
|
||
service rsyslog start | ||
|
||
start_bcm | ||
|
||
/usr/bin/saiserver -p /etc/sai/profile.ini -f /etc/sai/portmap.ini |