mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-12-13 08:37:08 +08:00
1.官网文档创建configmap名字已经从openim-config改为了config,部署文件内建议保持一致 2.创建usualConfig的configmap会报错,建议改成usual-config,官网文档建议改为 kubectl -n openim create configmap usual-config --from-file=config/usualConfig.yaml 3.调整了部分yaml缩紧格式更加正确
42 lines
1.0 KiB
YAML
42 lines
1.0 KiB
YAML
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: cache-deployment
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
app: cache # 选择这个指定标签执行
|
|
replicas: 1 # 运行pod数量
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: cache # 标签
|
|
spec:
|
|
containers:
|
|
- name: cache
|
|
image: openim/cache:v2.3.4
|
|
# imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 10240
|
|
volumeMounts:
|
|
- name: config
|
|
mountPath: /Open-IM-Server/config
|
|
readOnly: true
|
|
- name: usualConfig
|
|
mountPath: /Open-IM-Server/config
|
|
readOnly: true
|
|
env:
|
|
- name: CONFIG_NAME
|
|
value: "/Open-IM-Server"
|
|
- name: USUAL_CONFIG_NAME
|
|
value: "/Open-IM-Server"
|
|
volumes:
|
|
- name: config
|
|
configMap:
|
|
name: config
|
|
- name: usualConfig
|
|
configMap:
|
|
name: usual-config
|
|
strategy: #更新策略
|
|
type: RollingUpdate # 滚动更新 |