当前位置:网站首页>docker安装redis-简单而无坑
docker安装redis-简单而无坑
2022-06-24 19:40:00 【秃了也弱了。】
1.切换root用户
2.下载镜像文件
docker pull redis
3.创建实例并启动
mkdir -p /mydata/redis/conf
touch /mydata/redis/conf/redis.conf
docker run -p 6379:6379 --name redis -v /mydata/redis/data:/data \
-v /mydata/redis/conf/redis.conf:/etc/redis/redis.conf \
-d redis redis-server /etc/redis/redis.conf
4.redis配置文件详细配置(自行修改)
https://raw.githubusercontent.com/antirez/redis/4.0/redis.conf
想要修改配置文件,修改linux主机的/mydata/redis/conf/redis.conf即可
5.使用 redis 镜像执行 redis-cli 命令连接
docker exec -it redis redis-cli
边栏推荐
- 2022年高压电工考试模拟100题及在线模拟考试
- 详细了解关于sentinel的实际应用
- Chapter 10 project communication management
- Programmers become gods by digging holes in one year, carrying flags in five years and becoming gods in ten years
- Leetcode algorithm The first common node of two linked lists
- Row and column differences in matrix construction of DX HLSL and GL glsl
- 加分利器 不负所托 | 知道创宇获攻防演练防守方感谢信!
- CDN principle
- cat写多行内容到文件
- 使用Aggregated APIServer扩展你的kubernetes API
猜你喜欢

Heavyweight! Fada is listed as a "specialized and new" enterprise

Row and column differences in matrix construction of DX HLSL and GL glsl

【Mongodb】READ_ME_TO_RECOVER_YOUR_DATA,数据库被恶意删除

重磅!法大大上榜“专精特新”企业

Data center basic network platform

Wechat side: what is consistent hash? In what scenario? What problems have been solved?

Leetcode: calculate the number of elements less than the current element on the right (sortedlist+bisect\u left)

【Laravel系列7.9】测试

2022-06-16 work record --js- judge the number of digits in string type digits + judge the number of digits in numeric type digits + limit the text length (display n words at most, exceeding...)

中国SSD行业企业势力全景图
随机推荐
环境配置 | VS2017配置OpenMesh源码和环境
结合源码剖析Oauth2分布式认证与授权的实现流程
大厂面试必问:如何解决TCP可靠传输问题?8张图带你详细学习
Heavyweight! Fada is listed as a "specialized and new" enterprise
EPICS记录参考3 -- 所有记录都有的字段
How to solve the problem that the computer suddenly can't connect to WiFi
OSPF basic content
The usage difference between isempty and isblank is so different that so many people can't answer it
The difference between interceptor and filter
别再乱用了,这才是 @Validated 和 @Valid 的真正区别!!!
JWT(Json Web Token)
Leetcode: calculate the number of elements less than the current element on the right (sortedlist+bisect\u left)
加分利器 不负所托 | 知道创宇获攻防演练防守方感谢信!
Virtual private network foundation
2022-06-10 工作记录--JS-获取到某一日期N天后的日期
ACL (access control list) basic chapter - Super interesting learning network
Vulnhub Vegeta: 1
High level application of SQL statements in MySQL database (II)
2022年安全员-A证考题及答案
New, Huawei cloud Kaitian apaas