- workspace-auth.ts: reemplaza isInternalOnlyHost por isDevOnlyUrl que incluye localhost/127.0.0.1 e IPs LAN además de hostnames Docker. getWorkspaceBaseUrl() y getPublicKeycloakBaseUrl() ya ignoran valores dev-only; no usan VITE_KEYCLOAK_URL=http://localhost:... en prod. - Nuevo resolveSystemBaseUrl(): cuando url.origin es localhost porque ORIGIN env var apunta a localhost en producción, busca SITE_URL/APP_URL como fallback para construir redirect_uri seguros. - buildKeycloakAuthorizationUrl() y buildKeycloakLoginUrl() usan resolveSystemBaseUrl() para el redirect_uri (evita localhost:5173). - auth/callback/+page.server.ts: idem para el redirectUri del token exchange. - auth.ts (cliente): resolveKeycloakUrl() detecta en runtime si VITE_KEYCLOAK_URL bakeado apunta a localhost pero el browser NO está en localhost → deriva la URL del hostname real del browser. - .env.example: documenta vars de producción recomendadas (SITE_URL, ORIGIN, VITE_HUB_URL) con advertencias sobre el efecto de ORIGIN. Root cause: el .env de dev (ORIGIN=http://localhost:5173, VITE_KEYCLOAK_URL=http://localhost:8085/kcauth) se usaba en producción sin sobrescribir estas variables, causando que KC generara URLs con localhost como redirect_uri y KC URL. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
sv
Everything you need to build a Svelte project, powered by sv.
Creating a project
If you're seeing this, you've probably already done this step. Congrats!
# create a new project in the current directory
npx sv create
# create a new project in my-app
npx sv create my-app
# compile paraglide
cd frontend && sudo rm -rf src/lib/paraglide && pnpm paraglide-js compile --project ./project.inlang --outdir ./src/lib/paraglide
Developing
Once you've created a project and installed dependencies with npm install (or pnpm install or yarn), start a development server:
npm run dev
# or start the server and open the app in a new browser tab
npm run dev -- --open
Building
To create a production version of your app:
npm run build
You can preview the production build with npm run preview.
To deploy your app, you may need to install an adapter for your target environment.