This commit is contained in:
parent
e58c15f1c9
commit
70ec7f5e53
@ -49,7 +49,8 @@ let Config =
|
|||||||
, AppName : Text
|
, AppName : Text
|
||||||
, LiveMode : Bool
|
, LiveMode : Bool
|
||||||
, DevelMode : Bool
|
, DevelMode : Bool
|
||||||
, LoginCookieName : Optional Text
|
, SessionCookieName : Text
|
||||||
|
, SessionCookieSecret : Text
|
||||||
}
|
}
|
||||||
|
|
||||||
let defconf
|
let defconf
|
||||||
@ -61,7 +62,8 @@ let defconf
|
|||||||
, AppName = "pcmt"
|
, AppName = "pcmt"
|
||||||
, LiveMode = False
|
, LiveMode = False
|
||||||
, DevelMode = False
|
, DevelMode = False
|
||||||
, LoginCookieName = None Text
|
, SessionCookieName = "sessionz"
|
||||||
|
, SessionCookieSecret = "secret"
|
||||||
}
|
}
|
||||||
|
|
||||||
let conf
|
let conf
|
||||||
@ -88,4 +90,4 @@ let _ =
|
|||||||
-- | validate the configuration.
|
-- | validate the configuration.
|
||||||
assert : Config/validate conf
|
assert : Config/validate conf
|
||||||
|
|
||||||
in nuconf
|
in conf
|
||||||
|
@ -11,6 +11,8 @@ type Config struct {
|
|||||||
AppName string
|
AppName string
|
||||||
LiveMode bool
|
LiveMode bool
|
||||||
DevelMode bool
|
DevelMode bool
|
||||||
|
SessionCookieName string
|
||||||
|
SessionCookieSecret string
|
||||||
}
|
}
|
||||||
|
|
||||||
func LoadConfig(path string) (*Config, error) {
|
func LoadConfig(path string) (*Config, error) {
|
||||||
|
Loading…
Reference in New Issue
Block a user