Skip to content

Commit 9a07b1f

Browse files
committed
Local deployment minor fixes
1 parent b861033 commit 9a07b1f

File tree

4 files changed

+22
-9
lines changed

4 files changed

+22
-9
lines changed

Dockerfile.local

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ FROM --platform=linux/arm64 node:18-alpine AS eval-server-builder
7070

7171
WORKDIR /workspace
7272

73-
# Copy local browser-operator-core eval server with our modifications
74-
COPY browser-operator-core/eval-server/nodejs /workspace/eval-server
73+
# Copy local eval server
74+
COPY eval-server/nodejs /workspace/eval-server
7575

7676
WORKDIR /workspace/eval-server
7777

browser-operator-core

Lines changed: 0 additions & 1 deletion
This file was deleted.

build-local.sh

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,22 @@ echo "🔨 Building extended kernel-browser with DevTools frontend..."
99
SCRIPT_DIR=$(cd "$(dirname "$0")" && pwd)
1010
cd "$SCRIPT_DIR"
1111

12+
# Fix orphaned browser-operator-core submodule if it exists
13+
if [ -d "browser-operator-core" ] && ! grep -q "browser-operator-core" .gitmodules 2>/dev/null; then
14+
echo "🔧 Fixing orphaned browser-operator-core submodule..."
15+
git rm -f browser-operator-core 2>/dev/null || true
16+
rm -rf .git/modules/browser-operator-core 2>/dev/null || true
17+
echo "✅ Removed orphaned submodule"
18+
fi
19+
1220
# Check if kernel-images submodule exists and is initialized
13-
if [ ! -d "kernel-images" ]; then
14-
echo "❌ Error: kernel-images submodule not found"
15-
echo " Run: git submodule update --init --recursive"
16-
exit 1
21+
if [ ! -d "kernel-images" ] || [ ! -f "kernel-images/images/chromium-headful/build-docker.sh" ]; then
22+
echo "📦 Initializing kernel-images submodule..."
23+
git submodule update --init --recursive
1724
fi
1825

1926
if [ ! -f "kernel-images/images/chromium-headful/build-docker.sh" ]; then
20-
echo "❌ Error: kernel-images submodule appears empty"
21-
echo " Run: git submodule update --init --recursive"
27+
echo "❌ Error: kernel-images submodule appears empty after initialization"
2228
exit 1
2329
fi
2430

run-local.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,14 @@ else
8080
exit 1
8181
fi
8282
fi
83+
84+
# Clean up Chromium lock files from previous runs to prevent profile lock errors
85+
# These files prevent concurrent access but remain after container crashes
86+
echo "🧹 Cleaning Chromium lock files from previous runs..."
87+
rm -f "$CHROMIUM_DATA_REAL/user-data/SingletonLock" \
88+
"$CHROMIUM_DATA_REAL/user-data/SingletonSocket" \
89+
"$CHROMIUM_DATA_REAL/user-data/SingletonCookie" 2>/dev/null || true
90+
8391
CHROMIUM_DATA_VOLUME="${CHROMIUM_DATA_REAL}:/data"
8492
fi
8593

0 commit comments

Comments
 (0)