mirror of
https://github.com/maxlerebourg/crowdsec-bouncer-traefik-plugin.git
synced 2026-07-21 11:38:59 +02:00
✨ add redis database selection (#100)
* ✨ add redis database selection * 📝 update docs * 📝 readme
This commit is contained in:
Vendored
+2
-2
@@ -82,9 +82,9 @@ type Client struct {
|
||||
}
|
||||
|
||||
// New Initialize cache client.
|
||||
func (client *Client) New(isRedis bool, host string, pass string) {
|
||||
func (client *Client) New(isRedis bool, host, pass, database string) {
|
||||
if isRedis {
|
||||
redis.Init(host, pass)
|
||||
redis.Init(host, pass, database)
|
||||
client.cache = &redisCache{}
|
||||
} else {
|
||||
client.cache = &localCache{}
|
||||
|
||||
Reference in New Issue
Block a user