aggreact/src-exe/Main.hs
2019-03-10 20:44:33 +01:00

19 lines
799 B
Haskell

import Protolude
import Aggreact (mainServe,Conf(..),AuthorizationStrategy(..))
import Database.Store.Backend.SQLite (DBConf (SQLiteConf))
import Servant.Auth.Server
main :: IO ()
main = do
let conf = Conf { port = 3000
, jwtKeyFilePath = "jwt.key"
, cookieSettings = defaultCookieSettings
{ cookieIsSecure = NotSecure
, cookieXsrfSetting = Nothing
, cookieSameSite = AnySite }
, userDBConf = SQLiteConf "aggreact.db" "users"
, commentDBConf = SQLiteConf "aggreact.db" "comments"
, authorizationStrategy = Anybody
}
mainServe conf