-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart.sh
More file actions
executable file
·73 lines (60 loc) · 1.57 KB
/
start.sh
File metadata and controls
executable file
·73 lines (60 loc) · 1.57 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#!/bin/bash
# Quick Start Script for Cloud IDE
# This script sets up and starts the Cloud IDE platform
set -e
echo "🚀 Cloud IDE Quick Start"
echo "========================"
echo ""
# Check Node.js version
echo "📋 Checking prerequisites..."
if ! command -v node &> /dev/null; then
echo "❌ Node.js is not installed. Please install Node.js 18 or higher."
exit 1
fi
NODE_VERSION=$(node -v | cut -d'v' -f2 | cut -d'.' -f1)
if [ "$NODE_VERSION" -lt 18 ]; then
echo "❌ Node.js version must be 18 or higher. Current version: $(node -v)"
exit 1
fi
echo "✅ Node.js $(node -v) detected"
# Check npm
if ! command -v npm &> /dev/null; then
echo "❌ npm is not installed."
exit 1
fi
echo "✅ npm $(npm -v) detected"
echo ""
# Install dependencies
echo "📦 Installing dependencies..."
if [ ! -d "node_modules" ]; then
npm install
else
echo "✅ Dependencies already installed"
fi
echo ""
# Setup environment
echo "⚙️ Setting up environment..."
if [ ! -f ".env" ]; then
cp .env.example .env
echo "✅ Created .env file from .env.example"
else
echo "✅ .env file already exists"
fi
echo ""
# Create workspaces directory
if [ ! -d "workspaces" ]; then
mkdir -p workspaces
echo "✅ Created workspaces directory"
else
echo "✅ Workspaces directory already exists"
fi
echo ""
# Start the application
echo "🎯 Starting Cloud IDE..."
echo ""
echo "Frontend will be available at: http://localhost:3000"
echo "Backend API will be available at: http://localhost:5000"
echo ""
echo "Press Ctrl+C to stop the server"
echo ""
npm run dev