-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlaunch-panll.sh
More file actions
executable file
·37 lines (29 loc) · 890 Bytes
/
Copy pathlaunch-panll.sh
File metadata and controls
executable file
·37 lines (29 loc) · 890 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
#!/usr/bin/env bash
# PanLL Launcher - Starts the service and opens browser
set -euo pipefail
PANLL_DIR="/var/mnt/eclipse/repos/panll"
PORT=8080
URL="http://localhost:$PORT/public/"
echo "🔍 Checking if PanLL is running on port $PORT..."
if curl -sf "$URL" >/dev/null 2>&1; then
echo "✅ PanLL is already running"
else
echo "⚠️ PanLL not running. Starting it now..."
cd "$PANLL_DIR"
# Start PanLL in background
nohup just serve > /tmp/panll.log 2>&1 &
sleep 3
# Check if it started
if curl -sf "$URL" >/dev/null 2>&1; then
echo "✅ PanLL started successfully"
else
echo "❌ Failed to start PanLL. Check /tmp/panll.log"
echo "Last 10 lines of log:"
tail -10 /tmp/panll.log
exit 1
fi
fi
# Open browser
echo "🚀 Opening PanLL in browser..."
xdg-open "$URL"
echo "🎉 PanLL is ready!"