-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart-server.sh
More file actions
executable file
·34 lines (25 loc) · 973 Bytes
/
start-server.sh
File metadata and controls
executable file
·34 lines (25 loc) · 973 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
#!/bin/bash
# FERRETCANNON Matrix Server Startup Script for macOS
# This script starts the server in the background
echo "🚀 Starting FERRETCANNON Matrix Server..."
# Kill any existing server processes
pkill -f "gradle.*run" 2>/dev/null || true
pkill -f "java.*MainKt" 2>/dev/null || true
# Wait a moment for processes to terminate
sleep 2
# Start the server in background
./gradlew run &
SERVER_PID=$!
echo "✅ Server started with PID: $SERVER_PID"
echo "🌐 Server should be available at http://localhost:8080"
echo "🛑 To stop the server, run: kill $SERVER_PID"
echo "📋 Or use: pkill -f 'gradle.*run'"
# Wait a moment for server to start
sleep 3
# Check if server is responding
if curl -s http://localhost:8080/_matrix/client/v3/login > /dev/null 2>&1; then
echo "✅ Server is responding!"
else
echo "⚠️ Server may still be starting up..."
fi
echo "🎉 Server is running in background. You can now use this terminal for other commands."