@ -2,6 +2,7 @@ FROM ubuntu
# 设置固定的项目路径
ENV WORKDIR /Open-IM-Server
ENV CMDDIR $WORKDIR/cmd
ENV CONFIG_NAME $WORKDIR/config/config.yaml
@ -15,5 +16,5 @@ RUN mkdir $WORKDIR/logs $WORKDIR/config $WORKDIR/script && \
VOLUME ["/Open-IM-Server/logs","/Open-IM-Server/config", "/Open-IM-Server/script"]
WORKDIR $WORKDIR
CMD ./cmd/main
WORKDIR $CMDDIR
CMD ./main
# 将可执行文件复制到目标目录
@ -14,5 +15,5 @@ RUN mkdir $WORKDIR/logs $WORKDIR/config $WORKDIR/script && \
VOLUME ["/Open-IM-Server/logs","/Open-IM-Server/config","/Open-IM-Server/script"]
@ -16,7 +16,7 @@ spec:
containers:
- name: api
image: openim/api:v2.0.10k
# imagePullPolicy: Always
imagePullPolicy: Always
ports:
- containerPort: 10002
volumeMounts:
@ -42,3 +42,4 @@ spec:
targetPort: 10002
selector:
app: api
type: NodePort
targetPort: 10006
app: cms-api
targetPort: 10004
app: demo
@ -45,5 +45,6 @@ spec:
targetPort: ws-port
app: msg-gateway
@ -49,5 +49,6 @@ spec:
targetPort: 10003
app: sdk-server