Hello Everyone!

Today It is my turn to write in the Coretech christmas calendar!

Currently I am working a lot in Service Management Automation (SMA), a part for Windows Azure Pack. More info: http://aka.ms/introToSMA

SMA is based on PowerShell workflow, so this could be used in other scenarios than within SMA.

The first example i want to show is an easy way to get the selected object(s) in a Service Manager Request Offering

Download “Get-SCSMCIFromUserInput.zip” Get-SCSMCIFromUserInput.zip – Downloaded 198 times – 789 B

Setup / Import

  1. Download or create Get-SCSMCIFromUserInput.ps1
  2. Open WAP Admin Portal
  3. Go to Automation
  4. Import Runbook

Creating Assets

This runbook uses 2 assets.

  • “SCSM Server” – a variable that contains the dns name of the scsm server
  • “SCSM Access Account” – a credential which contains the account to connect to the SCSM server.

To create the assets you can use the following PowerShell code

To make this work in your environment, change the web service end point to point at your SMA server

and change the SCSM information to your servername and account info

Runbook

Notice that this runbook is using the Import-Module to import the SCSM module from your installation directory.

Please change this to fit your installation.

NB! there are several different ways to do this. This example has been simplified to make it easier to use.

Using the runbook

This is a example runbook that is designed to be triggered from SCSM. Inputs include the service request GUID which we use to send to the Get-SCSMCIFromUserInput.

Merry Christmas!!!