Quantcast
Channel: VMware Communities : Discussion List - vRealize Orchestrator
Viewing all articles
Browse latest Browse all 6251

how to get current username when running a workflow ?

$
0
0

Here is what I would like to do:

 

Say each user is allowed to have 4 QA instances, create a workflow, when a user run it from vCenter plugin, it should be able to get the user's SSO username jsmith, then it will query if there is a existing VM jsmith_qa1,jsmith_qa2,jsmith_qa4, etc, if there isn't one, then create one for him; otherwise tell the user he already has 4 instances.

 

I found I can use getCurrentLdapUser to do get jsmith@domain.name , now I want to remove the domain.name ( there are mulitple domains ) :

 

 

username = actionResult.userPrincipalName.replace("@[a-z.]+","");

 

This doesn't seem work. Does anyone know where I can find good document for vRealize Orchestrator scripting document?

 

Thanks!

 

Jack


Viewing all articles
Browse latest Browse all 6251

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>