|NO.Z.00263|——————————|CloudNative|——|KuberNetes&中间件容器化及helm.V10|——|中间件.v10|redis.v5.0.4|redis自定义账号密码|

一、redis集群自定义账号密码
### --- 自定义账号密码

[root@k8s-master01 redis-cluster-operator]# more deploy/example/custom-password.yaml 
apiVersion: v1
kind: Secret
metadata:
  annotations:
    # if your operator run as cluster-scoped, add this annotations
    redis.kun/scope: cluster-scoped
  name: mysecret
type: Opaque
data:
  password: MWYyZDFlMmU2N2Rm
### --- 查看账号密码;账号面是经过base64加密的,更改的时候也需要通过base64加密

[root@k8s-master01 redis-cluster-operator]# echo "MWYyZDFlMmU2N2Rm" | base64
TVdZeVpERmxNbVUyTjJSbQo=
### --- 更改密码为password,先通过base64加密

[root@k8s-master01 redis-cluster-operator]# echo "password" | base64
cGFzc3dvcmQK
### --- 然后更改custom-password.yaml 中的参数

[root@k8s-master01 redis-cluster-operator]# more deploy/example/custom-password.yaml 
    # if your operator run as cluster-scoped, add this annotations
    redis.kun/scope: cluster-scoped
  name: mysecret
type: Opaque
data:
  password: cGFzc3dvcmQK        // 更改密码参数即可

 
 
 
 
 
 
 
 
 

Walter Savage Landor:strove with none,for none was worth my strife.Nature I loved and, next to Nature, Art:I warm'd both hands before the fire of life.It sinks, and I am ready to depart
                                                                                                                                                   ——W.S.Landor

 

 

posted on   yanqi_vip  阅读(27)  评论(0编辑  收藏  举报

相关博文:
阅读排行:
· 全程不用写代码,我用AI程序员写了一个飞机大战
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 记一次.NET内存居高不下排查解决与启示
· DeepSeek 开源周回顾「GitHub 热点速览」
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

导航

统计

点击右上角即可分享
微信分享提示