20 lines
865 B
Haskell
20 lines
865 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 }
|
|
, slugDBConf = SQLiteConf "aggreact.db" "slugs"
|
|
, userDBConf = SQLiteConf "aggreact.db" "users"
|
|
, commentDBConf = SQLiteConf "aggreact.db" "comments"
|
|
, authorizationStrategy = Anybody
|
|
}
|
|
mainServe conf
|