Skip to content

Commit f79e3a3

Browse files
committed
docs: Use kustomize overlay for Nginx GW API
There is a patch in the `base` overlay which modifies proxy_buffers to account for large headers which is common in our envioronment and ultimately results in Nginx throwing a 502 and logging an error like, "upstream sent too big header while reading response header from upstream". This update also includes the latest changes to the nginx.conf as obtained from a fresh install. Starting in v1.5.0, the SnippetsFilterAPI was added which can be used in lieu of this configuration override, though it has to be enabled manually, and more testing is needed to implement the same. Jira: OSPC-990 PR: rackerlabs#463
1 parent bd603a6 commit f79e3a3

File tree

2 files changed

+23
-4
lines changed

2 files changed

+23
-4
lines changed

base-kustomize/gateway/base/files/nginx.conf

+16
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ http {
2929
sendfile on;
3030
tcp_nopush on;
3131

32+
server_tokens off;
33+
3234
server {
3335
listen unix:/var/run/nginx/nginx-status.sock;
3436
access_log off;
@@ -38,3 +40,17 @@ http {
3840
}
3941
}
4042
}
43+
44+
stream {
45+
variables_hash_bucket_size 512;
46+
variables_hash_max_size 1024;
47+
48+
map_hash_max_size 2048;
49+
map_hash_bucket_size 256;
50+
51+
log_format stream-main '$remote_addr [$time_local] '
52+
'$protocol $status $bytes_sent $bytes_received '
53+
'$session_time "$ssl_preread_server_name"';
54+
access_log /dev/stdout stream-main;
55+
include /etc/nginx/stream-conf.d/*.conf;
56+
}

docs/infrastructure-gateway-api.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,14 @@ There are various implementations of the Gateway API. In this document, we will
8181
=== "Stable _(Recommended)_"
8282

8383
``` shell
84-
cd /opt/genestack/submodules/nginx-gateway-fabric/charts
85-
84+
pushd /opt/genestack/submodules/nginx-gateway-fabric/charts || exit 1
8685
helm upgrade --install nginx-gateway-fabric ./nginx-gateway-fabric \
87-
--namespace=nginx-gateway \
88-
-f /etc/genestack/helm-configs/nginx-gateway-fabric/helm-overrides.yaml
86+
--namespace=nginx-gateway \
87+
-f /opt/genestack/base-helm-configs/nginx-gateway-fabric/helm-overrides.yaml \
88+
-f /etc/genestack/helm-configs/nginx-gateway-fabric/helm-overrides.yaml \
89+
--post-renderer /etc/genestack/kustomize/kustomize.sh \
90+
--post-renderer-args gateway/overlay
91+
popd || exit 1
8992
```
9093

9194
=== "Experimental"

0 commit comments

Comments
 (0)