https://kotlinlang.org logo
#ktor
Title
# ktor
r

rebok

12/08/2023, 1:04 PM
Does ktor support hot reloading of ssl certs?
a

Aleksei Tirman [JB]

12/08/2023, 1:05 PM
No. There is a pending feature request.
r

rebok

12/08/2023, 1:12 PM
And is there a engine specific implementation of this? I mean does any engine support it?
Maybe having a custom KeyStore will do the job
a

Aleksei Tirman [JB]

12/08/2023, 1:50 PM
Jetty has the
ssl-reload
module.
r

rebok

12/08/2023, 2:57 PM
Thanks, i will try using that
Do i need to use ktor implementation of SSL or the jetty one? And also, how do i call sslContextFactory.reload() when using an embededServer?
a

Aleksei Tirman [JB]

12/10/2023, 3:03 PM
I think you need to configure SSL on the Jetty's side. You can configure the Jetty's server by using the
configureServer
method:
Copy code
embeddedServer(Jetty, applicationEngineEnvironment {}) {
    configureServer = { // this: Server
        // Configure SSL here
    }
}.start(wait = true)