Configuration for restricted group of users to access a specific domain in Google OAuth2-Proxy

  docker, google-oauth, oauth, oauth-2.0, swarm

I have multiple subdomains for services and only one Google Oauth service, they are running in docker swarm mode. Once a user logged into a service successfully, they can also access the other serives.

Now I want to restrict access for a group of users. For example, I have multiple groups, and, only users in group A can access the, and the same for other groups. How could I configure the restricted group in my case? I am thinking about having multiple oauth for each service but it seems to be not an efficient way.

Any helps would be highly appreciated!

Source: Docker Questions