mirror of
https://github.com/urbit/shrub.git
synced 2024-12-19 00:13:12 +03:00
Merge pull request #3267 from urbit/pp/print-http-ports
king: eyre: add missing printouts with ports
This commit is contained in:
commit
36ee3da818
@ -176,8 +176,9 @@ startServ
|
||||
-> Bool
|
||||
-> HttpServerConf
|
||||
-> (EvErr -> STM ())
|
||||
-> (Text -> RIO e ())
|
||||
-> RIO e Serv
|
||||
startServ multi who isFake conf plan = do
|
||||
startServ multi who isFake conf plan stderr = do
|
||||
logDebug (displayShow ("EYRE", "startServ"))
|
||||
|
||||
let vLive = meaLive multi
|
||||
@ -270,6 +271,10 @@ startServ multi who isFake conf plan = do
|
||||
fil = pierPath <> "/.http.ports"
|
||||
|
||||
logDebug $ displayShow ("EYRE", "All Servers Started.", srvId, por, fil)
|
||||
for secPor $ \p ->
|
||||
stderr ("http: secure web interface live on https://localhost:" <> tshow p)
|
||||
stderr ("http: web interface live on http://localhost:" <> tshow insPor)
|
||||
stderr ("http: loopback live on http://localhost:" <> tshow lopPor)
|
||||
|
||||
pure (Serv srvId conf lop ins mSec por fil vLive)
|
||||
|
||||
@ -285,12 +290,14 @@ eyre'
|
||||
=> MultiEyreApi
|
||||
-> Ship
|
||||
-> Bool
|
||||
-> (Text -> RIO e ())
|
||||
-> RIO e ([Ev], RAcquire e (DriverApi HttpServerEf))
|
||||
eyre' multi who isFake = do
|
||||
eyre' multi who isFake stderr = do
|
||||
ventQ :: TQueue EvErr <- newTQueueIO
|
||||
env <- ask
|
||||
|
||||
let (bornEvs, startDriver) = eyre env multi who (writeTQueue ventQ) isFake
|
||||
let (bornEvs, startDriver) =
|
||||
eyre env multi who (writeTQueue ventQ) isFake stderr
|
||||
|
||||
let runDriver = do
|
||||
diOnEffect <- startDriver
|
||||
@ -319,8 +326,9 @@ eyre
|
||||
-> Ship
|
||||
-> (EvErr -> STM ())
|
||||
-> Bool
|
||||
-> (Text -> RIO e ())
|
||||
-> ([Ev], RAcquire e (HttpServerEf -> IO ()))
|
||||
eyre env multi who plan isFake = (initialEvents, runHttpServer)
|
||||
eyre env multi who plan isFake stderr = (initialEvents, runHttpServer)
|
||||
where
|
||||
king = fromIntegral (env ^. kingIdL)
|
||||
|
||||
@ -343,7 +351,7 @@ eyre env multi who plan isFake = (initialEvents, runHttpServer)
|
||||
restart :: Drv -> HttpServerConf -> RIO e Serv
|
||||
restart (Drv var) conf = do
|
||||
logDebug "Restarting http server"
|
||||
let startAct = startServ multi who isFake conf plan
|
||||
let startAct = startServ multi who isFake conf plan stderr
|
||||
res <- fromEither =<< restartService var startAct kill
|
||||
logDebug "Done restating http server"
|
||||
pure res
|
||||
|
@ -434,7 +434,7 @@ drivers env multi who isFake plan termSys stderr serfSIGINT = do
|
||||
(behnBorn, runBehn) <- rio Behn.behn'
|
||||
(termBorn, runTerm) <- rio (Term.term' termSys serfSIGINT)
|
||||
(amesBorn, runAmes) <- rio (Ames.ames' who isFake stderr)
|
||||
(httpBorn, runEyre) <- rio (Eyre.eyre' multi who isFake)
|
||||
(httpBorn, runEyre) <- rio (Eyre.eyre' multi who isFake stderr)
|
||||
(clayBorn, runClay) <- rio Clay.clay'
|
||||
(irisBorn, runIris) <- rio Iris.client'
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user