1. 安装文档 https://hub.docker.com/_/redis 2. 启动:
docker run -p 6379:6379 -v /lxh/myredis/data:/data -v /lxh/myredis/conf/redis.conf:/usr/local/etc/redis/redis.conf -d redis redis-server /usr/local/etc/redis/redis.conf 3. 测试 docker exec -it redis启动的容器id redis-cli 2.redis.conf 参考
<1> 下载
<2> 修改点
a. 注释掉 bind 127.0.0.1 -::1
b. protected-mode 值改为no