i used yo generator to install a skeleton mean js program with a grunt build to do the minifications and deployment.
What is the steps to be taken to deploy with pm2?
Right now im using nodemon to keep my app alive and im using digitalocean console stream to run the following command:
NODE_ENV=production PORT:80 grunt --force
That does according to my gruntfile the following:
concurrent: {
default: ['nodemon', 'watch'],
options: {
logConcurrentOutput: true
}
},
....
nodemon: {
dev: {
script: 'server.js',
options: {
//nodeArgs: ['--debug'],
ext: 'js,html',
watch: watchFiles.serverViews.concat(watchFiles.serverJS)
}
}
},
grunt.registerTask('default', ['sass','lint', 'concurrent:default']);
What configuration should i add/change in my gruntfile to make all of this work with pm2? ( I need it for clustering and load-balance my app ).