ktor-server-host-common / io.ktor.server.engine / kotlinx.coroutines.CoroutineScope

Extensions for kotlinx.coroutines.CoroutineScope

embeddedServer

fun <TEngine : ApplicationEngine, TConfiguration : Configuration> CoroutineScope.embeddedServer(factory: ApplicationEngineFactory<TEngine, TConfiguration>, port: Int = 80, host: String = "0.0.0.0", watchPaths: List<String> = listOf(WORKING_DIRECTORY_PATH), parentCoroutineContext: <ERROR CLASS> = EmptyCoroutineContext, configure: TConfiguration.() -> Unit = {}, module: Application.() -> Unit): TEngine

Creates an embedded server with the given factory, listening on host:port