Open xxxcrow opened 3 years ago
Hello @xxxcrow ,
There is no such thing in cloudflared. I would argue there is unlikely to ever be, for the reason that you mention: we already have a product that allows to do that for hostnames proxied through Cloudflare (and all Tunnel's hostnames are hosted there), so you can just leverage what already exists out of the box: https://blog.cloudflare.com/tag/transform-rules/
Is there a reason why that wouldn't work?
@nmldiegues only two rules transformation are allowed per domain on free plan 😅 And also, I was just interested, because I can't find enough information about all the ingress rules, and I though there might be some 😄
What about services that, based on some naming conventions, they need to end up in a different backend service
or maybe with a different httpHostHeader
flag set like the following (simplified) examples.
# wildcard ingress rule for all foo cpu services
- hostname: foo-*-cpu.example.com
service: http://foo-prod-*-cpu.main-foo-prod.svc.cluster.local:5000
# proxy foo gpu services through Keda-http to scale down to zero
- hostname: foo-*-gpu.example.com
originRequest:
httpHostHeader: foo-*-gpu-int.example.com
service: http://keda-add-ons-http-interceptor-proxy.keda.svc.cluster.local:8080
There may be other usecases to manipulate hostname, subdomais, paths etc.
This is currently not supported.
Is it possible to add something similar like from nginx:
I know that it's possible to transform rules in cloudflare dashboard but i want to know if there's any local cloudflared solution Or maybe headers changing?