Skip to content

Commit

Permalink
refactor heroku build scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-north committed Feb 22, 2018
1 parent 56b9d05 commit 3bce0db
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Procfile
Original file line number Diff line number Diff line change
@@ -1 +1 @@
web: npm run bump
web: npm start
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"success_url": "/",
"image": "heroku/node",
"scripts": {
"postdeploy": "npm run build"
"postdeploy": "./scripts/heroku-postdeploy.sh"
},
"env": {
"NPM_CONFIG_PRODUCTION": {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"bump": "npm run build && npm start",
"watch": "SCRIPTY_SILENT=true scripty",
"watch:debug": "SCRIPTY_SILENT=true scripty",
"heroku-postbuild": "scripty",
"heroku-postbuild": "npm run build",
"test": "SCRIPTY_SILENT=true scripty",
"test:ex": "SCRIPTY_SILENT=true scripty",
"test:ex:watch": "SCRIPTY_SILENT=true scripty",
Expand Down
3 changes: 3 additions & 0 deletions scripts/heroku-postdeploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env sh
psql $DATABASE_URL < northwind.sql -q
npm run db:migrate:pg --- up
3 changes: 0 additions & 3 deletions scripts/heroku-setup.sh

This file was deleted.

2 changes: 1 addition & 1 deletion scripts/heroku-postbuild.sh → scripts/heroku-start.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#!/usr/bin/env sh
npm run build
npm start

0 comments on commit 3bce0db

Please sign in to comment.