-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
83 lines (71 loc) · 1.78 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
buildscript {
ext.kotlin_version = '1.3.61'
repositories {
jcenter()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
apply plugin: 'java'
apply plugin: 'kotlin'
sourceSets {
main.kotlin.srcDirs = [ 'src/main/kotlin' ]
}
repositories {
mavenCentral()
maven { url 'https://jitpack.io' }
maven { url "https://dl.bintray.com/kyonifer/maven" }
jcenter()
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
compile 'com.github.kwebio:kweb-core:0.5.17'
//compile 'com.google.cloud:google-cloud-logging-logback:0.116.0-alpha'
compile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.30'
compile 'com.ibm.icu:icu4j:65.1'
compile group: "com.kyonifer", name:"koma-core-ejml", version: "0.12"
compile group: "com.kyonifer", name:"koma-plotting", version: "0.12"
compile 'com.github.ajalt:colormath:1.4.0'
compile 'com.beust:klaxon:5.0.1'
}
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
jar {
manifest {
attributes 'Main-Class': 'com.github.heathwinning.AppKt'
}
from {
configurations.compile.collect {
it.isDirectory() ? it : zipTree(it)
}
}
}
task dockerBuild {
dependsOn jar
doLast {
exec {
commandLine 'docker', 'build', '-t', 'moneypools', '.'
}
}
}
task dockerRun {
dependsOn dockerBuild
doLast {
exec {
commandLine 'docker', 'run', '-m512M', '--cpus', '2', '-p', '8080:8080', '--rm', 'moneypools'
}
}
}
task gaeDeploy {
dependsOn dockerBuild
doLast {
exec {
commandLine 'gcloud', 'app', 'deploy'
}
}
}