Skip to content

Instantly share code, notes, and snippets.

@InKolev
Last active March 5, 2018 13:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save InKolev/533b1586abd53b94c3b77b515bfa5593 to your computer and use it in GitHub Desktop.
Save InKolev/533b1586abd53b94c3b77b515bfa5593 to your computer and use it in GitHub Desktop.

Find largest files on disk (where size is bigger than 100MB)

sudo find / -xdev -type f -size +100M -exec du -sh {} ';' | sort -rh | head -n50

PM2 node process manager

pm2 start ecosystem.config.js

Sample ecosystem file

module.exports = {
  apps : [
    {
      name: 'StatsD',
      script: 'stats.js',
      env_production : {
        NODE_ENV: 'production'
      },
      out_file: '/dev/null',
      args: ["cloudwatchConfig.js"]
    }
  ],
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment