Skip to content

What is the format of the content of the REDIS__CONNECTION__ADDR environment variable? #304

Closed Answered by bikeshedder
JasterV asked this question in Q&A
Discussion options

You must be logged in to vote

You can find the Config struct here: https://github.com/bikeshedder/deadpool/blob/master/redis/src/config.rs#L39

I just realized the example in the config documentation was wrong and is now fixed as of fa9c55c.

The correct environment configuration is:

REDIS__URL=rediss://localhost:6379

The exploded ConnectionInfo is a bit more tricky as it involves quite a lot of nesting and is a 1:1 mapping from the underlying structures. A JSON config would look like that:

{
    "redis": {
        "connection": {
            "addr": {
                "TcpTls": {
                    "host": "localhost",
                    "port": 6379,
                    "insecure": false
                }
          …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@JasterV
Comment options

Answer selected by JasterV
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants