This commit is contained in:
Bastian Wagner
2025-04-26 18:36:33 +02:00
parent a5767a2c79
commit b965500129
5 changed files with 106 additions and 3 deletions

29
Dockerfile Normal file
View File

@@ -0,0 +1,29 @@
# ---- Build Stage ----
FROM node:18 AS builder
# Arbeitsverzeichnis im Container
WORKDIR /app
# Package-Dateien kopieren und installieren
COPY package.json package-lock.json ./
RUN npm install
# Quellcode kopieren
COPY . .
# Angular Build (Produktionsmodus)
RUN npm run build -- --configuration production
# ---- Run Stage ----
FROM nginx:stable-alpine
# Angular-Output in Nginx kopieren
COPY --from=builder /app/dist/stellar-lines/browser /usr/share/nginx/html
# Optionale eigene Nginx-Konfiguration (wenn gewünscht)
# COPY nginx.conf /etc/nginx/nginx.conf
# Exponiere Port 80
EXPOSE 80
# Start-Befehl (wird automatisch vom Nginx-Image gesetzt)