This is an automated email from the ASF dual-hosted git repository.

twice pushed a commit to branch unstable
in repository https://gitbox.apache.org/repos/asf/incubator-kvrocks.git


The following commit(s) were added to refs/heads/unstable by this push:
     new f416fbb3 Add redis cli to the docker image (#1415)
f416fbb3 is described below

commit f416fbb3966a9965611d0fd9aca4c32a26d0babc
Author: ColinChamber <[email protected]>
AuthorDate: Fri May 5 21:12:19 2023 +0800

    Add redis cli to the docker image (#1415)
---
 Dockerfile | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/Dockerfile b/Dockerfile
index 543195f7..0c75d510 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -23,12 +23,19 @@ ARG MORE_BUILD_ARGS
 ENV TZ=Asia/Shanghai
 RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
 
-RUN apt update && apt install -y git gcc g++ make cmake autoconf automake 
libtool python3 libssl-dev
+RUN apt update && apt install -y git gcc g++ make cmake autoconf automake 
libtool python3 libssl-dev curl
 WORKDIR /kvrocks
 
 COPY . .
 RUN ./x.py build -DENABLE_OPENSSL=ON -DPORTABLE=ON $MORE_BUILD_ARGS
 
+RUN curl -O https://download.redis.io/releases/redis-6.2.7.tar.gz && \
+    tar -xzvf redis-6.2.7.tar.gz && \
+    mkdir tools && \
+    cd redis-6.2.7 && \
+    make redis-cli && \
+    mv src/redis-cli /kvrocks/tools/redis-cli
+
 FROM ubuntu:focal
 
 RUN apt update && apt install -y libssl-dev
@@ -37,6 +44,9 @@ WORKDIR /kvrocks
 
 COPY --from=build /kvrocks/build/kvrocks ./bin/
 
+COPY --from=build /kvrocks/tools/redis-cli ./bin/
+ENV PATH="$PATH:/kvrocks/bin"
+
 VOLUME /var/lib/kvrocks
 
 COPY ./LICENSE ./NOTICE ./DISCLAIMER ./

Reply via email to