Setup Redis & Go with Docker Compose ( Redis CLI setup included )



Setup Redis & Go with Docker Compose ( Redis CLI setup included )

Setup Redis & Go with Docker Compose ( Redis CLI setup included )

How to setup Go (golang) and Redis with Docker Compose. Also shows how to use Redis CLI to read keys and config within the docker container itself. In addition a custom config for redis is added which can be customized throughout. If done, the container might need to be rebuilt.
Instead of building the Go dockerfile, the image can be used instead. Just remember to build the image and add it like the redis service. If you need a video on this, let me know.

I’ve added the code directly to avoid wasting time watching me type it out line by line.
For development the required package is: https://github.com/go-redis/redis
go get github.com/go-redis/redis and make sure the correct type is imported in the code and compose file. This doesn’t use go modules but I can make another video on this if requested .

Code: https://github.com/Jasoncheung94/youtube-projects-code/tree/main/redis-go-docker

––––––––––––––––––––––––––––––
Track: Good Evening — Amine Maxwell [Audio Library Release]
Music provided by Audio Library Plus
Watch: https://youtu.be/2BEJUXf_U38
Free Download / Stream: https://alplus.io/good-evening
––––––––––––––––––––––––––––––

Comments are closed.