Merge pull request #3409 from Shopify/client-max-body-size

Convert isValidClientBodyBufferSize to something more generic
This commit is contained in:
k8s-ci-robot 2018-11-13 08:36:06 -08:00 committed by GitHub
commit a22c656f30
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 20 additions and 15 deletions

View file

@ -874,8 +874,10 @@ stream {
proxy_http_version 1.1;
proxy_ssl_server_name on;
proxy_pass_request_headers on;
{{ if isValidByteSize $location.Proxy.BodySize }}
client_max_body_size {{ $location.Proxy.BodySize }};
{{ if isValidClientBodyBufferSize $location.ClientBodyBufferSize }}
{{ end }}
{{ if isValidByteSize $location.ClientBodyBufferSize }}
client_body_buffer_size {{ $location.ClientBodyBufferSize }};
{{ end }}
@ -1084,8 +1086,10 @@ stream {
}
{{ end }}
{{ if isValidByteSize $location.Proxy.BodySize }}
client_max_body_size {{ $location.Proxy.BodySize }};
{{ if isValidClientBodyBufferSize $location.ClientBodyBufferSize }}
{{ end }}
{{ if isValidByteSize $location.ClientBodyBufferSize }}
client_body_buffer_size {{ $location.ClientBodyBufferSize }};
{{ end }}