-
Notifications
You must be signed in to change notification settings - Fork 51
fix(gwapi): allow custom nginx.conf #463
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
3eaf352
to
ba8f482
Compare
There is no easy way to add `proxy_buffer_size` or similar parameters to Nginx via CRD. A feature for the same is being worked on and might be released early November per nginx/nginx-gateway-fabric#1398 (comment) As a workaround, this change includes the default nginx configuration as deployed in the current version of nginx gateway fabric. It will be made available to the nginx pod at `/etc/nginx/nginx.conf` by supplanting the nginx-gateway deployment with a kustomize patch that overrides `nginx.conf` via a mounted configMap volume containing said file. Several additional parameters, `proxy_buffer_size` and `proxy_buffers` are being included at this time, to account for some large header payloads being proxied from Gnocchi.
e645e9e
to
50c8d59
Compare
Still testing this in the lab, it's working as expected so far, but there are a few other things I want to check before it's ready for review. |
Deployed this to our DFW staging environment by means of a helm upgrade - this worked as expected. |
Looks good to me. |
Hey @LukeRepko, was going through some old conversations and came across this. We did implement SnippetFilters where you would be able to specify this kind of configuration (or most other NGINX customizations) in YAML. If you get a chance, we'd love to know how well it works, or if it works, for you guys! |
Thank you for the heads up @mpstefan - that's great news! I've created an internal story for our team to test and implement the same if it works as expected. Considering what we have in our backlog it will likely take a bit to implement, but I've left a note to follow-up here to let you know how it works out. Jira: OSPC-990 |
Failure to do so will result in the custom overrides for Genestack that exist in base not to get applied. There exists a modification to 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". 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
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
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: #463
There is no easy way to add
proxy_buffer_size
or similar parameters to Nginx via CRD. A feature for the same is being worked on and might be released early November per nginxinc/nginx-gateway-fabric/#1398.As a workaround, this change includes the default nginx configuration as deployed in the current version of nginx gateway fabric. It will be made available to the nginx pod at
/etc/nginx/nginx.conf
by supplanting the nginx-gateway deployment with a kustomize patch that overridesnginx.conf
via a mounted configMap volume containing said file.Several additional parameters,
proxy_buffer_size
andproxy_buffers
are being included at this time, to account for some large header payloads being proxied from Gnocchi.