docker-syncd-cavm : Added synchronization between syncd and redis (#79)
This commit is contained in:
parent
96c2834cad
commit
57ff53ea60
@ -18,7 +18,7 @@ RUN dpkg_apt() { [ -f $1 ] && { dpkg -i $1 || apt-get -y install -f; } || return
|
||||
&& dpkg_apt /deps/libsaimetadata_*.deb \
|
||||
&& dpkg_apt /deps/syncd_*.deb
|
||||
|
||||
RUN apt-get -y install libpcap-dev libxml2-dev python-dev swig libsensors4-dev
|
||||
RUN apt-get -y install libpcap-dev libxml2-dev python-dev swig libsensors4-dev redis-tools
|
||||
|
||||
COPY ["start.sh", "/usr/bin/"]
|
||||
|
||||
|
@ -3,4 +3,21 @@
|
||||
export XP_ROOT=/usr/bin/
|
||||
|
||||
service rsyslog start
|
||||
syncd -p /etc/ssw/AS7512/profile.ini -N
|
||||
|
||||
while true; do
|
||||
|
||||
# Check if redis-server starts
|
||||
|
||||
result=$(redis-cli ping)
|
||||
|
||||
if [ "$result" == "PONG" ]; then
|
||||
|
||||
redis-cli FLUSHALL
|
||||
syncd -p /etc/ssw/AS7512/profile.ini -N
|
||||
break
|
||||
|
||||
fi
|
||||
|
||||
sleep 1
|
||||
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user