How do I run Redis on Windows for my Development?
After reading through couple of articles and threads on stackoverflow I figured out the easiest way is to use install Redis on Vagrant and use port forwarding to connect to Redis from Windows.
Here the steps required
- Download and Install Vagrant.
- Install Redis on Vagrant
- Add necessary repos to Ubuntu
echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list - Install Redis
apt-get update
apt-get -y install redis-server - Configure Redis
Verify redis installation
in order to connect from windows
$ vi /etc/redis/redis.conf
Comment "bind 127.0.0.1" - Enable Port Forwarding in Vagrant
Add the port forwarding configuration to the Vagrant file under the Vagrant\bin folder in windows.
config.vm.network "forwarded_port", guest: 6379, host: 6379 # redis port forwading - Enable firewall ports in windows
Add rules to the windows firewall to enable port 6379 for Redisnetsh advfirewall firewall add rule name="Redis Port 6379" dir=in action=allow protocol=TCP localport=6379netsh advfirewall firewall add rule name="Redis Port 6379" dir=out action=allow protocol=TCP localport=6379 - Connect to Redis using the Redis Desktop Manager