mirror of
https://github.com/bunkerity/bunkerweb
synced 2026-05-24 09:28:37 +00:00
redis - add REDIS_SSL_VERIFY setting
This commit is contained in:
parent
55450949fa
commit
f38f775f3d
3 changed files with 13 additions and 0 deletions
|
|
@ -25,6 +25,7 @@ function clusterstore:initialize(pool)
|
|||
["REDIS_PORT"] = "",
|
||||
["REDIS_DATABASE"] = "",
|
||||
["REDIS_SSL"] = "",
|
||||
["REDIS_SSL_VERIFY"] = "",
|
||||
["REDIS_TIMEOUT"] = "",
|
||||
["REDIS_KEEPALIVE_IDLE"] = "",
|
||||
["REDIS_KEEPALIVE_POOL"] = "",
|
||||
|
|
@ -57,6 +58,7 @@ function clusterstore:initialize(pool)
|
|||
keepalive_poolsize = tonumber(self.variables["REDIS_KEEPALIVE_POOL"]),
|
||||
connection_options = {
|
||||
ssl = self.variables["REDIS_SSL"] == "yes",
|
||||
ssl_verify = self.variables["REDIS_SSL_VERIFY"] == "yes",
|
||||
},
|
||||
host = self.variables["REDIS_HOST"],
|
||||
port = tonumber(self.variables["REDIS_PORT"]),
|
||||
|
|
|
|||
|
|
@ -50,6 +50,15 @@
|
|||
"regex": "^(yes|no)$",
|
||||
"type": "check"
|
||||
},
|
||||
"REDIS_SSL_VERIFY": {
|
||||
"context": "global",
|
||||
"default": "no",
|
||||
"help": "Verify the certificate of Redis server.",
|
||||
"id": "redis-ssl-verify",
|
||||
"label": "Redis SSL/TLS verify",
|
||||
"regex": "^(yes|no)$",
|
||||
"type": "check"
|
||||
},
|
||||
"REDIS_TIMEOUT": {
|
||||
"context": "global",
|
||||
"default": "1000",
|
||||
|
|
|
|||
|
|
@ -58,6 +58,7 @@ function sessions:init()
|
|||
["REDIS_PORT"] = "",
|
||||
["REDIS_DATABASE"] = "",
|
||||
["REDIS_SSL"] = "",
|
||||
["REDIS_SSL_VERIFY"] = "",
|
||||
["REDIS_TIMEOUT"] = "",
|
||||
["REDIS_KEEPALIVE_IDLE"] = "",
|
||||
["REDIS_KEEPALIVE_POOL"] = "",
|
||||
|
|
@ -124,6 +125,7 @@ function sessions:init()
|
|||
pool = "bw-redis",
|
||||
pool_size = tonumber(redis_vars["REDIS_KEEPALIVE_POOL"]),
|
||||
ssl = redis_vars["REDIS_SSL"] == "yes",
|
||||
ssl_verify = redis_vars["REDIS_SSL_VERIFY"] == "yes",
|
||||
database = tonumber(redis_vars["REDIS_DATABASE"]),
|
||||
}
|
||||
if redis_vars["REDIS_SENTINEL_HOSTS"] ~= nil then
|
||||
|
|
|
|||
Loading…
Reference in a new issue