Files
Hitonabi f2da1ad525 UI: echter Build hinter nginx, relative API-Pfade, Logs-Seite ehrlich
Vorher lief der Vite-ENTWICKLUNGSSERVER als Produktion, und vier Dateien
riefen hartkodiert http://localhost:8000 auf — vom PC aus fragte der Browser
damit den PC selbst nach Laufwerken (deshalb blieb das UI immer leer);
Settings nutzte ein nie gesetztes VITE_API_URL. Die Logs-Seite zeigte fest
einprogrammierte Fantasie-Einträge ("The Matrix gerippt").

- lib/api.ts: axios-Instanz mit baseURL /api; nginx proxied /api → api:8000
  (ein Origin, kein CORS), SSE-tauglich (proxy_buffering off)
- Dockerfile: Vite-Build → nginx:alpine statt npm run dev
- Logs + LiveLog von echtem /logs-Endpoint; MetadataPreview: echte Laufwerke
  aus /devices statt erfundener /dev/bluray-Optionen, startet echten Job

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-23 15:02:39 +02:00

22 lines
523 B
Docker

# UI-Image: Vite-Build → statisch via nginx (KONZEPT-konform).
# Vorher lief hier `npm run dev` — der Vite-ENTWICKLUNGSSERVER — als
# "Produktion". Jetzt: echter Build, nginx liefert aus und proxied /api.
FROM node:22-alpine AS build
WORKDIR /app
COPY docker/ui/package.json docker/ui/package-lock.json ./
RUN npm ci --no-audit --no-fund
COPY docker/ui/ .
RUN npm run build
FROM nginx:alpine
COPY docker/ui/nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=build /app/dist /usr/share/nginx/html
EXPOSE 80