This commit is contained in:
2026-08-30 13:12:15 +03:00
parent f213b139da
commit 995c5fba0e
15 changed files with 969 additions and 375 deletions
@@ -0,0 +1,3 @@
package pw.binom.llmproxy
actual fun getEnv(name: String): String? = System.getenv(name)
@@ -0,0 +1,15 @@
package pw.binom.llmproxy
import io.ktor.client.HttpClient
import io.ktor.client.engine.cio.CIO
import io.ktor.server.application.Application
import io.ktor.server.cio.CIO as ServerCIO
import io.ktor.server.engine.embeddedServer
actual fun createHttpClient(): HttpClient = HttpClient(CIO)
actual fun startServer(port: Int, module: Application.() -> Unit) {
embeddedServer(ServerCIO, port = port, host = "0.0.0.0") {
module()
}.start(wait = true)
}