Added Heroku + pg
This commit is contained in:
parent
a5ed17fa2c
commit
4f8dcae721
5 changed files with 37 additions and 2 deletions
|
@ -45,7 +45,7 @@ makeFoundation :: AppConfig DefaultEnv Extra -> IO App
|
||||||
makeFoundation conf = do
|
makeFoundation conf = do
|
||||||
manager <- newManager def
|
manager <- newManager def
|
||||||
s <- staticSite
|
s <- staticSite
|
||||||
dbconf <- withYamlEnvironment "config/sqlite.yml" (appEnv conf)
|
dbconf <- withYamlEnvironment "config/postgresql.yml" (appEnv conf)
|
||||||
Database.Persist.Store.loadConfig >>=
|
Database.Persist.Store.loadConfig >>=
|
||||||
Database.Persist.Store.applyEnv
|
Database.Persist.Store.applyEnv
|
||||||
p <- Database.Persist.Store.createPoolConfig (dbconf :: Settings.PersistConfig)
|
p <- Database.Persist.Store.createPoolConfig (dbconf :: Settings.PersistConfig)
|
||||||
|
|
1
Procfile
Normal file
1
Procfile
Normal file
|
@ -0,0 +1 @@
|
||||||
|
web: ./inmanis production -p $PORT
|
29
config/postegresql.yml
Normal file
29
config/postegresql.yml
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
Default: &defaults
|
||||||
|
user: yesod
|
||||||
|
password: abofv53.
|
||||||
|
host: localhost
|
||||||
|
port: 5432
|
||||||
|
database: inmanis
|
||||||
|
poolsize: 10
|
||||||
|
|
||||||
|
Development:
|
||||||
|
<<: *defaults
|
||||||
|
|
||||||
|
Testing:
|
||||||
|
database: inmanis_test
|
||||||
|
<<: *defaults
|
||||||
|
|
||||||
|
Staging:
|
||||||
|
database: inmanis_staging
|
||||||
|
poolsize: 100
|
||||||
|
<<: *defaults
|
||||||
|
|
||||||
|
Production:
|
||||||
|
<<: *defaults
|
||||||
|
database: ddvl03pmqsm5ls
|
||||||
|
user: bocilnfqriwudj
|
||||||
|
password: 0vGDzpcuDTsTQiGSHfm4ys8c4u
|
||||||
|
host: ec2-54-243-248-219.compute-1.amazonaws.com
|
||||||
|
port: 5432
|
||||||
|
sslmode=require
|
||||||
|
|
|
@ -67,7 +67,7 @@ library
|
||||||
, bytestring >= 0.9 && < 0.10
|
, bytestring >= 0.9 && < 0.10
|
||||||
, text >= 0.11 && < 0.12
|
, text >= 0.11 && < 0.12
|
||||||
, persistent >= 1.0 && < 1.1
|
, persistent >= 1.0 && < 1.1
|
||||||
, persistent-sqlite >= 1.0 && < 1.1
|
, persistent-postgresql >= 1.0 && < 1.1
|
||||||
, template-haskell
|
, template-haskell
|
||||||
, hamlet >= 1.1 && < 1.2
|
, hamlet >= 1.1 && < 1.2
|
||||||
, shakespeare-css >= 1.0 && < 1.1
|
, shakespeare-css >= 1.0 && < 1.1
|
||||||
|
|
5
package.json
Normal file
5
package.json
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"name" : "inmanis",
|
||||||
|
"version" : "0.0.0",
|
||||||
|
"dependencies" : {}
|
||||||
|
}
|
Loading…
Reference in a new issue