<p>You'll want to set your <a href="http://buildwithcraft.com/docs/config-settings#cacheMethod" rel="nofollow">cacheMethod</a> config setting to 'redis' and create a <code>rediscache.php</code> file in <code>craft/config/</code>.</p>

<p>That config file is multi-environment aware, just like the other files in <code>craft/config/</code> and you can see the default settings for Redis in <code>craft/app/etc/config/defaults/rediscache.php</code>.</p>

CC BY-SA 3.0
2014-12-15T17:00:25.747Z
2014-12-15T17:00:25.747Z
Brad Bell
<p>I'm not entirely well versed in how Redis works, but I have an idea that it probably makes the most sense to have the 3 craft sites I have running on the same server, have 3 different redis databases assigned to each?</p>

<p>Is there a way to do so, like in <code>general.php</code> or <code>db.php</code></p>

<p>As in </p>

<pre><code>"site-one.com" =&gt; {
    'database' =&gt; 0,
},

"site-two.com" =&gt; {
    'database =&gt; 1,
}
</code></pre>

<cache>
Redis Enviornment Specific DB's
# Redis Enviornment Specific DB's

(Asked by: username_0 on 2014-12-15)

I'm not entirely well versed in how Redis works, but I have an idea that it probably makes the most sense to have the 3 craft sites I have running on the same server, have 3 different redis databases assigned to each?
Is there a way to do so, like in general.php or db.php
As in 
"site-one.com" => {
    'database' => 0,
},

"site-two.com" => {
    'database => 1,
}

**Tags:** cache


---

## 1 answers

### Answer by username_1 on 2014-12-15. Score: 2 | Accepted answer

You'll want to set your [cacheMethod](http://buildwithcraft.com/docs/config-settings#cacheMethod) config setting to 'redis' and create a `rediscache.php` file in `craft/config/`.

That config file is multi-environment aware, just like the other files in `craft/config/` and you can see the default settings for Redis in `craft/app/etc/config/defaults/rediscache.php`.


---

