blob: 0381f48991d184438f8b5a1a9a648798917e7550 [file] [log] [blame]
Tang Chenge7d3a0e2019-07-08 16:27:33 +08001plugins {
2 id 'java'
Tang Cheng22731312019-07-12 11:19:30 +08003 id 'org.springframework.boot'
4 id 'org.jetbrains.kotlin.jvm'
Tang Chenge7d3a0e2019-07-08 16:27:33 +08005 id 'org.jetbrains.kotlin.plugin.jpa' version '1.3.31'
Tang Cheng22731312019-07-12 11:19:30 +08006 id 'org.jetbrains.kotlin.plugin.spring'
7 id "com.palantir.git-version"
8 id 'com.palantir.docker'
Tang Chenge7d3a0e2019-07-08 16:27:33 +08009}
10
11apply plugin: 'java'
12apply plugin: 'io.spring.dependency-management'
13
14payapiVersion = gitVersion()
15
Tang Cheng40993e12019-07-08 16:38:51 +080016group = rootProject.group
Tang Chenge7d3a0e2019-07-08 16:27:33 +080017version = '1'
18sourceCompatibility = jdkVersion
Tang Cheng8beabcd2019-07-12 11:48:01 +080019def payapiStartClass = 'com.supwisdom.dlpay.PayApiApplicationKt'
Tang Chenge7d3a0e2019-07-08 16:27:33 +080020
21println("Build version: $payapiVersion")
Tang Chenge7d3a0e2019-07-08 16:27:33 +080022
23bootJar {
Tang Cheng8beabcd2019-07-12 11:48:01 +080024 mainClassName = payapiStartClass
Tang Chenge7d3a0e2019-07-08 16:27:33 +080025 manifest {
26 attributes('Payapi-Version': payapiVersion)
27 }
28}
29
30jar {
31 baseName = 'payapi'
32}
33
34docker {
35 name 'harbor.supwisdom.com/dali/payapi:' + version
36 println(jar.archivePath)
37 files jar.archivePath
38}
39
40docker.dependsOn(jar)
41
42dependencies {
43 implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
44 implementation 'org.springframework.boot:spring-boot-starter-data-redis'
45 implementation 'org.springframework.boot:spring-boot-starter-web'
46 implementation 'org.springframework.boot:spring-boot-starter-security'
47 implementation 'org.springframework.boot:spring-boot-starter-cache'
48 implementation 'org.springframework.boot:spring-boot-autoconfigure'
49 implementation 'org.springframework.security:spring-security-oauth2-jose'
50 implementation 'org.springframework.security:spring-security-oauth2-client'
51 implementation 'org.springframework.security:spring-security-oauth2-jose'
52 implementation 'org.springframework.security.oauth.boot:spring-security-oauth2-autoconfigure:2.1.5.RELEASE'
53 implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
54 implementation 'org.springframework.session:spring-session-data-redis'
55 implementation 'org.springframework.boot:spring-boot-starter-cache'
56 implementation 'org.springframework.social:spring-social-web:1.1.6.RELEASE'
57 implementation 'org.jetbrains.kotlin:kotlin-reflect'
58 implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8'
59 implementation 'commons-codec:commons-codec:1.12'
Tang Chenge7436342019-07-11 16:04:58 +080060 implementation 'org.apache.commons:commons-lang3:3.9'
Tang Chengacb93a62019-07-18 22:04:48 +080061 implementation 'net.javacrumbs.shedlock:shedlock-spring:2.5.0'
62 implementation 'net.javacrumbs.shedlock:shedlock-provider-redis-spring:2.5.0'
Tang Chenge7d3a0e2019-07-08 16:27:33 +080063
64 implementation 'org.springframework.cloud:spring-cloud-starter-consul-discovery:2.1.2.RELEASE'
65
66 implementation 'org.thymeleaf.extras:thymeleaf-extras-springsecurity5'
67
68 runtime("org.springframework.boot:spring-boot-devtools")
69
70 implementation 'org.postgresql:postgresql:42.2.5'
71 implementation 'com.fasterxml.jackson.module:jackson-module-kotlin'
72 implementation 'com.jcabi:jcabi-manifests:1.1'
Tang Chenge0537a72019-07-13 12:52:07 +080073 implementation 'org.bitbucket.b_c:jose4j:0.6.5'
Tang Chenge7d3a0e2019-07-08 16:27:33 +080074 implementation 'io.github.microutils:kotlin-logging:1.6.26'
75 implementation 'org.slf4j:slf4j-parent:1.7.26'
76 implementation 'com.github.penggle:kaptcha:2.3.2'
77 implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
78 implementation group: 'com.sun.jersey', name: 'jersey-client', version: '1.19'
79 implementation group: 'javax.servlet', name: 'jstl', version: '1.2'
80 implementation group: 'taglibs', name: 'standard', version: '1.1.2'
81 implementation group: 'commons-codec', name: 'commons-codec', version: '1.6'
Tang Chenge0537a72019-07-13 12:52:07 +080082// implementation files('libs/ojdbc6.jar')
Tang Chenge7d3a0e2019-07-08 16:27:33 +080083 implementation 'commons-dbcp:commons-dbcp:1.4'
84
Tang Cheng13911f92019-07-10 09:38:32 +080085 implementation project(':payapi-common')
qiaowei1657eef2019-07-22 17:50:33 +080086 /*支付宝SDK*/
87 implementation group: 'com.alipay.sdk', name: 'alipay-sdk-java', version: '3.7.110.ALL'
Tang Chenge7d3a0e2019-07-08 16:27:33 +080088
89 annotationProcessor "org.springframework.boot:spring-boot-configuration-processor"
90 annotationProcessor 'org.projectlombok:lombok:1.18.8'
91 compileOnly 'org.projectlombok:lombok:1.18.8'
92
93// providedRuntime 'org.springframework.boot:spring-boot-starter-tomcat'
94 testImplementation 'org.springframework.boot:spring-boot-starter-test'
95 testImplementation 'io.rest-assured:rest-assured:3.3.0'
96 testImplementation 'io.rest-assured:spring-mock-mvc:3.3.0'
97 testImplementation 'org.hamcrest:hamcrest:2.1'
98}
99
100compileKotlin {
101 kotlinOptions {
102 freeCompilerArgs = ['-Xjsr305=strict']
103 jvmTarget = jdkVersion
104 }
105}
106
107compileTestKotlin {
108 kotlinOptions {
109 freeCompilerArgs = ['-Xjsr305=strict']
110 jvmTarget = jdkVersion
111 }
112}