Stop tor binary when server is shutdown (#3543)

This commit is contained in:
Chris Stewart 2021-08-13 10:24:47 -05:00 committed by GitHub
parent e08dc636a1
commit bbd3cd2bc4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -81,6 +81,13 @@ class BitcoinSServerMain(override val serverArgParser: ServerArgParser)(implicit
_ <- walletConf.stop()
_ <- nodeConf.stop()
_ <- chainConf.stop()
_ <- {
if (torConf.enabled) {
torConf.createClient.stopBinary()
} else {
Future.unit
}
}
_ = logger.info(s"Stopped ${nodeConf.nodeType.shortName} node")
_ <- system.terminate()
} yield {