Cleanup build & fix development default values

This commit is contained in:
Gregor Kleen 2017-12-08 14:05:05 +01:00
parent 14ccdb1e35
commit 9fca36b07f
6 changed files with 11 additions and 11 deletions

1
.dockerignore Normal file
View File

@ -0,0 +1 @@
**/*

View File

@ -13,12 +13,12 @@ approot: "_env:APPROOT:http://localhost:3000"
# Optional values with the following production defaults. # Optional values with the following production defaults.
# In development, they default to the inverse. # In development, they default to the inverse.
# #
detailed-logging: "_env:DETAILED_LOGGING:false" detailed-logging: "_env:DETAILED_LOGGING:invalid"
should-log-all: "_env:LOG_ALL:false" should-log-all: "_env:LOG_ALL:invalid"
# reload-templates: false # reload-templates: false
# mutable-static: false # mutable-static: false
# skip-combining: false # skip-combining: false
auth-dummy-login: "_env:DUMMY_LOGIN:false" auth-dummy-login: "_env:DUMMY_LOGIN:invalid"
# NB: If you need a numeric value (e.g. 123) to parse as a String, wrap it in single quotes (e.g. "_env:PGPASS:'123'") # NB: If you need a numeric value (e.g. 123) to parse as a String, wrap it in single quotes (e.g. "_env:PGPASS:'123'")
# See https://github.com/yesodweb/yesod/wiki/Configuration#parsing-numeric-values-as-strings # See https://github.com/yesodweb/yesod/wiki/Configuration#parsing-numeric-values-as-strings

View File

@ -88,17 +88,17 @@ instance FromJSON AppSettings where
( appLDAPURI, appLDAPDN, appLDAPPw, appLDAPBaseName ) ( appLDAPURI, appLDAPDN, appLDAPPw, appLDAPBaseName )
<- (=<< o .: "ldap") . withObject "LDAP" $ \obj -> (,,,) <$> obj .: "uri" <*> obj .: "dn" <*> obj .: "password" <*> obj .:? "basename" <- (=<< o .: "ldap") . withObject "LDAP" $ \obj -> (,,,) <$> obj .: "uri" <*> obj .: "dn" <*> obj .: "password" <*> obj .:? "basename"
appDetailedRequestLogging <- o .:? "detailed-logging" .!= defaultDev appDetailedRequestLogging <- (o .:? "detailed-logging" <|> pure Nothing) .!= defaultDev
appShouldLogAll <- o .:? "should-log-all" .!= defaultDev appShouldLogAll <- (o .:? "should-log-all" <|> pure Nothing) .!= defaultDev
appReloadTemplates <- o .:? "reload-templates" .!= defaultDev appReloadTemplates <- (o .:? "reload-templates" <|> pure Nothing) .!= defaultDev
appMutableStatic <- o .:? "mutable-static" .!= defaultDev appMutableStatic <- (o .:? "mutable-static" <|> pure Nothing) .!= defaultDev
appSkipCombining <- o .:? "skip-combining" .!= defaultDev appSkipCombining <- (o .:? "skip-combining" <|> pure Nothing) .!= defaultDev
appCopyright <- o .: "copyright" appCopyright <- o .: "copyright"
appAnalytics <- o .:? "analytics" appAnalytics <- o .:? "analytics"
appCryptoIDKeyFile <- o .: "cryptoid-keyfile" appCryptoIDKeyFile <- o .: "cryptoid-keyfile"
appAuthDummyLogin <- o .:? "auth-dummy-login" .!= defaultDev appAuthDummyLogin <- (o .:? "auth-dummy-login" <|> pure Nothing) .!= defaultDev
return AppSettings {..} return AppSettings {..}

View File

@ -6,6 +6,6 @@ in haskell.lib.buildStackProject {
inherit ghc; inherit ghc;
name = "stackenv"; name = "stackenv";
buildInputs = with pkgs; buildInputs = with pkgs;
[ postgresql zlib [ postgresql zlib openldap cyrus_sasl.dev
]; ];
} }

View File

@ -3,7 +3,6 @@ docker:
enable: false enable: false
image: uniworx image: uniworx
nix: nix:
enable: false
packages: [] packages: []
pure: false pure: false
shell-file: ./stack.nix shell-file: ./stack.nix