In preparing for my upcoming presentation at SQL Saturday Vancouver, I needed to setup Redis locally in case of poor internet during my presentation. One of the reasons I went with Redis on Docker is that I can stand up multiple Redis databases and create new ones quickly.
- First download and install docker for Windows from the stable channel.
- Restart your computer.
- After your computer restarts you may or may not be presented with a pop up from Docker asking to enable Hyper-V:
- Click Ok and restart your computer. It may restart more then once while it’s enabling Hyper-V
- Open Power Shell and run command:
docker run -d -p 6379:6379 redis
- An easy way to inspect your Redis instances it to use Redis Desktop Manager
- Once the Redis Desktop Manager is installed click the Connect to Redis Server Button.
- Which will open the connections settings
- Specify a name (I used Redis on Docker)
- Enter localhost for the server
- Leave the port as 6379
- Click Ok
- Now you will see the name of your connection. This is showing you are not connected.
- Click on the name of your connection. Now it will list all the database in the selected Redis Server instance; by default it’s 16.