PowerCLI/Powershell: vCenter Slack Bot

An OVF from Opvizor that gets deployed to any VMware environment for powercli slack integration.  Very simple deployment model.  
Current Model:
  1. Appliance can currently only target one vCenter and one slack bot.
  2. Permissions are granted via account designated in OVF config. 
    • (read only recommended for obvious reasons)
    • all commands requested via slack bot run in context of this account.
  3. Multiple appliances/vCenters can target one slack bot. 
    • (Ref.1 of two appliances/vcenter targeting one slack bot)
  4. Appliances can also be assigned to individually different slack bots. 
    • (Ref.2 of two different slack bots)
  5. Both models can be achieved by simply doubling up OVF deployments.  One that targets a singular bot, while the other targets a default/catch-all bot.
  6. Utilizes powerclicore so, there are limitations to what powercli cmdlets can be utilized and same limits that powershellcore may have too.
References:
ref.1

ref.2
Links:


Neat Tidbit:
  1. Not yet in "Help", but there is a little neat 'alias' function.
    • @yourbotname alias badvms=posh get-view -ViewType VirtualMachine -Filter @{'RunTime.ConnectionState'='disconnected|inaccessible|invalid|orphaned'} | select name
    • @yourbotname badvms
  2. This will run your PowerCLI/Powershell line of code by simply passing your alias. (ref.3)
ref.3

No comments: