tjb
02/20/2018, 7:35 PMgroup 'canti'
version '1.0-SNAPSHOT'
buildscript {
ext.company = 'test'
ext.kotlin_version = '1.1.51'
ext.ktor_version = '0.9.0'
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "se.transmode.gradle:gradle-docker:1.2"
}
}
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'application'
apply plugin: 'docker'
sourceCompatibility = 1.8
mainClassName = 'io.ktor.server.netty.DevelopmentEngine'
repositories {
mavenCentral()
jcenter()
maven { url "<http://dl.bintray.com/kotlin/ktor>" }
maven { url "<https://dl.bintray.com/kotlin/kotlinx>" }
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jre8:$kotlin_version"
compile "io.ktor:ktor-server-netty:$ktor_version"
compile "com.ullink.slack:simpleslackapi:1.0.0"
compile "org.glassfish.tyrus.bundles:tyrus-standalone-client:1.8.3"
compile "com.github.salomonbrys.kodein:kodein:4.1.0"
compile "com.fasterxml.jackson.module:jackson-module-kotlin:2.9.0"
compile "com.github.kittinunf.fuel:fuel-jackson:1.12.0"
compile "com.beust:klaxon:0.30"
compile "io.ktor:ktor-jackson:0.9.0"
compile "org.slf4j:jul-to-slf4j:1.7.12"
compile "ch.qos.logback:logback-classic:1.2.1"
testCompile group: 'junit', name: 'junit', version: '4.12'
}
version = "1.0.1"
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
kotlin {
experimental {
coroutines "enable"
}
}
jar {
baseName = "canti"
}
/**
* Docker
*/
task dockerize(type: Docker) {
applicationName = jar.baseName
tag = "${applicationName}"
setEnvironment('JAR_BASE', "${jar.baseName}")
setEnvironment('JAR_NAME', "${jar.baseName}-${version}")
dockerfile = file("docker/Dockerfile")
doFirst {
copy {
from jar
into stageDir
}
}
}