fix heroku again

Signed-off-by: BoHong Li <raccoon@hackmd.io>
This commit is contained in:
BoHong Li 2020-03-02 22:21:01 +08:00
parent 109e751da8
commit 1cd4dce6b6
No known key found for this signature in database
GPG Key ID: 06770355DC9ECD38
1 changed files with 10 additions and 1 deletions

View File

@ -4,7 +4,16 @@ set -e
if [ ! -z "$DYNO" ]; then
# setup config files
cp .sequelizerc.example .sequelizerc
cat << EOF > .sequelizerc
const path = require('path')
const config = require('./lib/config')
module.exports = {
'migrations-path': path.resolve('lib', 'migrations'),
'models-path': path.resolve('lib', 'models'),
url: process.env['CMD_DB_URL'] || config.dbURL
}
EOF
cat << EOF > config.json