gocd-contrib / google-oauth-authorization-plugin

The plugin allows user to login in GoCD using google account
Apache License 2.0
13 stars 7 forks source link

Query regarding Authorisation #39

Open rohit4813 opened 5 years ago

rohit4813 commented 5 years ago

We are trying to provide default role for all the people trying to login via Google oauth plugin. They are getting pipeline trigger access as well.

We understand that Authorisation bit is to be done yet.

Is there any other way to achieve the same. I do not want all users who logs in with Google to have access to trigger the build.

And also curious to know what is the timeline for Authorisation bit to be done.

Thank in advance.

ankitsri11 commented 5 years ago

@rohit4813 you would need to create a role in GoCD and add users to it. Once this is done, you can assign pipeline group permissions accordingly. You can read more here

arvindsv commented 5 years ago

@ankitsri11 Since the question is about "default role" for people who're "new" (not in the users' table yet), are you saying that having a role will mean that these new/default users will automatically be provided view permission only?

ankitsri11 commented 5 years ago

@arvindsv No, it will not automatically assign the view permission. Currently, the authorization part is not supported for this plugin. Sorry, if I wasn't clear in my response. I meant to create a GoCD role (not plugin role type) and then add users who are in the user's list to the role. Once users are part of a role, pipeline group permissions can be defined accordingly.

ankitsri11 commented 5 years ago

@rohit4813 A workaround would be to have a GoCD superadmin and make him/her the pipeline group owner. Now when a new user logs in (who had never logged in before) will not see pipelines of that group.

For example, I have below two users:

  1. "goadmin" - GoCD superadmin user
  2. "user1" - normal user who has never logged in

Assigned "goadmin" as pipeline group admin.

Screenshot 2019-03-29 at 12 46 30

Now, when "user1" logs in for the first time, it won't see any pipelines from that group. Later, you can give permission accordingly.