Stirling-PDF icon indicating copy to clipboard operation
Stirling-PDF copied to clipboard

Enlarging max-http-header-size

Open helgisid opened this issue 1 year ago • 10 comments

Is there any way to set custom max-http-header-size value? Maybe I can set it using setting.yml somehow?

image

helgisid avatar Jan 11 '24 13:01 helgisid

Out of curiosity what size are you loading?

Frooodle avatar Jan 11 '24 14:01 Frooodle

Out of curiosity what size are you loading?

Keycloak returns cookie up to 6 mb, I can't make it smaller

helgisid avatar Jan 11 '24 14:01 helgisid

yeah just add this in settings.yml

server:
  max-http-header-size: 10MB 

Frooodle avatar Jan 11 '24 14:01 Frooodle

yeah just add this in settings.yml

server:
  max-http-header-size: 10MB 

I can make another .yml file with these lines and it will be merged with the main one, right?

helgisid avatar Jan 11 '24 14:01 helgisid

No please add to same configs/settings.yml

Frooodle avatar Jan 11 '24 15:01 Frooodle

max-http-header-size: 10MB 

I work in k8s and get Read-only file system exception, how can I overcome this?

 volumeMounts:
         - name: settings
            mountPath: /configs/settings.yml
            subPath: settings.yml

helgisid avatar Jan 11 '24 15:01 helgisid

Google says

volumeMounts:
  - name: settings
    mountPath: /configs/settings.yml
    subPath: settings.yml
    readOnly: false  # Make sure this is set to false

Frooodle avatar Jan 11 '24 15:01 Frooodle

still get "Request header is too large" error... any other thoughts about what could be wrong?

helgisid avatar Jan 11 '24 15:01 helgisid

After restart of app?

Frooodle avatar Jan 11 '24 15:01 Frooodle

After restart of app?

yes, after redeploying the chart I use the app in

helgisid avatar Jan 11 '24 16:01 helgisid

This code works properly:

server:
    max-http-request-header-size: 12KB

helgisid avatar Jan 12 '24 10:01 helgisid

This code works properly:

server:
    max-http-request-header-size: 12KB

Interesting why does that work if you said header can be 6mb?

Frooodle avatar Jan 12 '24 10:01 Frooodle

This code works properly:

server:
    max-http-request-header-size: 12KB

Interesting why does that work if you said header can be 6mb?

the value is not the case, but the syntax also cookies are 6KB, not MB, my fault hahah

helgisid avatar Jan 12 '24 10:01 helgisid