Skip to content

Support for "Virtual host" used by Kubernetes Ingress #159

@pawelbolonek

Description

@pawelbolonek

Currently client pases original "Host" header coming from request. This way kubernetes ingress can't dispatch call to respective service.

Host header should come from target hostname and original Host could be placed in x-forwarded-host header as proxy usually do.

Suggested solution:

L50:
Object.keys(data).forEach(key => {
req.set(key, data[key])
if(key.toUpperCase() === 'HOST'){
req.set(key, target.host);
req.set('x-forwarded-host', data[key]);
}
})

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions