added nix support
This commit is contained in:
parent
cc77fee048
commit
cb9ae44ec4
6 changed files with 112 additions and 3 deletions
|
|
@ -33,7 +33,8 @@ data AppSettings = AppSettings
|
|||
-- ^ Configuration settings for accessing the database.
|
||||
, appRoot :: Maybe Text
|
||||
-- ^ Base for all generated URLs. If @Nothing@, determined
|
||||
-- from the request headers.
|
||||
, appSessionKey :: [Char]
|
||||
-- ^ Where to get the client session key
|
||||
, appHost :: HostPreference
|
||||
-- ^ Host/interface the server should bind to.
|
||||
, appPort :: Int
|
||||
|
|
@ -74,6 +75,7 @@ instance FromJSON AppSettings where
|
|||
appStaticDir <- o .: "static-dir"
|
||||
appDatabaseConf <- o .: "database"
|
||||
appRoot <- o .:? "approot"
|
||||
appSessionKey <- o .: "session-key"
|
||||
appHost <- fromString <$> o .: "host"
|
||||
appPort <- o .: "port"
|
||||
appIpFromHeader <- o .: "ip-from-header"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue