app.set('port', process.env.PORT || 8081);
- From the EB App Dashboard, go to Eb Configuration -> Software Configuration.
- Under Container Options -> Node Command add "npm start", or "node ".
- The solution is to add the file .npmrc to the application with the content:
# Force npm to run node-gyp also as root, preventing permission denied errors in AWS with npm@5
unsafe-perm=true