Skip to content

Commit

Permalink
heroku
Browse files Browse the repository at this point in the history
  • Loading branch information
robertistok committed Mar 24, 2017
1 parent 4906f25 commit eed0a81
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ const mongoose = require('mongoose');
const bodyParser = require('body-parser');
const cors = require('cors');
const morgan = require('morgan');
const path = require('path');

const router = require('./api/router');

Expand All @@ -11,7 +12,7 @@ const app = express();
app.set('port', process.env.PORT || 3001);

if (process.env.NODE_ENV === 'production') {
app.use(express.static('client/build'));
app.use(express.static(path.join(__dirname, 'client/build')));
}

mongoose.Promise = global.Promise;
Expand Down
2 changes: 1 addition & 1 deletion client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"react-redux": "^5.0.3",
"react-router": "^4.0.0",
"react-router-dom": "^4.0.0",
"react-scripts": "0.9.5",
"redux": "^3.6.0",
"redux-form": "^6.5.0",
"redux-logger": "^2.10.2",
Expand All @@ -22,7 +23,6 @@
"semantic-ui": "^2.2.9"
},
"devDependencies": {
"react-scripts": "0.9.5",
"redux-immutable-state-invariant": "^2.0.0"
},
"scripts": {
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
},
"scripts": {
"server": "node server.js",
"install": "cd client && npm install && npm run build && cd ..",
"client": "node start-client.js",
"start": "concurrently \"npm run server\" \"npm run client \"",
"lint": "eslint ."
Expand Down

0 comments on commit eed0a81

Please sign in to comment.