* feat(server): persist accounts and characters in PostgreSQL via jOOQ, HikariCP, and Flyway * test: reword test names to match the writing style * docs: explain the database setup and dev seeding
51 lines
1.3 KiB
Kotlin
51 lines
1.3 KiB
Kotlin
plugins {
|
|
application
|
|
id("buildsrc.convention.kotlin-jvm")
|
|
id("buildsrc.convention.spotless")
|
|
id("buildsrc.convention.sonarlint")
|
|
id("buildsrc.common.keys")
|
|
id("buildsrc.convention.jooq-db")
|
|
alias(libs.plugins.ksp)
|
|
}
|
|
|
|
group = "de.fiereu.openmmo"
|
|
|
|
version = "0.1.0"
|
|
|
|
application { mainClass.set("de.fiereu.openmmo.server.login.MainKt") }
|
|
|
|
jooqDb { packageName = "de.fiereu.openmmo.db.login" }
|
|
|
|
dependencies {
|
|
api(project(":network"))
|
|
api(project(":protocols.login"))
|
|
api(project(":common"))
|
|
|
|
implementation(libs.dagger)
|
|
ksp(libs.dagger.compiler)
|
|
|
|
implementation(libs.typesafe.config)
|
|
implementation(libs.kotlinx.coroutines)
|
|
implementation(libs.kotlin.logging)
|
|
implementation(libs.logback)
|
|
|
|
testImplementation(libs.bundles.kotest)
|
|
testImplementation(libs.kotlinx.coroutines.test)
|
|
}
|
|
|
|
tasks.named<JavaExec>("run") {
|
|
listOf(
|
|
"OPENMMO_SESSION_SECRET",
|
|
"LOGIN_DB_HOST",
|
|
"LOGIN_DB_PORT",
|
|
"LOGIN_DB_NAME",
|
|
"LOGIN_DB_USER",
|
|
"LOGIN_DB_PASSWORD",
|
|
"LOGIN_DB_SEED_DEV")
|
|
.forEach { key -> env.fetchOrNull(key)?.let { environment(key, it) } }
|
|
}
|
|
|
|
listOf("classes", "processResources").forEach { taskName ->
|
|
tasks.named(taskName) { dependsOn("copyPublicKeyGame", "copyPrivateKeyGame") }
|
|
}
|