fix: declare postgres upstream max_fails/fail_timeout directives
This commit is contained in:
parent
4e3e518936
commit
09053bf1fd
1 changed files with 4 additions and 0 deletions
|
@ -188,7 +188,11 @@ upstream {{ $upstream_name }} {
|
||||||
{{ else if $containerNetwork }}
|
{{ else if $containerNetwork }}
|
||||||
{{ $server_found = "true" }}
|
{{ $server_found = "true" }}
|
||||||
# {{ $container.Name }}
|
# {{ $container.Name }}
|
||||||
|
{{ if eq $address.Port "5432"}}
|
||||||
|
server {{ $containerNetwork.IP }}:{{ $address.Port }} max_fails=1 fail_timeout=100000000000s;
|
||||||
|
{{ else }}
|
||||||
server {{ $containerNetwork.IP }}:{{ $address.Port }};
|
server {{ $containerNetwork.IP }}:{{ $address.Port }};
|
||||||
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ else if $containerNetwork }}
|
{{ else if $containerNetwork }}
|
||||||
# {{ $container.Name }}
|
# {{ $container.Name }}
|
||||||
|
|
Loading…
Reference in a new issue