How to remove cookie before proxying to upstream service

The Traefik is serving example.com. This serve multiple services behind the oauth2_proxy forward auth

For ex:

example.com/a
example.com/b
example.com/c

traefik-remove-cookie-upstream

After successful authentication, oauth2_proxy set cookie named "_oauth2_proxy". This cookie is passed to all the services. This creates some side-effect.

I want to remove the particular cookie only before proxying to upstream service in Traefik. How to do that?

traefik-remove-cookie-upstream1

Have you tried to use a middleware for http headers and just set the cookie to empty?

Yes. I tried. It removes all the cookie.

There is no way to remove a particular cookie.

Hello @arulrajnet did you find the way?

Maybe check Traefik plugins, like cookie-filter.