-
Notifications
You must be signed in to change notification settings - Fork 264
Expand file tree
/
Copy pathpost-create.sh
More file actions
executable file
·49 lines (42 loc) · 1.27 KB
/
post-create.sh
File metadata and controls
executable file
·49 lines (42 loc) · 1.27 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
#!/bin/bash
# post-create.sh - One-time setup after container creation
set -e
echo "=========================================="
echo "Sourcebot Dev Container: Post-Create Setup"
echo "=========================================="
cd /workspaces/sourcebot
# 1. Initialize git submodules (in case initializeCommand didn't run)
echo ""
echo "[1/4] Initializing git submodules..."
git submodule update --init --recursive
# 2. Build Zoekt and install dependencies (uses Makefile)
echo ""
echo "[2/4] Building Zoekt and installing dependencies..."
make
echo ""
echo "[3/4] Running database migrations..."
yarn dev:prisma:migrate:dev
echo ""
echo "[4/4] Creating default config.json..."
cat > config.json << 'EOF'
{
"$schema": "https://raw.githubusercontent.com/sourcebot-dev/sourcebot/main/schemas/v3/index.json",
"connections": {
"github": {
"type": "github",
"repos": ["sourcebot-dev/sourcebot"]
}
}
}
EOF
echo ""
echo "=========================================="
echo "Post-create setup complete!"
echo ""
echo "To start the development server, run:"
echo " yarn dev"
echo ""
echo "Services will be available at:"
echo " - Web App: http://localhost:3000"
echo " - Zoekt: http://localhost:6070"
echo "=========================================="