Forum Discussion
Joonas Pakkanen
Feb 12, 2018Brass Contributor
Automatically provision OneDrive for Business site for end user when adding O365 license
Hi,
Is it possible to automatically provision OneDrive for Business site for end users when adding O365 license?
I know that we can use Request-SPOPersonalSite CMDlet and PreProvision scripts, but it would be great if this can be set up more easily.
Example: User gets Office 365 license and system automatically provisions user OneDrive.
Regards, Joonas
- BenSteginkSteel Contributor
I’ve actually done this for one of my clients. When the need to add a new users, they simply put the UPN/email address in a SharePoint list along with the two character location code. Adding an item to the list, triggers some PowerShell running in Azure Automation to appropriate license the users in Office 365 as well as provision OneDrive for Business.
There are a few different ways you could trigger the PowerShell, but the end of the day, PowerShell is going to be at the heart of your solution for this.
- Aubrey MarshallBrass Contributor
Do you have more details on how this is accomplished?
- BenSteginkSteel Contributor
Aubrey Marshall, I don't have any examples or scripts that are publicly available right now. Working on a way to provide solutions like this easier and also have it on my to-do list to write a blog post that would give a little more detail on how this process might work.
I have a presentation I did recently here - https://collab365.community/hood-6-automating-sharepoint-online-powershell-azure-automation-flow/. It doesn't give the step-by-step details, but does provide some additional details into how I did it.
- Joonas PakkanenBrass Contributor
Sounds like a great workaround!
Still wishing that there could be much simpler solution for this.
Did you use some automation to get user in SharePoint list or just manually added it there?
- BenSteginkSteel Contributor
I just manually added users to the SP List. However, you could easily automate that part if you had a CSV file with all the users...or some other way you wanted to automatically add users to the list.
- Pablo R. OrtizSteel ContributorAFAIK there's no way to do that on the portal. You could combine pre-provisioning scripts with Licensing scripts. Here's a good example:
http://www.questiondriven.com/2016/01/19/office-365-license-user-and-provision-onedrive-via-powershell-scheduled-task/- Agree with Pablo here...if your problem is the use of PowerShell, then you should invest some time on checking if you can get the same with a third party tool