refactor: remove /goosefarm subpath from default, add goosefarminvesting.conf (SSOT)
Some checks failed
Deploy Nginx Config to Ubuntu Server / deploy (push) Has been cancelled
Some checks failed
Deploy Nginx Config to Ubuntu Server / deploy (push) Has been cancelled
- goosefarminvesting.com은 별도 도메인으로 직접 서빙 - ro-being.com/goosefarm/ 경로 제거 - base: / 빌드에 맞춘 nginx 설정
This commit is contained in:
parent
9eb7afcdb8
commit
3771ba80de
@ -69,31 +69,8 @@ server {
|
|||||||
try_files $uri /index.html;
|
try_files $uri /index.html;
|
||||||
}
|
}
|
||||||
|
|
||||||
# GooseFarm API - must come before /goosefarm for priority
|
|
||||||
location /goosefarm/api/ {
|
|
||||||
proxy_buffering on;
|
|
||||||
proxy_buffer_size 128k;
|
|
||||||
proxy_buffers 8 256k;
|
|
||||||
proxy_busy_buffers_size 512k;
|
|
||||||
proxy_read_timeout 120s;
|
|
||||||
proxy_pass http://localhost:8200/api/;
|
|
||||||
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 $scheme;
|
|
||||||
}
|
|
||||||
|
|
||||||
# GooseFarm index.html 캐시 방지 (Vite 해시 파일명 변경 시 즉시 반영)
|
|
||||||
location = /goosefarm/index.html {
|
|
||||||
alias /var/www/html/goosefarm/index.html;
|
|
||||||
add_header Cache-Control "no-store, no-cache, must-revalidate";
|
|
||||||
}
|
|
||||||
|
|
||||||
# GooseFarm Frontend
|
|
||||||
location /goosefarm {
|
|
||||||
alias /var/www/html/goosefarm/;
|
|
||||||
try_files $uri /goosefarm/index.html;
|
|
||||||
}
|
|
||||||
|
|
||||||
# IR Valuation Frontend
|
# IR Valuation Frontend
|
||||||
location /ir-valuation {
|
location /ir-valuation {
|
||||||
@ -280,31 +257,8 @@ server {
|
|||||||
try_files $uri /index.html;
|
try_files $uri /index.html;
|
||||||
}
|
}
|
||||||
|
|
||||||
# GooseFarm API - must come before /goosefarm for priority
|
|
||||||
location /goosefarm/api/ {
|
|
||||||
proxy_buffering on;
|
|
||||||
proxy_buffer_size 128k;
|
|
||||||
proxy_buffers 8 256k;
|
|
||||||
proxy_busy_buffers_size 512k;
|
|
||||||
proxy_read_timeout 120s;
|
|
||||||
proxy_pass http://localhost:8200/api/;
|
|
||||||
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 $scheme;
|
|
||||||
}
|
|
||||||
|
|
||||||
# GooseFarm index.html 캐시 방지 (Vite 해시 파일명 변경 시 즉시 반영)
|
|
||||||
location = /goosefarm/index.html {
|
|
||||||
alias /var/www/html/goosefarm/index.html;
|
|
||||||
add_header Cache-Control "no-store, no-cache, must-revalidate";
|
|
||||||
}
|
|
||||||
|
|
||||||
# GooseFarm Frontend
|
|
||||||
location /goosefarm {
|
|
||||||
alias /var/www/html/goosefarm/;
|
|
||||||
try_files $uri /goosefarm/index.html;
|
|
||||||
}
|
|
||||||
|
|
||||||
# API endpoints -> route to gateway (host 8100 -> container 8000)
|
# API endpoints -> route to gateway (host 8100 -> container 8000)
|
||||||
location /api/ {
|
location /api/ {
|
||||||
@ -432,18 +386,13 @@ server {
|
|||||||
server {
|
server {
|
||||||
listen 80;
|
listen 80;
|
||||||
listen [::]:80;
|
listen [::]:80;
|
||||||
server_name goosefarminvesting.com www.goosefarminvesting.com;
|
|
||||||
|
|
||||||
location /.well-known/acme-challenge/ {
|
location /.well-known/acme-challenge/ {
|
||||||
alias /var/www/html/.well-known/acme-challenge/;
|
alias /var/www/html/.well-known/acme-challenge/;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($host = www.goosefarminvesting.com) {
|
|
||||||
return 301 https://goosefarminvesting.com$request_uri;
|
|
||||||
}
|
|
||||||
|
|
||||||
location = / {
|
location = / {
|
||||||
return 301 https://$host/goosefarm/;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
@ -454,43 +403,16 @@ server {
|
|||||||
server {
|
server {
|
||||||
listen 443 ssl http2;
|
listen 443 ssl http2;
|
||||||
listen [::]:443 ssl http2;
|
listen [::]:443 ssl http2;
|
||||||
server_name goosefarminvesting.com www.goosefarminvesting.com;
|
|
||||||
|
|
||||||
ssl_certificate /etc/letsencrypt/live/goosefarminvesting.com/fullchain.pem;
|
|
||||||
ssl_certificate_key /etc/letsencrypt/live/goosefarminvesting.com/privkey.pem;
|
|
||||||
include /etc/letsencrypt/options-ssl-nginx.conf;
|
include /etc/letsencrypt/options-ssl-nginx.conf;
|
||||||
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
||||||
|
|
||||||
if ($host = www.goosefarminvesting.com) {
|
|
||||||
return 301 https://goosefarminvesting.com$request_uri;
|
|
||||||
}
|
|
||||||
|
|
||||||
location = / {
|
location = / {
|
||||||
return 301 https://$host/goosefarm/;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
location /goosefarm/api/ {
|
|
||||||
proxy_buffering on;
|
|
||||||
proxy_buffer_size 128k;
|
|
||||||
proxy_buffers 8 256k;
|
|
||||||
proxy_busy_buffers_size 512k;
|
|
||||||
proxy_read_timeout 120s;
|
|
||||||
proxy_pass http://localhost:8200/api/;
|
|
||||||
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 $scheme;
|
|
||||||
}
|
|
||||||
|
|
||||||
location = /goosefarm/index.html {
|
|
||||||
alias /var/www/html/goosefarm/index.html;
|
|
||||||
add_header Cache-Control "no-store, no-cache, must-revalidate";
|
|
||||||
}
|
|
||||||
|
|
||||||
location /goosefarm {
|
|
||||||
alias /var/www/html/goosefarm/;
|
|
||||||
try_files $uri /goosefarm/index.html;
|
|
||||||
}
|
|
||||||
|
|
||||||
location /.well-known/acme-challenge/ {
|
location /.well-known/acme-challenge/ {
|
||||||
alias /var/www/html/.well-known/acme-challenge/;
|
alias /var/www/html/.well-known/acme-challenge/;
|
||||||
|
|||||||
46
sites-available/goosefarminvesting.conf
Normal file
46
sites-available/goosefarminvesting.conf
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
server {
|
||||||
|
listen 443 ssl;
|
||||||
|
listen [::]:443 ssl;
|
||||||
|
server_name goosefarminvesting.com www.goosefarminvesting.com;
|
||||||
|
|
||||||
|
ssl_certificate /etc/letsencrypt/live/goosefarminvesting.com/fullchain.pem;
|
||||||
|
ssl_certificate_key /etc/letsencrypt/live/goosefarminvesting.com/privkey.pem;
|
||||||
|
include /etc/letsencrypt/options-ssl-nginx.conf;
|
||||||
|
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
||||||
|
|
||||||
|
root /var/www/html/goosefarm;
|
||||||
|
index index.html;
|
||||||
|
|
||||||
|
location /api/ {
|
||||||
|
proxy_pass http://localhost:8200/api/;
|
||||||
|
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 $scheme;
|
||||||
|
proxy_read_timeout 120s;
|
||||||
|
}
|
||||||
|
|
||||||
|
location / {
|
||||||
|
try_files $uri $uri/ /index.html;
|
||||||
|
}
|
||||||
|
|
||||||
|
location = /index.html {
|
||||||
|
add_header Cache-Control "no-store, no-cache, must-revalidate";
|
||||||
|
}
|
||||||
|
|
||||||
|
location /.well-known/acme-challenge/ {
|
||||||
|
alias /var/www/html/.well-known/acme-challenge/;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
listen [::]:80;
|
||||||
|
server_name goosefarminvesting.com www.goosefarminvesting.com;
|
||||||
|
location /.well-known/acme-challenge/ {
|
||||||
|
alias /var/www/html/.well-known/acme-challenge/;
|
||||||
|
}
|
||||||
|
location / {
|
||||||
|
return 301 https://$host$request_uri;
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user