diff options
author | Tony Jiang <yujiang99@gmail.com> | 2022-08-13 06:28:16 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-13 15:28:16 +0200 |
commit | 03f19b8cd38ee0096f9a4ce47247379ed6f94cd7 (patch) | |
tree | f24918a6ee8128757e4466a42eba4ceca69ddb55 /nanobox | |
parent | 7ccf7a73f1c47a8c03712c39f7c591e837cf6d08 (diff) |
Remove nanobox (#17881)
Co-authored-by: Tony Jiang <tjiang@hippo.com>
Diffstat (limited to 'nanobox')
-rw-r--r-- | nanobox/nginx-local.conf | 92 | ||||
-rw-r--r-- | nanobox/nginx-stream.conf.erb | 66 | ||||
-rw-r--r-- | nanobox/nginx-web.conf.erb | 90 |
3 files changed, 0 insertions, 248 deletions
diff --git a/nanobox/nginx-local.conf b/nanobox/nginx-local.conf deleted file mode 100644 index 37c8a451a..000000000 --- a/nanobox/nginx-local.conf +++ /dev/null @@ -1,92 +0,0 @@ -worker_processes 1; -daemon off; - -events { - worker_connections 1024; -} - -http { - include /data/etc/nginx/mime.types; - sendfile on; - - gzip on; - gzip_disable "MSIE [1-6]\."; - gzip_vary on; - gzip_proxied any; - gzip_comp_level 6; - gzip_buffers 16 8k; - gzip_min_length 500; - gzip_http_version 1.1; - gzip_types text/plain text/xml text/javascript text/css text/comma-separated-values application/xml+rss application/xml application/x-javascript application/json application/javascript application/atom+xml; - - # Proxy upstream to the puma process - upstream rails { - server 127.0.0.1:3000; - } - - # Proxy upstream to the node process - upstream node { - server 127.0.0.1:4000; - } - - map $http_upgrade $connection_upgrade { - default upgrade; - '' close; - } - - # Configuration for Nginx - server { - # Listen on port 8080 - listen 8080; - - keepalive_timeout 70; - client_max_body_size 80M; - - root /app/public; - - add_header Strict-Transport-Security "max-age=31536000"; - - location / { - try_files $uri @rails; - } - - # Proxy connections to rails - location @rails { - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Proxy ""; - proxy_pass_header Server; - - proxy_pass http://rails; - proxy_buffering off; - proxy_redirect off; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection $connection_upgrade; - - tcp_nodelay on; - } - - # Proxy connections to node - location /api/v1/streaming { - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Proxy ""; - - proxy_pass http://node; - proxy_buffering off; - proxy_redirect off; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection $connection_upgrade; - - tcp_nodelay on; - } - } - - error_page 500 501 502 503 504 /500.html; -} diff --git a/nanobox/nginx-stream.conf.erb b/nanobox/nginx-stream.conf.erb deleted file mode 100644 index 4ea6e30fc..000000000 --- a/nanobox/nginx-stream.conf.erb +++ /dev/null @@ -1,66 +0,0 @@ -worker_processes 1; -daemon off; - -events { - worker_connections 1024; -} - -http { - include /data/etc/nginx/mime.types; - sendfile on; - - gzip on; - gzip_disable "MSIE [1-6]\."; - gzip_vary on; - gzip_proxied any; - gzip_comp_level 6; - gzip_buffers 16 8k; - gzip_min_length 500; - gzip_http_version 1.1; - gzip_types text/plain text/xml text/javascript text/css text/comma-separated-values application/xml+rss application/xml application/x-javascript application/json application/javascript application/atom+xml; - - # Proxy upstream to the node process - upstream node { - server 127.0.0.1:4000; - } - - map $http_upgrade $connection_upgrade { - default upgrade; - '' close; - } - - # Configuration for Nginx - server { - # Listen on port 8080 - listen 8080; - - keepalive_timeout 70; - client_max_body_size 80M; - - root /app/public; - - add_header Strict-Transport-Security "max-age=31536000"; - - location / { - try_files $uri @node; - } - - # Proxy connections to node - location @node { - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Proxy ""; - - proxy_pass http://node; - proxy_buffering off; - proxy_redirect off; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection $connection_upgrade; - - tcp_nodelay on; - } - } -} diff --git a/nanobox/nginx-web.conf.erb b/nanobox/nginx-web.conf.erb deleted file mode 100644 index 182d99209..000000000 --- a/nanobox/nginx-web.conf.erb +++ /dev/null @@ -1,90 +0,0 @@ -worker_processes 1; -daemon off; - -events { - worker_connections 1024; -} - -http { - include /data/etc/nginx/mime.types; - sendfile on; - - gzip on; - gzip_disable "MSIE [1-6]\."; - gzip_vary on; - gzip_proxied any; - gzip_comp_level 6; - gzip_buffers 16 8k; - gzip_min_length 500; - gzip_http_version 1.1; - gzip_types text/plain text/xml text/javascript text/css text/comma-separated-values application/xml+rss application/xml application/x-javascript application/json application/javascript application/atom+xml; - - # Proxy upstream to the puma process - upstream rails { - server 127.0.0.1:3000; - } - - map $http_upgrade $connection_upgrade { - default upgrade; - '' close; - } - - # Configuration for Nginx - server { - # Listen on port 8080 - listen 8080; - - keepalive_timeout 70; - client_max_body_size 80M; - - root /app/public; - - add_header Strict-Transport-Security "max-age=31536000"; - - location / { - try_files $uri @rails; - } - - location /sw.js { - add_header Cache-Control "public, max-age=0"; - add_header Strict-Transport-Security "max-age=31536000"; - try_files $uri @rails; - } - - location ~ ^/(emoji|packs|system/media_attachments/files|system/accounts/avatars) { - add_header Cache-Control "public, max-age=31536000, immutable"; - add_header Strict-Transport-Security "max-age=31536000"; - try_files $uri @rails; - } - - # Proxy connections to rails - location @rails { - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Proxy ""; - proxy_pass_header Server; - - proxy_pass http://rails; - proxy_buffering on; - proxy_redirect off; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection $connection_upgrade; - - proxy_cache CACHE; - proxy_cache_valid 200 7d; - proxy_cache_valid 410 24h; - proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504; - add_header Strict-Transport-Security "max-age=31536000"; - add_header X-Cached $upstream_cache_status; - - tcp_nodelay on; - } - } - - proxy_cache_path /data/var/cache/nginx levels=1:2 keys_zone=CACHE:10m inactive=7d max_size=1g; - - error_page 500 501 502 503 504 /500.html; -} |