We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d341f11 + da9d780 commit 5de9073Copy full SHA for 5de9073
lib/Resque/Redis.php
@@ -148,6 +148,7 @@ public function __construct($server, $database = null)
148
* - host:port
149
* - redis://user:pass@host:port/db?option1=val1&option2=val2
150
* - tcp://user:pass@host:port/db?option1=val1&option2=val2
151
+ * - unix:///path/to/redis.sock
152
*
153
* Note: the 'user' part of the DSN is not used.
154
@@ -161,6 +162,16 @@ public static function parseDsn($dsn)
161
162
// Use a sensible default for an empty DNS string
163
$dsn = 'redis://' . self::DEFAULT_HOST;
164
}
165
+ if(substr($dsn, 0, 7) === 'unix://') {
166
+ return array(
167
+ $dsn,
168
+ null,
169
+ false,
170
171
172
173
+ );
174
+ }
175
$parts = parse_url($dsn);
176
177
// Check the URI scheme
0 commit comments