Deployment improvements: - Add template env files (.envs.example/) for documentation - Create init-production.sh for one-time server setup - Create build-activepieces.sh for building/deploying AP image - Update deploy.sh with --deploy-ap flag - Make custom-pieces-metadata.sql idempotent - Update DEPLOYMENT.md with comprehensive instructions Frontend: - Redirect logged-in business owners from root domain to tenant dashboard - Redirect logged-in users from /login to /dashboard on their tenant - Log out customers on wrong subdomain instead of redirecting 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
62 lines
1.8 KiB
Plaintext
62 lines
1.8 KiB
Plaintext
events{}
|
|
http {
|
|
include /etc/nginx/mime.types;
|
|
client_max_body_size 100m;
|
|
|
|
server_tokens off;
|
|
ssl_protocols TLSv1.2 TLSv1.3;
|
|
|
|
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" always;
|
|
add_header X-Content-Type-Options "nosniff" always;
|
|
|
|
server {
|
|
listen 80;
|
|
server_name localhost;
|
|
root /usr/share/nginx/html;
|
|
index index.html;
|
|
|
|
error_page 404 /404.html;
|
|
location = /404.html {
|
|
root /usr/share/nginx/html;
|
|
try_files $uri $uri/ /index.html;
|
|
}
|
|
|
|
location /socket.io {
|
|
proxy_pass http://localhost:3000/socket.io;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "Upgrade";
|
|
proxy_set_header Host $host;
|
|
proxy_read_timeout 900s;
|
|
proxy_send_timeout 900s;
|
|
}
|
|
|
|
location ~* ^/(?!api/).*\.(css|js|jpg|jpeg|png|gif|ico|svg|woff|woff2|ttf|eot)$ {
|
|
root /usr/share/nginx/html;
|
|
add_header Expires "0";
|
|
add_header Cache-Control "public, max-age=31536000, immutable";
|
|
}
|
|
|
|
# Use the default language for the root of the application
|
|
location / {
|
|
root /usr/share/nginx/html;
|
|
try_files $uri $uri/ /index.html?$args;
|
|
add_header Cache-Control "public, max-age=120";
|
|
}
|
|
|
|
location /api/ {
|
|
proxy_pass http://localhost:3000/;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "Upgrade";
|
|
proxy_set_header Host $host;
|
|
proxy_read_timeout 900s;
|
|
proxy_send_timeout 900s;
|
|
|
|
# SSE specific settings
|
|
proxy_buffering off;
|
|
proxy_cache off;
|
|
}
|
|
}
|
|
}
|