Skip to content

Commit

Permalink
fix: nginx
Browse files Browse the repository at this point in the history
  • Loading branch information
zdm committed Jan 2, 2024
1 parent 5691b35 commit 3dca7af
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/app/components/nginx/nginx/docker/service.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,13 @@ export default class DockerService {
if ( value === "" ) continue;

if ( name === "upstreamPort" ) {
upstreamPort = value;
}
else if ( name === "upstreamProxyProtocol" ) {
proxyOptions[name] = value;
let tags = value.split( ":" ).map( tag => tag.trim() );

upstreamPort = tags.shift();

tags = new Set( tags );

if ( tags.has( "proxy-protocol" ) ) proxyOptions.upstreamProxyProtocol = true;
}
else if ( name === "port" ) {
servers = value
Expand Down

0 comments on commit 3dca7af

Please sign in to comment.