-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeploy.sh
More file actions
37 lines (32 loc) Β· 944 Bytes
/
Copy pathdeploy.sh
File metadata and controls
37 lines (32 loc) Β· 944 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
#!/bin/bash
# Quick deployment script for 9jaAgentsConnect
echo "π 9jaAgentsConnect Deployment Script"
echo "======================================"
# Kill existing servers
pkill -f "python.*http.server" 2>/dev/null
pkill -f "ssh.*serveo" 2>/dev/null
# Start local server
PORT=${1:-8765}
echo "π¦ Starting local server on port $PORT..."
cd "$(dirname "$0")"
python3 -m http.server $PORT > /tmp/server.log 2>&1 &
SERVER_PID=$!
sleep 2
# Check if server started
if ! kill -0 $SERVER_PID 2>/dev/null; then
echo "β Failed to start server"
exit 1
fi
echo "β
Server running on http://localhost:$PORT"
echo ""
echo "π To make it publicly accessible, run:"
echo " ssh -R 80:localhost:$PORT serveo.net"
echo ""
echo "π± Or deploy to Netlify:"
echo " npx netlify-cli deploy --prod --dir=."
echo ""
echo "π Or deploy to Vercel:"
echo " npx vercel --prod"
echo ""
echo "Press Ctrl+C to stop the server"
wait $SERVER_PID