Create idle.sh

This commit is contained in:
pancakes-proxy 2025-03-11 07:22:18 -04:00 committed by GitHub
parent cb1885c2d2
commit 169c064f21
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

12
idle.sh Normal file
View File

@ -0,0 +1,12 @@
#!/bin/bash
# Kill any currently running Node.js processes
echo "Stopping any running Node.js processes..."
pkill -f "node server.js"
# Wait for a moment to ensure the process is stopped
sleep 2
# Restart the Node.js server
echo "Restarting the server..."
node server.js &