Initial Astro website with Tailwind
- Homepage mit Hero, Stats, Features, Pricing, Industries, Waitlist - 5 Branchenseiten (Großhandel, Handwerk, Steuerberater, Inkasso, Lieferanten) - Tailwind CSS mit Brand-Colors (Navy + Signal-Red) - Docker-Build für Coolify Deployment - Component-basierte Architektur
This commit is contained in:
46
Dockerfile
Normal file
46
Dockerfile
Normal file
@@ -0,0 +1,46 @@
|
||||
# Build Stage
|
||||
FROM node:22-alpine AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Dependencies
|
||||
COPY package*.json ./
|
||||
RUN npm ci
|
||||
|
||||
# Source
|
||||
COPY . .
|
||||
|
||||
# Build
|
||||
RUN npm run build
|
||||
|
||||
# Production Stage
|
||||
FROM nginx:alpine
|
||||
|
||||
# Copy built files
|
||||
COPY --from=builder /app/dist /usr/share/nginx/html
|
||||
|
||||
# Nginx config for SPA routing
|
||||
RUN echo 'server { \
|
||||
listen 80; \
|
||||
root /usr/share/nginx/html; \
|
||||
index index.html; \
|
||||
\
|
||||
location / { \
|
||||
try_files $uri $uri/ $uri.html /index.html; \
|
||||
} \
|
||||
\
|
||||
# Cache static assets \
|
||||
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2)$ { \
|
||||
expires 1y; \
|
||||
add_header Cache-Control "public, immutable"; \
|
||||
} \
|
||||
\
|
||||
# Security headers \
|
||||
add_header X-Frame-Options "SAMEORIGIN" always; \
|
||||
add_header X-Content-Type-Options "nosniff" always; \
|
||||
add_header X-XSS-Protection "1; mode=block" always; \
|
||||
}' > /etc/nginx/conf.d/default.conf
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
Reference in New Issue
Block a user