-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstop.sh
More file actions
executable file
·38 lines (28 loc) · 996 Bytes
/
stop.sh
File metadata and controls
executable file
·38 lines (28 loc) · 996 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/bash
# stop.sh - Stop HeyIm services (backend + frontend)
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PROJECT_ROOT="$SCRIPT_DIR"
echo "🛑 Stopping HeyIm services..."
# Stop frontend
echo "⏹ Stopping frontend..."
sudo launchctl stop com.heyim.frontend 2>/dev/null || true
sudo launchctl unload /Library/LaunchDaemons/com.heyim.frontend.plist 2>/dev/null || true
# Stop backend
echo "⏹ Stopping backend..."
sudo launchctl stop com.heyim.backend 2>/dev/null || true
sudo launchctl unload /Library/LaunchDaemons/com.heyim.backend.plist 2>/dev/null || true
sleep 2
# Kill any remaining processes
echo "🧹 Cleaning up remaining processes..."
pkill -f "HeyImServer" 2>/dev/null || true
pkill -f "next-server.*5859" 2>/dev/null || true
# Wait for ports to be released
echo "⏳ Waiting for ports to be released..."
sleep 3
# Check status
echo ""
echo "📊 Service Status:"
"$PROJECT_ROOT/status.sh" || true
echo ""
echo "✅ HeyIm stopped successfully!"