Commit 38af3f1e authored by Peter's avatar Peter

added support for redis password

parent ce88b74d
...@@ -25,6 +25,7 @@ redis: ...@@ -25,6 +25,7 @@ redis:
bin: /usr/bin/redis-cli bin: /usr/bin/redis-cli
host: 127.0.0.1 host: 127.0.0.1
port: 6379 port: 6379
# pass: redispass # Allows you to specify the password for Redis
# socket: /tmp/redis.socket # Only define this if you want to use sockets # socket: /tmp/redis.socket # Only define this if you want to use sockets
namespace: resque:gitlab namespace: resque:gitlab
......
...@@ -53,7 +53,11 @@ class GitlabConfig ...@@ -53,7 +53,11 @@ class GitlabConfig
if redis.has_key?("socket") if redis.has_key?("socket")
%W(#{redis['bin']} -s #{redis['socket']}) %W(#{redis['bin']} -s #{redis['socket']})
else else
%W(#{redis['bin']} -h #{redis['host']} -p #{redis['port']}) if redis.has_key?("pass")
%W(#{redis['bin']} -h #{redis['host']} -p #{redis['port']} -a #{redis['pass']})
else
%W(#{redis['bin']} -h #{redis['host']} -p #{redis['port']})
end
end end
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment