PowerOrion A Module for PowerShell Tim Danner edited this page Jan 12, 2017 · 3 revisions
What is it? PowerOrion is a PowerShell Module, based on the Orion SDK. Essentially it is an attempt to take some of the sample scripts included in the SDK, and to convert those to PowerShell Cmdlets
Why A Module? Converting this code into a module has several benefits:
Pages 25
Home About SWIS Account Management Agents Alerts
1. By creating Cmdlets, actions can be performed much faster. For example, to add nodes, rather than editing a script and calling that, you can now just call something like
What this boils down to is when writing your own scripts, these can now be much smaller in size, and faster to develop, as a lot of the “plumbing” is already done (instead of having to copy and paste a 75 line script, you can now achieve the same in a couple of lines).
Discovery IPAM 4.5.x API IPAM 4.6 API IPAM API IPAM vNext API
2. It’s more intuitive, and fits conventional PowerShell Verb-Noun naming conventions
Managing Custom Properties
3. By building in error handling, and through the use of defaults and parameter sets, there is less chance for user error. For example, when building statements in either the console or the IDE it can prompt on possible options for parameters.
NCM Config Search
4. Built-in documentation. By using native functionality in PowerShell help and examples can be included with the modules.
Installing the Module To install PowerOrion, follow these steps: 1. Visit https://github.com/solarwinds/OrionSDK, click the green "Clone or download" button, and then click "Download ZIP". 2. Extract the zip to a temp directory. 3. Copy the PowerOrion directory from the Samples\PowerShell directory you just extract to either: i. $pshome\Modules ( %windir%\System32\WindowsPowerShell\v1.0\Modules ) - this will install PowerOrion system-wide. ii. $home\Documents\WindowsPowerShell\Modules ( %UserProfile%\Documents\WindowsPowerShell\Modules ) - this will install PowerShell for the current user only. Now that PowerOrion is installed, you can load it into the current PowerShell session with: Import-Module PowerOrion
To see a list of all commands: Get-Command -Module PowerOrion
For more information on installing and using modules see Get-Help About_Modules
NCM Config Transfer Show 10 more pages…
Clone this wiki locally https://github.com/solarwinds/OrionSDK.wiki.git
PowerOrion A Module for PowerShell · solarwinds/OrionSDK Wiki ...
solarwinds / OrionSDK
PowerOrion A Module for PowerShell Tim Danner edited this page Jan 12, 2017 · 3 revisions
What is it? PowerOrion is a PowerShe...