X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=docker%2FDockerfile.redis;h=98d4c262ea12132a4e469d1f279ec176c1ee6306;hb=68d81ba25c3129a2c869294a660e01926f5bc84c;hp=a8b0c323989d1aae0512e3591be1d1507bf12382;hpb=87fd3ca9bf5cc0949dffc44ac68f0964964bee41;p=ric-plt%2Fdbaas.git diff --git a/docker/Dockerfile.redis b/docker/Dockerfile.redis index a8b0c32..98d4c26 100644 --- a/docker/Dockerfile.redis +++ b/docker/Dockerfile.redis @@ -13,32 +13,21 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ubuntu:latest +# +# This source code is part of the near-RT RIC (RAN Intelligent Controller) +# platform project (RICP). +# -# Install redis -RUN apt update && \ - apt install -y redis-server && \ - apt clean +FROM nexus3.o-ran-sc.org:10004/bldr-alpine3:6-a3.9-nng as build-env -# Install Redis modules -RUN apt install -y build-essential && \ - apt install -y automake && \ - apt install -y libtool && \ - apt clean -COPY ./redismodule ./redismodule +COPY ./redismodule /redismodule WORKDIR /redismodule RUN ./autogen.sh && \ ./configure && \ make install -j -# Create suitable configuration file -RUN sed -i 's/^\(bind .*\)$/# \1/' /etc/redis/redis.conf && \ - sed -i 's/^\(daemonize .*\)$/# \1/' /etc/redis/redis.conf && \ - sed 's/^protected-mode yes/protected-mode no/' -i /etc/redis/redis.conf && \ - echo 'loadmodule /usr/local/libexec/redismodule/libredismodule.so' >> /etc/redis/redis.conf && \ - sed -i 's/^\(save .*\)$/# \1/' /etc/redis/redis.conf && \ - echo 'save ""' >> /etc/redis/redis.conf - -EXPOSE 6379 +FROM redis:5.0.5-alpine3.9 -CMD ["redis-server", "/etc/redis/redis.conf"] +RUN apk add curl +COPY --from=build-env /usr/local/libexec/redismodule/libredismodule.so /usr/local/libexec/redismodule/libredismodule.so +WORKDIR /data