module.exports = {
  apps: [{
    name: 'telegram-bot',
    script: 'bot.js',
    instances: 1,
    autorestart: true,
    watch: false,
    max_memory_restart: '500M',
    env: {
      NODE_ENV: 'production'
    },
    error_file: './logs/err.log',
    out_file: './logs/out.log',
    log_date_format: 'YYYY-MM-DD HH:mm:ss Z',
    merge_logs: true,
    // Restart در صورت crash
    min_uptime: '10s',
    max_restarts: 10,
    restart_delay: 4000
  }]
};

