How to override X-Frame-Options for FrankenPHP variant #642
-
|
Hello everybody, I'm using FrankenPHP variant and would like to override the It is set in the Caddyfile to > in front of the header name. (https://caddyserver.com/docs/caddyfile/directives/header#syntax)
So my reproducer is as follow: Start container and set the header docker run --rm -it -p 8081:8080 \
-e CADDY_SERVER_EXTRA_DIRECTIVES="header >X-Frame-Options 'DENY'" \
serversideup/php:8.3.30-frankenphp-v4.3.0-beta1Request with curl to check the headers As you can see I've double checked with setting a custom header name and this is working as expected. docker run --rm -it -p 8081:8080 \
-e CADDY_SERVER_EXTRA_DIRECTIVES="header >My-Custom-Header 'Works'" \
serversideup/php:8.3.30-frankenphp-v4.3.0-beta1So what am I doing wrong? Any ideas? Thanks for your support. :) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
For us to set We could possibly add a feature where you could control this by a variableI try to keep the variables to as little as possible, but if there is a strong community support behind a feature I like to build it. You could use
|
Beta Was this translation helpful? Give feedback.
For us to set
DENYas the default will likely be too strict, but here are some ways this could happen:We could possibly add a feature where you could control this by a variable
I try to keep the variables to as little as possible, but if there is a strong community support behind a feature I like to build it.
You could use
sedto make the changeIf you are building your own image, you could just make a simple change in your Docker file:
I usually cringe in the case when people…