[redis] Use redis-server and redis-tools in blob storage to prevent upstream link broken (#5340)

* [redis] Use redis-server and redis-tools in blob storage to prevent
upstream link broken
* Use curl instead of wget
* Explicitly install dependencies
This commit is contained in:
Qi Luo 2020-09-08 19:30:14 -07:00 committed by GitHub
parent 01fb32fa08
commit d4fc8e5b22
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 22 additions and 4 deletions

View File

@ -40,6 +40,7 @@ COPY ["no-check-valid-until", "/etc/apt/apt.conf.d"]
# pre-install fundamental packages
RUN apt-get update && \
apt-get -y install \
curl \
less \
perl \
procps \
@ -52,8 +53,12 @@ RUN apt-get update && \
# Install dependencies of supervisor
python-pkg-resources \
python-meld3 \
# Install redis-tools
redis-tools=5:6.0.6-1~bpo10+1 \
# Install dependencies of redis-tools
libatomic1 \
libjemalloc2 \
liblua5.1-0 \
lua-bitop \
lua-cjson \
# common dependencies
libpython2.7 \
libdaemon0 \
@ -68,6 +73,11 @@ RUN apt-get update && \
# for processing/handling json files in bash environment
jq
# Install redis-tools
RUN curl -o redis-tools_6.0.6-1~bpo10+1_amd64.deb "https://sonicstorage.blob.core.windows.net/packages/redis/redis-tools_6.0.6-1~bpo10+1_amd64.deb?sv=2015-04-05&sr=b&sig=73zbmjkf3pi%2Bn0R8Hy7CWT2EUvOAyzM5aLYJWCLySGM%3D&se=2030-09-06T19%3A44%3A59Z&sp=r"
RUN dpkg -i redis-tools_6.0.6-1~bpo10+1_amd64.deb || apt-get install -f -y
RUN rm redis-tools_6.0.6-1~bpo10+1_amd64.deb
# For templating
RUN pip install j2cli

View File

@ -11,7 +11,10 @@ ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
# install redis-server
RUN apt-get install -y redis-server=5:6.0.6-1~bpo10+1
RUN curl -o redis-tools_6.0.6-1~bpo10+1_amd64.deb "https://sonicstorage.blob.core.windows.net/packages/redis/redis-tools_6.0.6-1~bpo10+1_amd64.deb?sv=2015-04-05&sr=b&sig=73zbmjkf3pi%2Bn0R8Hy7CWT2EUvOAyzM5aLYJWCLySGM%3D&se=2030-09-06T19%3A44%3A59Z&sp=r"
RUN curl -o redis-server_6.0.6-1~bpo10+1_amd64.deb "https://sonicstorage.blob.core.windows.net/packages/redis/redis-server_6.0.6-1~bpo10+1_amd64.deb?sv=2015-04-05&sr=b&sig=2Ketg7BmkZEaTxR%2FgvAFVmhjn7ywdmkc7l2T2rsL57o%3D&se=2030-09-06T19%3A45%3A20Z&sp=r"
RUN dpkg -i redis-tools_6.0.6-1~bpo10+1_amd64.deb redis-server_6.0.6-1~bpo10+1_amd64.deb || apt-get install -f
RUN rm redis-tools_6.0.6-1~bpo10+1_amd64.deb redis-server_6.0.6-1~bpo10+1_amd64.deb
{% if docker_database_debs.strip() -%}
# Copy locally-built Debian package dependencies

View File

@ -13,7 +13,6 @@ RUN echo "deb http://packages.microsoft.com/repos/sonic-dev/ jessie main" >> /et
RUN apt-get update
RUN apt-get install -y net-tools \
redis-server=5:6.0.6-1~bpo10+1 \
arping \
ndisc6 \
ethtool \
@ -49,6 +48,12 @@ RUN apt-get install -y net-tools \
python3-pip \
jq
# install redis-server
RUN curl -o redis-tools_6.0.6-1~bpo10+1_amd64.deb "https://sonicstorage.blob.core.windows.net/packages/redis/redis-tools_6.0.6-1~bpo10+1_amd64.deb?sv=2015-04-05&sr=b&sig=73zbmjkf3pi%2Bn0R8Hy7CWT2EUvOAyzM5aLYJWCLySGM%3D&se=2030-09-06T19%3A44%3A59Z&sp=r"
RUN curl -o redis-server_6.0.6-1~bpo10+1_amd64.deb "https://sonicstorage.blob.core.windows.net/packages/redis/redis-server_6.0.6-1~bpo10+1_amd64.deb?sv=2015-04-05&sr=b&sig=2Ketg7BmkZEaTxR%2FgvAFVmhjn7ywdmkc7l2T2rsL57o%3D&se=2030-09-06T19%3A45%3A20Z&sp=r"
RUN dpkg -i redis-tools_6.0.6-1~bpo10+1_amd64.deb redis-server_6.0.6-1~bpo10+1_amd64.deb || apt-get install -f
RUN rm redis-tools_6.0.6-1~bpo10+1_amd64.deb redis-server_6.0.6-1~bpo10+1_amd64.deb
RUN pip install setuptools
RUN pip3 install setuptools
RUN pip install py2_ipaddress