Creating new vCloud Organization users with PowerCLI

June 11, 2013

Table of Contents

Today am going to show you how to create new cloud user with powerCLI though there is no new-CLuser cmdlet so far. We require a username , password and a role, the tough part is finding a role to assign the use, this can be done by using the Search-cloud:

Search-Cloud -QueryType Role | select Name

a list of roles appear and you have to choose one for example admin.

$role = Search-Cloud -QueryType Role -Name “Organization Administrator” | Get-CIView

The query just asked for the role, then retrieved the role object using the Get-CIView and assigned it to the $role variable.

Next you get the Org object and create a new user object:

$org = Get-Org

$user = New-Object VMware.VimAutomation.Cloud.Views.User

You then assign the org object user to the user object:

$user.Name =”JakeRobinson”

$user.Password = “myPassword”

$user.Role = $role.href

$user.IsEnabled = $true

Lastly you then put the user object to the org:

$org.ExtensionData.createUser($user)

And you will be done, all you have to know is in the .extensiondata of the objects like $org.

Share on
Facebook
Twitter
LinkedIn
Pinterest
More posts

Dedicated Servers Quick Guide

What is a Dedicated Servers? Why bother using a dedicated server over a VPS or Shared Hosting?A dedicated server is a server 100% dedicated to your website/project or business needs.

cPanel 2-Factor Auth Bypass

2-Factor Authentication Bypass hole in WHM cPanel security has been Reported effected WHM resellers. cPanel, a software provider to manage web hosting/websites, has recently patched a security vulnerability that allowed

Dedicated SERVER Special
50% OFF for Life!

🔥 DELL Bare-metal Dedicated Server in New York

🔹  Intel Gold 80 Cores
🔹  23TB SSD Flash +
🔹1TB NVMe (W RAID)
🔹 1TB DDR4 RAM 
🔹 10Gbps Redundant Uplinks 
🔹 10 IPv4 + IPv6 Addresses Included 

💲 Just $699/month – 50% OFF FOR LIFE! (Reg $1399/month)
🚀 Zero Setup Costs | Flexible OS: Ubuntu, Proxmox, ESXi, Windows, etc.

✅ Reserve Risk-Free! 30-Day Money-Back Guarantee
💡 100% Uptime Assurance – Enterprise-Grade Hardware 

🖥 Ideal for Virtualization, Data-Intensive Apps, & High Traffic Sites

Use coupon code at checkout for the discount to apply FBHEO3023EJFB
⚡ Limited Availability – Don’t Miss Out!

Get 90% Discount

First 3 People gets the Bonus!
Don't Miss Out Our Big Sale

Get 0-90% On All
247Rack Services

247Rack

The Sale Is Until The End Of March