Docker deployment with external auth and group membership

I am currently testing icinga2 in a dockerized deployment, with traefik and oauth2-proxy for authentication (and backend = external for the icingaweb config ).

I am using the container.

For the user, icingaweb relies on the the ‘REMOTE_USER’ environment variable to get the username, which i inject from the proxy as X-USERNAMEand adding


as apache config to the icingaweb container.

Which seem to work pretty well.

But now i need a way to dynamically add the user groups, is there any way to map an HTTP_Header to groups?