-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart.sh
More file actions
30 lines (23 loc) · 772 Bytes
/
Copy pathstart.sh
File metadata and controls
30 lines (23 loc) · 772 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
#!/bin/bash
echo "🚀 Starting Next.js Server..."
# Go to frontend folder and start the server
cd frontend/neutron-vpn || { echo "Failed to go to frontend folder"; exit 1; }
npm run start & # Run server in background
NEXT_SERVER_PID=$!
echo "✅ Next.js server started with PID $NEXT_SERVER_PID."
# Wait a few seconds for server to initialize
sleep 5
echo "⚡ Starting Electron App..."
cd ../../src
# Run AppImage from src folder
APP_IMAGE="./NeutronVPN-1.0.0.AppImage"
if [ -f "$APP_IMAGE" ]; then
chmod +x "$APP_IMAGE" || true
"$APP_IMAGE" &
ELECTRON_PID=$!
echo "✅ Electron App started with PID $ELECTRON_PID."
else
echo "❌ AppImage not found at $APP_IMAGE!"
fi
# Optionally wait for both processes
wait $NEXT_SERVER_PID $ELECTRON_PID