pom.xml 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  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>config-server</artifactId>
  8. <version>0.0.1-SNAPSHOT</version>
  9. <packaging>jar</packaging>
  10. <name>config-server</name>
  11. <description>Config Server 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-config-server</artifactId>
  35. </dependency>
  36. <!-- actuator-->
  37. <dependency>
  38. <groupId>org.springframework.boot</groupId>
  39. <artifactId>spring-boot-starter-actuator</artifactId>
  40. </dependency>
  41. <!--<dependency>-->
  42. <!--<groupId>org.springframework.cloud</groupId>-->
  43. <!--<artifactId>spring-cloud-starter-bus-amqp</artifactId>-->
  44. <!--</dependency>-->
  45. <!--&lt;!&ndash;热部署引用&ndash;&gt;-->
  46. <!--<dependency>-->
  47. <!--<groupId>org.springframework.boot</groupId>-->
  48. <!--<artifactId>spring-boot-devtools</artifactId>-->
  49. <!--<optional>true</optional>-->
  50. <!--</dependency>-->
  51. <dependency>
  52. <groupId>org.springframework.cloud</groupId>
  53. <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
  54. </dependency>
  55. <dependency>
  56. <groupId>net.logstash.logback</groupId>
  57. <artifactId>logstash-logback-encoder</artifactId>
  58. </dependency>
  59. <dependency>
  60. <groupId>org.springframework.retry</groupId>
  61. <artifactId>spring-retry</artifactId>
  62. </dependency>
  63. <dependency>
  64. <groupId>org.springframework.boot</groupId>
  65. <artifactId>spring-boot-starter-aop</artifactId>
  66. </dependency>
  67. <dependency>
  68. <groupId>org.jolokia</groupId>
  69. <artifactId>jolokia-core</artifactId>
  70. </dependency>
  71. </dependencies>
  72. <build>
  73. <plugins>
  74. <plugin>
  75. <groupId>org.springframework.boot</groupId>
  76. <artifactId>spring-boot-maven-plugin</artifactId>
  77. </plugin>
  78. <!-- 添加docker-maven插件 -->
  79. <plugin>
  80. <groupId>com.spotify</groupId>
  81. <artifactId>docker-maven-plugin</artifactId>
  82. <configuration>
  83. <imageName>${docker.image.prefix}/${project.artifactId}:${project.version}</imageName>
  84. <forceTags>true</forceTags>
  85. <!--镜像的FROM,使用压缩的小镜像-->
  86. <baseImage>frolvlad/alpine-oraclejdk8:slim</baseImage>
  87. <entryPoint>["java", "-jar", "/${project.build.finalName}.jar"]</entryPoint>
  88. <resources>
  89. <resource>
  90. <targetPath>/</targetPath>
  91. <directory>${project.build.directory}</directory>
  92. <include>${project.build.finalName}.jar</include>
  93. </resource>
  94. </resources>
  95. </configuration>
  96. </plugin>
  97. </plugins>
  98. </build>
  99. </project>