Add Docker image and compose for Needle web exports

Serve production Vite dist with nginx; optional SampleScene profile.

Made-with: Cursor
This commit is contained in:
pelpanagiotis
2026-04-19 23:05:50 +03:00
parent a7c53a08a0
commit 479e9bb979
5 changed files with 102 additions and 2 deletions

20
docker/nginx-default.conf Normal file
View File

@@ -0,0 +1,20 @@
server {
listen 80;
server_name localhost;
root /usr/share/nginx/html;
index index.html;
# SPA / static Needle export
location / {
try_files $uri $uri/ /index.html;
}
# wasm / glb / long cache for hashed assets (optional)
location ~* \.(wasm|glb|png|jpg|jpeg|webp|ico|svg)$ {
try_files $uri =404;
add_header Cache-Control "public, max-age=31536000, immutable";
}
gzip on;
gzip_types text/css application/javascript application/json image/svg+xml;
}