pom.xml 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <groupId>com.diagbot</groupId>
  7. <artifactId>monitor-service</artifactId>
  8. <version>0.0.1-SNAPSHOT</version>
  9. <packaging>jar</packaging>
  10. <name>monitor-service</name>
  11. <description>Monitor Service for Spring Boot</description>
  12. <parent>
  13. <groupId>com.diagbot</groupId>
  14. <artifactId>diagbotcloud</artifactId>
  15. <version>0.0.1-SNAPSHOT</version>
  16. </parent>
  17. <dependencies>
  18. <dependency>
  19. <groupId>org.springframework.boot</groupId>
  20. <artifactId>spring-boot-starter-web</artifactId>
  21. <exclusions>
  22. <exclusion>
  23. <groupId>org.springframework.boot</groupId>
  24. <artifactId>spring-boot-starter-tomcat</artifactId>
  25. </exclusion>
  26. </exclusions>
  27. </dependency>
  28. <dependency>
  29. <groupId>org.springframework.boot</groupId>
  30. <artifactId>spring-boot-starter-undertow</artifactId>
  31. </dependency>
  32. <dependency>
  33. <groupId>org.springframework.cloud</groupId>
  34. <artifactId>spring-cloud-starter-config</artifactId>
  35. </dependency>
  36. <dependency>
  37. <groupId>org.springframework.cloud</groupId>
  38. <artifactId>spring-cloud-starter-netflix-turbine</artifactId>
  39. </dependency>
  40. <dependency>
  41. <groupId>org.springframework.boot</groupId>
  42. <artifactId>spring-boot-starter-actuator</artifactId>
  43. </dependency>
  44. <!--hystrix-dashboard-->
  45. <dependency>
  46. <groupId>org.springframework.cloud</groupId>
  47. <artifactId>spring-cloud-starter-netflix-hystrix-dashboard</artifactId>
  48. </dependency>
  49. <!--hystrix -->
  50. <dependency>
  51. <groupId>org.springframework.cloud</groupId>
  52. <artifactId>spring-cloud-starter-netflix-hystrix</artifactId>
  53. </dependency>
  54. <dependency>
  55. <groupId>net.logstash.logback</groupId>
  56. <artifactId>logstash-logback-encoder</artifactId>
  57. </dependency>
  58. <dependency>
  59. <groupId>org.springframework.cloud</groupId>
  60. <artifactId>spring-cloud-starter-bus-amqp</artifactId>
  61. </dependency>
  62. </dependencies>
  63. <build>
  64. <plugins>
  65. <plugin>
  66. <groupId>org.springframework.boot</groupId>
  67. <artifactId>spring-boot-maven-plugin</artifactId>
  68. </plugin>
  69. <!-- 添加docker-maven插件 -->
  70. <plugin>
  71. <groupId>com.spotify</groupId>
  72. <artifactId>docker-maven-plugin</artifactId>
  73. <configuration>
  74. <imageName>${docker.image.prefix}/${project.artifactId}:${project.version}</imageName>
  75. <forceTags>true</forceTags>
  76. <!--镜像的FROM,使用压缩的小镜像-->
  77. <baseImage>frolvlad/alpine-oraclejre8:slim</baseImage>
  78. <entryPoint>["java", "-jar", "-Xms256m", "-Xmx1024m", "-Duser.timezone=GMT+8", "/${project.build.finalName}.jar"]</entryPoint>
  79. <resources>
  80. <resource>
  81. <targetPath>/</targetPath>
  82. <directory>${project.build.directory}</directory>
  83. <include>${project.build.finalName}.jar</include>
  84. </resource>
  85. </resources>
  86. <serverId>docker-registry</serverId>
  87. <registryUrl>${registryUrl}</registryUrl>
  88. </configuration>
  89. </plugin>
  90. </plugins>
  91. </build>
  92. </project>