Skip to content
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

feat: Allows to configure client_max_body_size #12924

Merged
merged 1 commit into from
Oct 23, 2024

Conversation

satyamsundaram
Copy link
Contributor

What this PR does / why we need it:

Adjusting client_max_body_size in Nginx allows us to fix this nginx error: client intended to send too large body.

Which issue(s) this PR fixes:
Fixes #8736, #10521

Special notes for your reviewer:

Checklist

  • Reviewed the CONTRIBUTING.md guide (required)
  • Documentation added
  • Tests updated
  • Title matches the required conventional commits format, see here
    • Note that Promtail is considered to be feature complete, and future development for logs collection will be in Grafana Alloy. As such, feat PRs are unlikely to be accepted unless a case can be made for the feature actually being a bug fix to existing behavior.
  • Changes that require user attention or interaction to upgrade are documented in docs/sources/setup/upgrade/_index.md
  • For Helm chart changes bump the Helm chart version in production/helm/loki/Chart.yaml and update production/helm/loki/CHANGELOG.md and production/helm/loki/README.md. Example PR
  • If the change is deprecating or removing a configuration option, update the deprecated-config.yaml and deleted-config.yaml files respectively in the tools/deprecated-config-checker directory. Example PR

@satyamsundaram satyamsundaram requested a review from a team as a code owner May 9, 2024 07:21
@CLAassistant
Copy link

CLAassistant commented May 9, 2024

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot added area/helm type/docs Issues related to technical documentation; the Docs Squad uses this label across many repositories labels May 9, 2024
Copy link
Collaborator

@trevorwhitney trevorwhitney left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, need to bump the version but otherwise let's get this merged!

@satyamsundaram
Copy link
Contributor Author

I've bumped the version. Let me know if there are any other changes required.

@satyamsundaram satyamsundaram changed the title feat(Helm): Allows to configure client_max_body_size feat: Allows to configure client_max_body_size May 24, 2024
@ursuciprian
Copy link

Are there any updates on the merge for this one?

@satyamsundaram satyamsundaram changed the title feat: Allows to configure client_max_body_size feat: Allows to configure client_max_body_size Sep 28, 2024
@satyamsundaram
Copy link
Contributor Author

I've fixed all merge conflicts. It can be merged now.

@jarmd
Copy link

jarmd commented Oct 22, 2024

@trevorwhitney
Can you rerun the pipeline and potentially merge this ?
This is currently a blocker for us to upgrade to loki 3.x

@trevorwhitney trevorwhitney merged commit 809a024 into grafana:main Oct 23, 2024
64 checks passed
@morganrowse
Copy link

morganrowse commented Oct 31, 2024

Hi this merge appears to be on the helm Changelog currently on main branch for the Helm 6.15.0 (release 6.18.0 is the latest current release). https://github.com/grafana/loki/blob/f5b0fb6b998dc0a49cd36c0968862340c7e517bf/production/helm/loki/CHANGELOG.md

However I'm not actually finding any chart releases >=6.15.0 that include this variable for consumption.

What is the process here for changes to chart or has this change erroneously been removed or are the changelogs incorrect?

@trevorwhitney
Copy link
Collaborator

yeah, it looks like the hem-ci is broken during the installation of the prometheus operator, which is breaking all helm releases. help in fixing it would be greatly appreciated!

@morganrowse
Copy link

Thank you, we appreciate the feedback @trevorwhitney 😃

Is there an open issue related to this to track/contribute to?

@trevorwhitney
Copy link
Collaborator

trevorwhitney commented Nov 6, 2024

@morganrowse there is now 😄 #14799

@asaf400
Copy link

asaf400 commented Nov 25, 2024

I'm still targeting Loki 2.X, so on Chart v5.44.4 which still has the config duplication issue without parameters,
I had to implement a workaround, when supplying chart values, basically inventing a new config value and using it:

gateway:
  nginxConfig:
    # Hack to allow for custom nginx config
    file: | 
      {{- tpl .Values.gateway.nginxConfig.custom_nginx_configfile_template . | indent 2 }}
    
    # Hack to allow for custom nginx config
    # Source from: https://github.com/grafana/loki/blob/helm-loki-5.44.4/production/helm/loki/templates/_helpers.tpl#L648
    custom_nginx_configfile_template: |

      # DO NOT REMOVE EMPTY NEWLINE ABOVE THIS LINE, IT WONT SHOW UP IN FINAL CONFIGMAP BUT IS REQUIRED FOR TEMPLATING
      worker_processes  5;  ## Default: 1
      <.. Rest of config here, with ability for user to modify..>

The upside is that I'm still using official chart source, and no chart modification is required, just values..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/helm size/S type/docs Issues related to technical documentation; the Docs Squad uses this label across many repositories
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error from Hardcoded "client_max_body_size" in HTTPSnippet
7 participants