0

ive been creating new intances for redis and clustering them. i would like my intsances to use rejson so im using redislabs/rejson. the only problem is when composing up i get this issue for all redis nodes.

enter image description here here is the dockerfile for allredis nodes:

FROM redislabs/rejson:latest AS redis

ARG REDIS_PORT

WORKDIR /redis-workdir

# Installing OS level dependencies
RUN apt-get update
RUN apt-get install -y wget
RUN apt-get install -y gettext-base
RUN mkdir -p "/opt"
# Downloading redis default config
RUN wget https://raw.githubusercontent.com/wayofthepie/docker-rejson/master/redis.conf
RUN mv redis.conf redis.default.conf
COPY . .

ENV REDIS_PORT $REDIS_PORT
RUN envsubst < redis.conf > updated_redis.conf
RUN mv updated_redis.conf redis.conf

CMD redis-server ./redis.conf

its running the last line of this link https://raw.githubusercontent.com/wayofthepie/docker-rejson/master/redis.conf

thanks for helping out

Camille Basbous
  • 299
  • 5
  • 11
  • 34
  • If the file exists, use `ldd` to inspect its shared library dependencies and how they're fulfilled. – Charles Duffy Sep 26 '22 at 23:19
  • What's actually in the `redis.conf` file? Is there any reason to have the container start on something other than the standard Redis port 6379? You seem to have included an image file in place of the error message; can you [edit] the question to include the actual text of the error? – David Maze Sep 26 '22 at 23:48
  • (to David's point, see [Why not upload images of code/data/errors when asking a question?](https://meta.stackoverflow.com/a/285557/14122)) – Charles Duffy Sep 27 '22 at 00:00
  • That's my rejson.conf from a repo that's 5 years old. It harcodes that path because that's where that specific dockerfile puts the .so, see https://github.com/wayofthepie/docker-rejson/blob/master/Dockerfile#L16. I'd strongly advise against using that config :D I'm sure rejson has a more up to date example. – wayofthepie Sep 27 '22 at 05:19
  • @DavidMaze im creating a cluster that has different instances related to different port to be able to utilize more threading cores – Camille Basbous Sep 27 '22 at 12:52
  • @wayofthepie I've tried finding another one but didn't find one yet, any suggestions? – Camille Basbous Sep 27 '22 at 12:53
  • Each Docker container internally has its own private IP address. While that's mostly an implementation detail that you don't see, it does mean you can launch multiple instances of a container each listening on the "normal" TCP port and they won't conflict. If your only configuration change is modifying the port number, the standard image listening on the standard port should work fine. – David Maze Sep 27 '22 at 13:12
  • 1
    @CamilleBasbous it's just a redis config that has a loadmodule for the rejson.so. This has example confs for many versions of redis https://redis.io/docs/manual/config/. – wayofthepie Sep 28 '22 at 05:14

0 Answers0