WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Hardware Options
    • Hardware Reviews
    • Lab Deployment Scripts
    • Nested Virtualization
    • Homelab Podcasts
  • VMware Nostalgia
  • Apple

Introducing Alexa to a few more VMware APIs

06.12.2017 by William Lam // 3 Comments

Over the weekend, while taking a break from putting together some furniture as it was my time for my daughters nap, I got that the chance to explore and create a new Alexa Skill which integrates with a few of VMware's APIs. This has been something I wanted to try out for some time but have not had any spare time. I had even purchased an Amazon Echo Dot but its just currently being used as a music player for the family. A couple of weeks back I saw an awesome blog post from Cody De Arkland where he demonstrates how to easily integrate the new vCenter Server 6.5 REST APIs into an Alexa Skill which can then be consumed using an Amazon Echo device.

Cody's write-up was fantastic and I was able to get everything up and running in about 20-25minutes with a few minor trial/error. It was great to see how easy it was for a non-developer like Cody to easily consume the new vCenter Server REST APIs which includes basic VM Management as well access to the VMware Management Appliance Interface or VAMI for short. Given Cody already did the hard work to create the initial Alexa integration, I figure it might be cool to extend his work and introduce Alexa to a few more VMware's APIs including the traditional vSphere API (SOAP) and the new vSAN Management API.

UPDATE (06/15/17) - Just added support for PowerCLI, it was a little tricky as Flask app is written in Python and so poor man workaround was to call Powershell/PowerCLI using subprocess.

Since Cody's integration module was written using Python, it was pretty simple to add support for both pyvmomi (vSphere SDK for Python) and vSAN Management SDK. To install pyvmomi, you can simply run

pip3 install pyvmomi

and for installing vSAN Management SDK, have a look at this blog post here.

Here is a quick video that I had recorded which demonstrates the use of both the vSphere API and vSAN Management API using my Amazon Echo.

You can find all my changes in this forked repo lamw/alexavsphereskill and make sure to follow Cody's blog post here for instructions on how to get setup. For those wondering if Cody will be publishing an Alexa Skill for general consumption, I know he is working on some awesome updates to make it even easier to consume. Here is a sneak peak at just some of the recent updates that Cody is working on ...

A little @VMwareClarity UI action going on with the @amazonecho & @VMware skill this weekend in the lab. So easy to work with! @vmwarecode pic.twitter.com/0iXMbU6Acz

— Cody De Arkland (@Codydearkland) June 12, 2017

Stay tuned on this blog and Github repo for future updates!

One thing to note which I was not aware of until Cody mentioned it, is that once your Alexa Skill is built, you can directly access it from your own personal Amazon Echo without needing to publish it. You need to activate the Alexa Skill by saying "Alexa Start [APP-NAME]" where name is the name used in the "Invocation Name" field as shown in the screenshot below when setting up your Alexa Skill. I should also mention that if you decide to change the Alexa Skill name itself, which I had initially done and called it "vGhetto Control", make sure you update the Flask App name in __init__.py to the same name (spaces are converted to underscores) or you will run into issues.

Categories // Automation, VCSA, VSAN, vSphere Tags // Alexa, Flask, pyVmomi, REST API, vcenter server appliance, VSAN, vSphere API

Managing ESXi Embedded Host Client settings

05.31.2017 by William Lam // Leave a Comment

There was a question the other day about managing ESXi Embedded Host Client (EHC) settings which you can find by click on the logged-in username and navigating to the "Settings" section as shown in the screenshot below. Customers can manage things like the default VM Console used whether that is the HTML5 VMRC or the Standalone VMRC to auto-refresh and even sharing usage information to help improve the product back to VMware.


In addition to configuring the EHC settings within UI, you can also manage them via automation using the vSphere API and any one of your favorite vSphere SDK/CLIs. The EHC settings are exposed as a set of ESXi Advanced Settings as shown in the screenshot below. These settings are applied on a per-ESXi basis and NOT on a per-user basis.


Below is a table that summarizes the 7 different EHC settings which you can programmatically query to retrieve their current value, default value and whether they have been overridden simliar to what the UI provides today.

Key Description Default Value
UserVars.HostClientCEIPOptIn  Whether or not to opt-in for CEIP in Host Client: 0 for ask 1 for yes 2 for no 0
UserVars.HostClientDefaultConsole  Default console type in Host Client webmks
UserVars.HostClientEnableMOTDNotification  Whether or not to enable MOTD notification on login for Host Client 1
UserVars.HostClientEnableVisualEffects  Whether or not to enable visual effects for Host Client 1
UserVars.HostClientSessionTimeout  Default timeout for Host Client sessions in seconds 900
UserVars.HostClientShowOnlyRecentObjects  Whether or not to show only recent objects in Host Client 1
UserVars.HostClientWelcomeMessage  Welcome message displayed on login in Host Client  Welcome to {{hostname}}

Note: The language settings is based on your browser settings which you can overridden, but it looks like we may not have exposed that as a configurable setting via automation.

Categories // Automation, ESXi Tags // embedded host client, host client

Configure vRealize Automation to use Platform Services Controller as External Identity Provider

05.18.2017 by William Lam // 2 Comments

I was doing some research on an inquiry that I had received from a customer who was interested in configuring their vRealize Automation (vRA) instance to use vCenter's Platform Services Controller (PSC) as an External Identity Provider (IDP) rather than the default VMware Identity Manager (vIDM) which vRA supports natively out of the box. vIDM already supports a large number of websso applications as seen here and it itself can also be used as an External IDP to integrate with things like Active Directory Federation Services (ADFS) for example.

For some customers who are more familiar with the PSC, this is a convenient way to unify their authentication between the different vRealize products which support vIDM and integrating that directly with PSC. Since both solutions spoke SAML, it was merely figuring out process on setting up the External IDP using the PSC. In reading some of our internal Wikis and working with one of the vIDM Engineers, since I was stuck on a particular step, I was able to finally get this to work which I have outlined the steps below. I also learned that we had officially supported this since vRA 7.0 which was great to hear as well.

I know there are number of customers who would also like to see the reverse of this configuration, where PSC can use vIDM as an External IDP. I know this is something the PSC team is currently looking into for External IDP support. If this is something that you are interested in or would like to see specific External IDP setup/configuration, feel free to leave a comment.

Pre-Requisite: 

  • Join Platform Services Controller (PSC) to Active Directory (instructions here & here)
  • Join vRealize Automation (vRA) Appliance to Active Directory (instructions here)

In my lab environment, I have deployed an Embedded VCSA 6.5 (this also works with an External PSC) and vRealize Automation 7.2 (this was prior to 7.3 getting released but should work as well).

[Read more...]

Categories // Uncategorized Tags // Identity Provider, IDP, platform service controller, psc, SAML, vIDM, VMware Identity Manager, vRealize Automation, vsphere web client

  • « Previous Page
  • 1
  • …
  • 274
  • 275
  • 276
  • 277
  • 278
  • …
  • 561
  • Next Page »

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Automating the vSAN Data Migration Pre-check using vSAN API 06/04/2025
  • VCF 9.0 Hardware Considerations 05/30/2025
  • VMware Flings is now available in Free Downloads of Broadcom Support Portal (BSP) 05/19/2025
  • VMUG Connect 2025 - Minimal VMware Cloud Foundation (VCF) 5.x in a Box  05/15/2025
  • Programmatically accessing the Broadcom Compatibility Guide (BCG) 05/06/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025

 

Loading Comments...