Files
tilbudgivern/archive/scripts/start-with-pm2.sh
T
2025-10-30 18:28:58 +00:00

23 lines
766 B
Bash
Executable File

#!/bin/bash
# Start services with PM2 using correct node path
export NODE_PATH="/home/alex/.vscode-server/cli/servers/Stable-7d842fb85a0275a4a8e4d7e040d2625abbf7f084/server/node"
export PATH="/home/alex/.vscode-server/cli/servers/Stable-7d842fb85a0275a4a8e4d7e040d2625abbf7f084/server:$PATH"
cd /mnt/HC_Volume_103713257/tilbudgivern
echo "🚀 Starting Tilbudgivern services with PM2..."
# Stop any existing PM2 processes
/usr/local/bin/pm2 delete all 2>/dev/null
# Start with ecosystem config
$NODE_PATH /usr/local/bin/pm2 start ecosystem.config.json
echo ""
echo "✅ Services started!"
echo ""
echo "📊 Monitor: $NODE_PATH /usr/local/bin/pm2 monit"
echo "📋 Logs: $NODE_PATH /usr/local/bin/pm2 logs"
echo "📜 List: $NODE_PATH /usr/local/bin/pm2 list"