diff --git a/docker/deploy.sh b/docker/deploy.sh index 0ee4cd8a..11bbbd89 100644 --- a/docker/deploy.sh +++ b/docker/deploy.sh @@ -26,7 +26,7 @@ port(){ # 启动基础环境(必须) base(){ - docker-compose up -d ruoyi-mysql ruoyi-redis ruoyi-nacos ruoyi-nginx + docker-compose up -d ruoyi-mysql ruoyi-redis ruoyi-nacos ruoyi-nginx sentinel } # 启动程序模块(必须) diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index 5fb8da1c..b07d30c4 100644 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -1,5 +1,12 @@ version : '3.8' services: + sentinel: + container_name: sentinel + build: + context: ./sentinel + dockerfile: dockerfile + ports: + - "8718:8718" ruoyi-nacos: container_name: ruoyi-nacos image: nacos/nacos-server diff --git a/docker/sentinel/dockerfile b/docker/sentinel/dockerfile new file mode 100644 index 00000000..73fae7a2 --- /dev/null +++ b/docker/sentinel/dockerfile @@ -0,0 +1,15 @@ +# 基础镜像 +FROM openjdk:8-jre +# author +MAINTAINER ruoyi + +# 挂载目录 +VOLUME /home/ruoyi +# 创建目录 +RUN mkdir -p /home/ruoyi +# 指定路径 +WORKDIR /home/ruoyi +# 复制jar文件到路径 +COPY ./jar/sentinel-dashboard-1.8.0.jar /home/ruoyi/sentinel-dashboard-1.8.0.jar +# 启动认证服务 +ENTRYPOINT ["java","-Dserver.port=8718","-Dcsp.sentinel.dashboard.server=localhost:8718","-Dproject.name=sentinel-dashboard","-jar","sentinel-dashboard-1.8.0.jar"] \ No newline at end of file diff --git a/docker/sentinel/jar/sentinel-dashboard-1.8.0.jar b/docker/sentinel/jar/sentinel-dashboard-1.8.0.jar new file mode 100644 index 00000000..b90c4a43 Binary files /dev/null and b/docker/sentinel/jar/sentinel-dashboard-1.8.0.jar differ