uni2work.workflows.visualiser/server/ServerMain.hs
2023-09-04 20:16:02 +02:00

20 lines
520 B
Haskell

-- SPDX-FileCopyrightText: 2023 David Mosbach <david.mosbach@campus.lmu.de>
--
-- SPDX-License-Identifier: AGPL-3.0-or-later
module ServerMain where
import Routes (workFlows, files)
import Network.Wai
import Network.Wai.Handler.Warp ( run )
import Control.Concurrent
serverMain :: IO ()
serverMain = do
putStrLn "Starting app @ http://localhost:8081/"
mainServerThread <- forkIO $ run 8081 workFlows
putStrLn "Main server is running"
putStrLn "Starting file server @ http://localhost:8080/"
run 8080 files