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.
		
		
		
	
	
		
		
			
	
	
		
			
				
					
						
							|  |  |  | /** | 
					
						
							|  |  |  |  * 设置打包文件的运行时目标环境(target) | 
					
						
							|  |  |  |  * 设置方式: 通过命令行 -D 传入目标环境参数 | 
					
						
							|  |  |  |  * 打包命令如下: | 
					
						
							|  |  |  |  * 1. gradle bootwar                  		# 默认, 			target=tomcat | 
					
						
							|  |  |  |  * 2. gradle bootwar -Dtarget=undertow		# undertow,		target=undertow | 
					
						
							|  |  |  |  * 3. gradle bootwar -Dtarget=jetty			# jetty,		target=jetty | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | def target =System.getProperty("target") ?: "undertow"; | 
					
						
							|  |  |  | System.setProperty('target',target); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | // 根据 targetRuntime 变量的值执行实际的 build.gradle
 | 
					
						
							|  |  |  | apply from: "build-${target}.gradle" | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | // 应用启动项目无需发布到仓库中
 | 
					
						
							|  |  |  | publishPublicationPublicationToMavenRepository.enabled=false | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | // 开启 docker 镜像生成任务
 | 
					
						
							|  |  |  | jibBuildTar.enabled =true |