json configs

This commit is contained in:
2026-05-27 15:24:38 +03:00
parent 554fc024b1
commit 62f32c97c3
5 changed files with 89 additions and 16 deletions

View File

@ -5,11 +5,11 @@ import java.net.ServerSocket
import java.net.Socket
import java.io.DataInputStream
fun startServer(port: Int) = runBlocking {
val tun = TunDevice("10.1.0.1")
fun startServer(address: String, port: Int) = runBlocking {
val tun = TunDevice(address)
val server = ServerSocket(port)
println("Server started")
println("Server started on $port")
while (true) {
val client = server.accept()