当前位置:网站首页>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
边栏推荐
- Research Report on market supply and demand and strategy of ceiling power supply device industry in China
- 【Laravel系列7.9】测试
- 加分利器 不负所托 | 知道创宇获攻防演练防守方感谢信!
- Future development of education industry of e-commerce Express
- STP spanning tree protocol Foundation
- Data center basic network platform
- 糖豆人登录报错解决方案
- 上新了,华为云开天aPaaS
- 2022-06-10 工作记录--JS-获取到某一日期N天后的日期
- Online filing process
猜你喜欢

Idea global search replace shortcut key

双亲委派机制

Future development of education industry of e-commerce Express

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

The core concept of JMM: happens before principle

High level application of SQL statements in MySQL database (I)
![[QT] QT event handling](/img/48/14a5491307fee1c99434d6cb308337.jpg)
[QT] QT event handling

DX 的 HLSL 和 GL 的 GLSL的 矩阵构建的行列区别

Learn more about the practical application of sentinel

CDN principle
随机推荐
Nuscenes -- remedies for missing image files or 0-size images encountered during dataset configuration
ThreadLocal内存泄漏问题
面试害怕被问MySQL相关问题 ?这份三万字精华总结 + 面试100 问,吊打面试官完全够了
Solve the problem of non secure websites requesting localhost to report CORS after chrome94
Principle of IP routing
Chapter 10 project communication management
vulnhub Vegeta: 1
别再乱用了,这才是 @Validated 和 @Valid 的真正区别!!!
Environment configuration | vs2017 configuring openmesh source code and environment
Unable to use the bean introduced into the jar package
Can AI chat robots replace manual customer service?
See how sparksql supports enterprise data warehouse
Layer 2 and layer 3 forwarding principle based on VLAN
Row and column differences in matrix construction of DX HLSL and GL glsl
1. fully explain the basic principles of IPSec
【武汉大学】考研初试复试资料分享
Virtual private network foundation
Learn more about the practical application of sentinel
【Mongodb】READ_ ME_ TO_ RECOVER_ YOUR_ Data, the database is deleted maliciously
上新了,华为云开天aPaaS