Support proxy app
This commit is contained in:
@@ -45,7 +45,7 @@ server {
|
||||
location / {
|
||||
<% if ( endpoint === 'dashboard' || endpoint === 'setup' ) { %>
|
||||
return 301 https://$host$request_uri;
|
||||
<% } else if ( endpoint === 'app' ) { %>
|
||||
<% } else if ( endpoint === 'app' || endpoint === 'external' ) { %>
|
||||
return 301 https://$host$request_uri;
|
||||
<% } else if ( endpoint === 'redirect' ) { %>
|
||||
return 301 https://<%= redirectTo %>$request_uri;
|
||||
@@ -175,6 +175,8 @@ server {
|
||||
proxy_pass http://127.0.0.1:3000;
|
||||
<% } else if ( endpoint === 'app' ) { %>
|
||||
proxy_pass http://<%= ip %>:<%= port %>;
|
||||
<% } else if ( endpoint === 'external' ) { %>
|
||||
proxy_pass <%= upstreamUri %>;
|
||||
<% } else if ( endpoint === 'redirect' ) { %>
|
||||
return 302 https://<%= redirectTo %>$request_uri;
|
||||
<% } %>
|
||||
@@ -326,6 +328,10 @@ server {
|
||||
# to clear a permanent redirect on the browser
|
||||
return 302 https://<%= redirectTo %>$request_uri;
|
||||
}
|
||||
<% } else if ( endpoint === 'external' ) { %>
|
||||
location / {
|
||||
proxy_pass <%= upstreamUri %>;
|
||||
}
|
||||
<% } else if ( endpoint === 'ip' ) { %>
|
||||
location /notfound.html {
|
||||
root <%= sourceDir %>/dashboard/dist;
|
||||
|
||||
Reference in New Issue
Block a user