feat: start sync-server alongside Theia
This commit is contained in:
@@ -24,7 +24,8 @@ if [ -n "$GITEA_REPO" ] && [ -n "$GITEA_TOKEN" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
git config --global credential.helper store
|
git config --global credential.helper store
|
||||||
printf "https://vibn:%s@%s\n" "$GITEA_TOKEN" "${GITEA_BASE#https://}" \
|
printf "https://vibn:%s@%s
|
||||||
|
" "$GITEA_TOKEN" "${GITEA_BASE#https://}" \
|
||||||
> /home/theia/.git-credentials 2>/dev/null || true
|
> /home/theia/.git-credentials 2>/dev/null || true
|
||||||
git config --global user.name "Vibn IDE"
|
git config --global user.name "Vibn IDE"
|
||||||
git config --global user.email "ide@vibnai.com"
|
git config --global user.email "ide@vibnai.com"
|
||||||
@@ -68,6 +69,12 @@ SETTINGS
|
|||||||
|
|
||||||
echo "[startup] Settings written to ${SETTINGS_DIR}/settings.json"
|
echo "[startup] Settings written to ${SETTINGS_DIR}/settings.json"
|
||||||
|
|
||||||
|
# ── Start sync server (agent runner calls this to trigger git pull) ───────────
|
||||||
|
if [ -f /sync-server.js ]; then
|
||||||
|
echo "[startup] Starting sync server on :3001..."
|
||||||
|
node /sync-server.js &
|
||||||
|
fi
|
||||||
|
|
||||||
# ── Start Theia ───────────────────────────────────────────────────────────────
|
# ── Start Theia ───────────────────────────────────────────────────────────────
|
||||||
echo "[startup] Starting Theia → ${OPEN_PATH}"
|
echo "[startup] Starting Theia → ${OPEN_PATH}"
|
||||||
exec node /home/theia/applications/browser/lib/backend/main.js \
|
exec node /home/theia/applications/browser/lib/backend/main.js \
|
||||||
|
|||||||
Reference in New Issue
Block a user