diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..46cdb57 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,12 @@ +FROM nginx:alpine + +# Copy build files +COPY packages/apps/build /usr/share/nginx/html + +# Copy nginx config +COPY nginx.conf /etc/nginx/conf.d/default.conf + +# Expose port +EXPOSE 80 + +CMD ["nginx", "-g", "daemon off;"] diff --git a/nginx.conf b/nginx.conf new file mode 100644 index 0000000..57ebe37 --- /dev/null +++ b/nginx.conf @@ -0,0 +1,29 @@ +server { + listen 80; + server_name localhost; + root /usr/share/nginx/html; + index index.html; + + # Gzip compression + gzip on; + gzip_vary on; + gzip_min_length 1024; + gzip_proxied expired no-cache no-store private auth; + gzip_types text/plain text/css text/xml text/javascript application/x-javascript application/xml application/javascript application/json; + + # Cache static assets + location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2|ttf|eot)$ { + expires 1y; + add_header Cache-Control "public, immutable"; + } + + # SPA fallback - serve index.html for all routes + location / { + try_files $uri $uri/ /index.html; + } + + # 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; +} diff --git a/package.json b/package.json index e5c6ab1..7813693 100644 --- a/package.json +++ b/package.json @@ -111,7 +111,7 @@ "@pezkuwi/types-create": "^16.5.6", "@pezkuwi/types-known": "^16.5.8", "@pezkuwi/types-support": "^16.5.6", - "@pezkuwi/ui-settings": "^3.16.9", + "@pezkuwi/ui-settings": "^3.17.1", "@pezkuwi/util": "^14.0.7", "@pezkuwi/util-crypto": "^14.0.7", "@pezkuwi/wasm-crypto": "^7.5.4", diff --git a/packages/apps-config/package.json b/packages/apps-config/package.json index 0f108a9..b6df329 100644 --- a/packages/apps-config/package.json +++ b/packages/apps-config/package.json @@ -41,7 +41,7 @@ "@pezkuwi/api": "^16.5.6", "@pezkuwi/api-derive": "^16.5.6", "@pezkuwi/networks": "^14.0.7", - "@pezkuwi/react-identicon": "^3.16.3", + "@pezkuwi/react-identicon": "^3.17.1", "@pezkuwi/types": "^16.5.6", "@pezkuwi/types-codec": "^16.5.6", "@pezkuwi/util": "^14.0.7", diff --git a/packages/react-components/package.json b/packages/react-components/package.json index 3423a0d..d073651 100644 --- a/packages/react-components/package.json +++ b/packages/react-components/package.json @@ -21,11 +21,11 @@ "@fortawesome/react-fontawesome": "^0.2.0", "@pezkuwi/keyring": "^14.0.7", "@pezkuwi/react-api": "^0.168.2-4-x", - "@pezkuwi/react-identicon": "^3.16.3", - "@pezkuwi/react-qr": "^3.16.3", + "@pezkuwi/react-identicon": "^3.17.1", + "@pezkuwi/react-qr": "^3.17.1", "@pezkuwi/react-query": "^0.168.2-4-x", - "@pezkuwi/ui-keyring": "^3.16.3", - "@pezkuwi/ui-settings": "^3.16.3", + "@pezkuwi/ui-keyring": "^3.17.1", + "@pezkuwi/ui-settings": "^3.17.1", "@pezkuwi/util": "^14.0.7", "@pezkuwi/util-crypto": "^14.0.7", "chart.js": "^4.4.1",