dev #4

Merged
steinhelge merged 6 commits from dev into master 2025-11-26 09:58:26 +01:00
2 changed files with 20 additions and 0 deletions
Showing only changes of commit 68ecdb0056 - Show all commits
+3
View File
@@ -22,5 +22,8 @@ WORKDIR /usr/share/nginx/html
# Legg inn bygget frontend # Legg inn bygget frontend
COPY --from=build /app/dist . COPY --from=build /app/dist .
# Kopier custom nginx config for SPA routing
COPY nginx.conf /etc/nginx/conf.d/default.conf
# Nginx server som statisk side # Nginx server som statisk side
EXPOSE 80 EXPOSE 80
+17
View File
@@ -0,0 +1,17 @@
server {
listen 80;
server_name localhost;
root /usr/share/nginx/html;
index index.html;
# Support for SPA routing
location / {
try_files $uri $uri/ /index.html;
}
# Optional: Cache static assets
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg)$ {
expires 1y;
add_header Cache-Control "public, no-transform";
}
}