mirror of
https://github.com/OneUptime/oneuptime
synced 2024-11-21 22:59:07 +00:00
fix nginx marketing page issue for on-prem isntall.
This commit is contained in:
parent
a474af6c0f
commit
97fad39d27
@ -167,7 +167,10 @@ server {
|
||||
fastcgi_buffers 16 16k;
|
||||
fastcgi_buffer_size 32k;
|
||||
|
||||
set $billing_enabled ${BILLING_ENABLED};
|
||||
|
||||
location / {
|
||||
|
||||
proxy_set_header Host $server_name;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
@ -177,9 +180,18 @@ server {
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_pass http://home;
|
||||
|
||||
# If billing_enabled is true then proxy to home otherwise to dashboard because we dont need marketing paages for on-prem install.
|
||||
if ($billing_enabled = true) {
|
||||
proxy_pass http://home;
|
||||
}
|
||||
|
||||
if ($billing_enabled != true) {
|
||||
proxy_pass http://dashboard;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
location /accounts {
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
|
Loading…
Reference in New Issue
Block a user