mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI-examples.git
synced 2024-12-22 08:37:18 +00:00
add opportunity to set port different with 8080 in WebAppServer sample
This commit is contained in:
parent
c6019b1862
commit
3925ef9423
@ -43,14 +43,13 @@ suspend fun main(vararg args: String) {
|
||||
val bot = telegramBot(telegramBotAPIUrlsKeeper)
|
||||
createKtorServer(
|
||||
"0.0.0.0",
|
||||
8080,
|
||||
args.getOrNull(2) ?.toIntOrNull() ?: 8080,
|
||||
additionalEngineEnvironmentConfigurator = {
|
||||
parentCoroutineContext += Dispatchers.IO
|
||||
}
|
||||
) {
|
||||
routing {
|
||||
static {
|
||||
files(File("WebApp/build/distributions"))
|
||||
staticFiles("", File("WebApp/build/distributions")) {
|
||||
default("WebApp/build/distributions/index.html")
|
||||
}
|
||||
post("inline") {
|
||||
|
Loading…
Reference in New Issue
Block a user