diff options
author | William Carroll <wpcarro@gmail.com> | 2020-07-31T17·26+0100 |
---|---|---|
committer | William Carroll <wpcarro@gmail.com> | 2020-07-31T17·28+0100 |
commit | c8ed6e51fea30ea2f79cca058c4f161625ab6a85 (patch) | |
tree | d49ee9bd7b1b5b5754c84b80f474f69891549f2f /src/Types.hs | |
parent | 1d7c77f51d287c9d636630142791952890d17622 (diff) |
Read CLIENT and SERVER endpoints from .envrc
In the spirit of DRY.
Diffstat (limited to 'src/Types.hs')
-rw-r--r-- | src/Types.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Types.hs b/src/Types.hs index 7bfdf6cfd000..f47e1419757a 100644 --- a/src/Types.hs +++ b/src/Types.hs @@ -33,12 +33,16 @@ import qualified Data.UUID as UUID data Config = Config { mailgunAPIKey :: Text , dbFile :: FilePath + , configClient :: Text + , configServer :: Text } deriving (Eq, Show) instance FromEnv Config where fromEnv _ = do mailgunAPIKey <- env "MAILGUN_API_KEY" dbFile <- env "DB_FILE" + configClient <- env "CLIENT" + configServer <- env "SERVER" pure Config {..} -- TODO(wpcarro): Properly handle NULL for columns like profilePicture. |