docker run -d –name rocketmq-dashboard -e “JAVA_OPTS=-Drocketmq.namesrv.addr=127.0.0.1:9876” -p 8080:8080 -t apacherocketmq/rocketmq-dashboard:latest
-XX:MaxHeapSize=256M -Drocketmq.namesrv.addr=rocketmq-nameserver:9876
在服务器根目录下,创建 rocketmq-dashboard.yaml 文件,文件内容为:
---
apiVersion: v1
kind: Service
metadata:
name: rocketmq-dashboard-svc
annotations:
kubesphere.io/alias-name: RocketMQ 管理控制台
kubesphere.io/description: RocketMQ 管理控制台
spec:
ports:
- name: tcp-8080
port: 8080
protocol: TCP
targetPort: 8080
selector:
app: rocketmq-dashboard
type: NodePort
---
kind: Deployment
apiVersion: apps/v1
metadata:
name: rocketmq-dashboard-deploy
annotations:
kubesphere.io/alias-name: RocketMQ 管理控制台
kubesphere.io/description: RocketMQ 管理控制台
spec:
replicas: 1
selector:
matchLabels:
app: rocketmq-dashboard
template:
metadata:
labels:
app: rocketmq-dashboard
spec:
containers:
- name: rocketmq-dashboard
image: 'apacherocketmq/rocketmq-dashboard:latest'
ports:
- containerPort: 8080
protocol: TCP
env:
- name: JAVA_OPTS
value: >-
-Drocketmq.namesrv.addr=127.0.0.1:9876
- name: JAVA_TOOL_OPTIONS
value: >-
-XX:+PrintGCDetails -XX:+PrintGCTimeStamps -XX:GCLogFileSize=20m
-XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=/logs/heaperror.log
-Xloggc:/logs/gcerror.log
imagePullPolicy: Always
使用 kubectl 执行如下命令部署 mindoc 服务 :
kubectl apply -f mindoc.yaml --namespace=你的命名空间
kubectl apply -f mindoc.yaml --namespace=dw-prod
作者:Jeebiz 创建时间:2023-01-23 02:29
最后编辑:Jeebiz 更新时间:2024-11-01 10:05
最后编辑:Jeebiz 更新时间:2024-11-01 10:05