Group question

Hi All,

we manage in our Jira all the companies divisions employees. This means that when we create a new user account we add them to the divisionA and to the Employee group. In the case of a different user from Division B we add them to divisionB group and then to the Employee. This Employee group is obligatory because it serves issue security aims (other group is Customers).

Hence we have to add the users more and more groups, is there a feature which automatically add the Employee group to the user when we add them to one of the division group? Maybe a script or something.

For instance: I create a user, add the user to the DivisonB group and it will be added automatically to the Employee group.

Can you please suggest?

Note, that the nested groups is not a solution, hence it significantly slow up our application!

Thanks in advance!

Rumi

2 answers

0 votes

Some sort of service to run every few mins to synchronise the groups I guess. There is no "user added to group" event afaik that you could listen for.

It is easy to script your process using addUser and addUserToGroup using the JIRA Command Line Interface. Create a file with of all the add actions you need. Then use the run action with findReplace parameter to replace the specific user id with a script reference like @newUser@.

Hi, is there a script also for this feature?

No, you create a custom script suitable for the groups you need to deal with. Something like:

--action addUser --userId @userId@ --userFullName "@userName@" --userEmail @userEmail@
--action addUserToGroup --userId @userId@ --group Employee 
--action addUserToGroup --userId @userId@ --group @division@
...

Then you would run it when a new user was needed using something like:

--action run --file myscript.txt --findReplace "@division@:DivisionA,@userId@:newUser,@userName@:New UserName,@userEmail@:newUser@domain.com"

Hi Bob,

can this script run for instance in every 5 minutes?

I mean I would like to achieve that in the case of new user creation, I would have to add the user to only 1 specific group (division group) and then the user will be automatically add to the Employees group, Internal group and confluence group (these 3 are our standard groups to which all employees has to be added.)

Using CLI is same effort as picking these 3 groups when creating a user, or not?

Thanks!

Rumi

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 18, 2018 in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

24,345 views 2 7
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you