Configure dynamic group memberships

In the next section, we will configure straightforward dynamic group memberships to use the department attribute to add users to their department group and build up a dynamic licensing assignment. Group-based licensing currently does not support groups that contain other groups (nested groups).

An Azure AD Premium P1 license is needed for every user in a dynamic group.
When enabling dynamic groups, current memberships will be lost.
The usage location of a user needs to be set to assign a license. 

As the admin@domain.onmicrosoft.com, choose the Accounting group, navigate to properties, and change the membership type to Dynamic User.

Create a simple rule, department Equals (-eq) Accounting:

Dynamic group membership rule configuration

Set the department attribute (profile section) on the accounting users Brian Cox and Jeff Simpson to Accounting:

Filling user attributes for dynamic group usage

The member should be added automatically. Check the group membership and verify the two new members:

Freshly calculated dynamic group membership

Next, we will provide an automatic licensing solution.

Create the following security group:

  • Office 365 full feature licensing
  • Group descriptionAutomatic Office 365 Full Feature Licensing
  • Membership type: Dynamic User
  • Dynamic query: userType -eq Member:
Group properties dialog

Under Licenses | Products, assign the Office 365 E5 plan. Don't choose any assignment options at the moment:

Group assignment options
Note: With the assignment options, you can enable/disable features as needed.

Wait until the membership has updated and check the license assignment for Don.Hall@domain.onmicrosoft.com.

You will see that the user gets the license through a direct and group-based assignment:

License assignment overview
This lice nse solution is to give you a starter. You shoul d remove the directly assigned licenses from all users that get licenses from group membership.

In the next section, we will configure role assignments to administrative units.