joeferner / redis-commander

Redis management tool written in node.js
http://joeferner.github.io/redis-commander/
MIT License
3.63k stars 468 forks source link

Connecting to TLS memory store redis on GCP #580

Open hrvalca opened 7 hours ago

hrvalca commented 7 hours ago

Having issues with TLS, seems like arguments like insecure or TLS CA location are not propagated at all to node cli

      env:
        - name: "REDIS_HOST"
          value: "10.12.15.24"
        - name: "REDIS_PORT"
          value: "6378"
        - name: "REDIS_PASSWORD"
          value: "123"
        - name: "REDIS_TLS_CA_CERT_FILE"
          value: "/tmp/file.pem"
        - name: "REDIS_TLS"
          value: "true"

I tried setting up NODE_TLS_REJECT_UNAUTHORIZED, but it just not working. Tried to mount base64 as secret but getting

setUpConnection (R:10.12.15.24:6378:0) Redis error Error: unable to verify the first certificate
    at TLSSocket.onConnectSecure (node:_tls_wrap:1535:34)
    at TLSSocket.emit (node:events:513:28)
    at TLSSocket._finishInit (node:_tls_wrap:949:8)
    at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:730:12)
➜  ~ kubectl logs -f redis-commander-679b784b7d-8dz5n
Creating custom redis-commander config '/redis-commander/config/local-production.json'.
node ./bin/redis-commander --redis-port 6378 --redis-host 10.12.15.24 --redis-tls --redis-password <set>  for k8s

I dont see that envs are propagated to CLI

When I try to connect to via redis-cli; It all works

`root@netshot-545cb796dc-9vczw:~# redis-cli --tls --insecure -h 10.12.15.24  -p 6378
10.102.125.244:6378> auth 123
OK
10.102.125.244:6378> keys *
 1) "redisson__timeout__set:{imba-properties-cache}"
 2) "redisson__timeout__set:{imba-owners-cache}"
 3) "redisson__timeout__set:{imba-contact-cache}"

I am not sure what I am doing wrong, but it seems to me that ENVs dont propagate to CLI arguments?

hrvalca commented 7 hours ago

Might be connected to https://github.com/joeferner/redis-commander/issues/554?