代码拉取完成,页面将自动刷新
---
kind: ConfigMap
apiVersion: v1
metadata:
namespace: rocketmq
name: configmap-rocketmq-broker-slave-prod
data:
NAMESRV_ADDR: "statefulset-rocketmq-namesrv-prod-0.service-rocketmq-namesrv-prod.rocketmq:9876;statefulset-rocketmq-namesrv-prod-1.service-rocketmq-namesrv-prod.rocketmq:9876"
BROKER_ID: "1"
BROKER_ROLE: "SLAVE"
STATEFULSET_NAME: "statefulset-rocketmq-broker-slave-prod"
SEND_MESSAGE_THREAD_POOL_NUMS: "128"
---
kind: Service
apiVersion: v1
metadata:
namespace: rocketmq
name: service-rocketmq-broker-slave-prod
labels:
app: service-rocketmq-broker-slave-prod
spec:
ports:
- name: rocketmq-port-10909
protocol: TCP
port: 10909
targetPort: 10909
- name: rocketmq-port-10911
protocol: TCP
port: 10911
targetPort: 10911
selector:
app: pod-rocketmq-broker-slave-prod
type: ClusterIP
clusterIP: None
sessionAffinity: ClientIP
---
kind: StatefulSet
apiVersion: apps/v1
metadata:
namespace: rocketmq
name: statefulset-rocketmq-broker-slave-prod
labels:
app: statefulset-rocketmq-broker-slave-prod
spec:
replicas: 1
serviceName: service-rocketmq-broker-slave-prod
selector:
matchLabels:
app: pod-rocketmq-broker-slave-prod
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
app: pod-rocketmq-broker-slave-prod
spec:
nodeSelector:
node-role.kubernetes.io/rocketmq: "true"
imagePullSecrets:
- name: rocketmq-secret-key
containers:
- image: 172.21.88.30/library/rocketmq-broker:4.5.1
securityContext:
privileged: true
imagePullPolicy: Always
name: container-rocketmq-broker-slave-prod
ports:
- protocol: TCP
containerPort: 10909
- protocol: TCP
containerPort: 10911
resources:
requests:
cpu: 5000m
memory: 1.5Gi
limits:
cpu: 5000m
memory: 6.5Gi
envFrom:
- configMapRef:
name: configmap-rocketmq-broker-slave-prod
env:
- name: POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: BROKER_IP1
valueFrom:
fieldRef:
fieldPath: status.podIP
volumeMounts:
- name: host-volume-rocketmq-broker-slave-prod
mountPath: /opt/rocketmq/store
readinessProbe:
tcpSocket:
port: 10909
initialDelaySeconds: 10
periodSeconds: 5
livenessProbe:
tcpSocket:
port: 10909
initialDelaySeconds: 120
periodSeconds: 10
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app
operator: In
values:
- pod-rocketmq-broker-slave-prod
topologyKey: kubernetes.io/hostname
dnsPolicy: ClusterFirst
restartPolicy: Always
volumes:
- name: host-volume-rocketmq-broker-slave-prod
hostPath:
path: /mnt/data/rocketmq-slave
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。