You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
481 B
20 lines
481 B
3 years ago
|
FROM ubuntu
|
||
|
|
||
|
# 设置固定的项目路径
|
||
3 years ago
|
ENV WORKDIR /Open-IM-Server
|
||
2 years ago
|
ENV CMDDIR $WORKDIR/cmd
|
||
3 years ago
|
ENV CONFIG_NAME $WORKDIR/config/config.yaml
|
||
|
|
||
|
# 将可执行文件复制到目标目录
|
||
3 years ago
|
ADD ./open_im_api $WORKDIR/cmd/main
|
||
3 years ago
|
|
||
|
# 创建用于挂载的几个目录,添加可执行权限
|
||
3 years ago
|
RUN mkdir $WORKDIR/logs $WORKDIR/config $WORKDIR/script && \
|
||
3 years ago
|
chmod +x $WORKDIR/cmd/main
|
||
3 years ago
|
|
||
3 years ago
|
VOLUME ["/Open-IM-Server/logs","/Open-IM-Server/config","/Open-IM-Server/script"]
|
||
3 years ago
|
|
||
|
|
||
2 years ago
|
WORKDIR $CMDDIR
|
||
|
CMD ./main
|