|
@@ -15,6 +15,25 @@
|
|
|
web服务入口
|
|
|
</description>
|
|
|
|
|
|
+ <profiles>
|
|
|
+ <profile>
|
|
|
+ <id>dev</id>
|
|
|
+ <properties>
|
|
|
+ <env>dev</env>
|
|
|
+ </properties>
|
|
|
+ <activation>
|
|
|
+ <activeByDefault>true</activeByDefault>
|
|
|
+ </activation>
|
|
|
+ </profile>
|
|
|
+ <profile>
|
|
|
+ <id>prod</id>
|
|
|
+ <properties>
|
|
|
+ <env>prod</env>
|
|
|
+ </properties>
|
|
|
+ </profile>
|
|
|
+ </profiles>
|
|
|
+
|
|
|
+
|
|
|
<dependencies>
|
|
|
|
|
|
<!-- spring-boot-devtools -->
|
|
@@ -64,6 +83,26 @@
|
|
|
</dependencies>
|
|
|
|
|
|
<build>
|
|
|
+ <resources>
|
|
|
+ <resource>
|
|
|
+ <directory>src/main/resources/</directory>
|
|
|
+ <!--打包时先排除掉文件夹-->
|
|
|
+ <excludes>
|
|
|
+<!-- <exclude>sit/*</exclude>-->
|
|
|
+ <exclude>prod/*</exclude>
|
|
|
+<!-- <exclude>test/*</exclude>-->
|
|
|
+ <exclude>dev/*</exclude>
|
|
|
+ </excludes>
|
|
|
+ <includes>
|
|
|
+ <!--如果有其他定义通用文件,需要包含进来-->
|
|
|
+ <!--<include>messages/*</include>-->
|
|
|
+ </includes>
|
|
|
+ </resource>
|
|
|
+ <resource>
|
|
|
+ <!--根据不同的环境,把对应文件夹里的配置文件打包-->
|
|
|
+ <directory>src/main/resources/${env}</directory>
|
|
|
+ </resource>
|
|
|
+ </resources>
|
|
|
<plugins>
|
|
|
<plugin>
|
|
|
<groupId>org.springframework.boot</groupId>
|