Rip out Theia, ship P5.1 attach E2E + Justine UI work-in-progress
Theia rip-out: - Delete app/api/theia-auth/route.ts (Traefik ForwardAuth shim) - Delete app/api/projects/[projectId]/workspace/route.ts and app/api/projects/prewarm/route.ts (Cloud Run Theia provisioning) - Delete lib/cloud-run-workspace.ts and lib/coolify-workspace.ts - Strip provisionTheiaWorkspace + theiaWorkspaceUrl/theiaAppUuid/ theiaError from app/api/projects/create/route.ts response - Remove Theia callbackUrl branch in app/auth/page.tsx - Drop "Open in Theia" button + xterm/Theia PTY copy in build/page.tsx - Drop theiaWorkspaceUrl from deployment/page.tsx Project type - Strip Theia IDE line + theia-code-os from advisor + agent-chat context strings - Scrub Theia mention from lib/auth/workspace-auth.ts comment P5.1 (custom apex domains + DNS): - lib/coolify.ts + lib/opensrs.ts: nameserver normalization, OpenSRS XML auth, Cloud DNS plumbing - scripts/smoke-attach-e2e.ts: full prod GCP + sandbox OpenSRS + prod Coolify smoke covering register/zone/A/NS/PATCH/cleanup In-progress (Justine onboarding/build, MVP setup, agent telemetry): - New (justine)/stories, project (home) layouts, mvp-setup, run, tasks routes + supporting components - Project shell + sidebar + nav refactor for the Stackless palette - Agent session API hardening (sessions, events, stream, approve, retry, stop) + atlas-chat, advisor, design-surfaces refresh - New scripts/sync-db-url-from-coolify.mjs + scripts/prisma-db-push.mjs + docker-compose.local-db.yml for local Prisma workflows - lib/dev-bypass.ts, lib/chat-context-refs.ts, lib/prd-sections.ts - Misc: stories CSS, debug/prisma route, modal-theme, BuildLivePlanPanel Made-with: Cursor
This commit is contained in:
@@ -5,7 +5,6 @@ import { randomUUID } from 'crypto';
|
||||
import { createRepo, createWebhook, getRepo, listWebhooks, GITEA_ADMIN_USER_EXPORT } from '@/lib/gitea';
|
||||
import { pushTurborepoScaffold } from '@/lib/scaffold';
|
||||
import { createMonorepoAppService } from '@/lib/coolify';
|
||||
import { provisionTheiaWorkspace } from '@/lib/cloud-run-workspace';
|
||||
import { getOrCreateProvisionedWorkspace } from '@/lib/workspaces';
|
||||
import type { ProjectPhaseData, ProjectPhaseScores } from '@/lib/types/project-artifacts';
|
||||
|
||||
@@ -208,24 +207,7 @@ export async function POST(request: Request) {
|
||||
}
|
||||
|
||||
// ──────────────────────────────────────────────
|
||||
// 3. Provision dedicated Theia workspace
|
||||
// ──────────────────────────────────────────────
|
||||
let theiaWorkspaceUrl: string | null = null;
|
||||
let theiaAppUuid: string | null = null;
|
||||
let theiaError: string | null = null;
|
||||
|
||||
try {
|
||||
const workspace = await provisionTheiaWorkspace(slug, projectId, giteaRepo);
|
||||
theiaWorkspaceUrl = workspace.serviceUrl;
|
||||
theiaAppUuid = workspace.serviceName;
|
||||
console.log(`[API] Theia workspace provisioned: ${theiaWorkspaceUrl}`);
|
||||
} catch (err) {
|
||||
theiaError = err instanceof Error ? err.message : String(err);
|
||||
console.error('[API] Theia workspace provisioning failed (non-fatal):', theiaError);
|
||||
}
|
||||
|
||||
// ──────────────────────────────────────────────
|
||||
// 4. Save project record
|
||||
// 3. Save project record
|
||||
// ──────────────────────────────────────────────
|
||||
const projectData = {
|
||||
id: projectId,
|
||||
@@ -262,10 +244,6 @@ export async function POST(request: Request) {
|
||||
giteaSshUrl,
|
||||
giteaWebhookId,
|
||||
giteaError,
|
||||
// Theia workspace
|
||||
theiaWorkspaceUrl,
|
||||
theiaAppUuid,
|
||||
theiaError,
|
||||
// Context snapshot (kept fresh by webhooks)
|
||||
contextSnapshot: null,
|
||||
// Coolify project — one per VIBN project, scopes all app services + DBs
|
||||
@@ -344,8 +322,6 @@ export async function POST(request: Request) {
|
||||
? { repo: giteaRepo, repoUrl: giteaRepoUrl, cloneUrl: giteaCloneUrl, sshUrl: giteaSshUrl }
|
||||
: null,
|
||||
giteaError: giteaError ?? undefined,
|
||||
theiaWorkspaceUrl,
|
||||
theiaError: theiaError ?? undefined,
|
||||
isImport: !!githubRepoUrl,
|
||||
analysisJobId: analysisJobId ?? undefined,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user