with ItemHierarchy (UniqueID, Name, ParentID, Path, Level) as ( select fol.UniqueID, fol.Name, fol.ParentID, CAST(fol.Name as varchar(max)), 0 from FOLDERS fol where fol.ParentID IS NULL union all select fol.UniqueID, fol.Name, fol.ParentID, CAST(par.Path + '\' + fol.Name AS varchar(max)), par.Level + 1 from FOLDERS fol inner join ItemHierarchy par on fol.ParentID = par.UniqueID ) select pol.Name as 'PolicyName', ith.Name as 'FolderName', ith.Path as 'Folder Path' from POLICIES pol inner join ItemHierarchy ith on pol.ParentID = ith.UniqueID where pol.Name like '%RunbookName%'
Showing posts with label Orchestrator. Show all posts
Showing posts with label Orchestrator. Show all posts
Thursday, September 26, 2019
SCORCH: Find runbook in folder structure
When you know a runbook exists but you can't find the folder it resides in, you can try this SQL query.
To retrieve the complete path from the root of the folder structure down to the runbook, i used a Common Table Expression (CTE).
It works like a recursive function.
Labels:
Code,
Orchestrator,
SCORCH,
SQL
Thursday, December 14, 2017
PowerShell: Encapsulate 64 bit cmdlet in a 32 bit context
Found a rather old but nice tip from Neil Peterson to tackle a challenge executing Powershell 64 bit cmdlets from a 32 bit execution context (Orchestrator in his example).
Just wanted to share this and add it to my own blog for enhancing my toolbox.
#living in a 32 bit universe
#starting PowerShell 'sysnative' version and thus 64 bit
#more info: https://msdn.microsoft.com/en-us/library/windows/desktop/aa384187(v=vs.85).aspx
$ClusterNodes = .$env:windir\sysnative\WindowsPowerShell\v1.0\powershell.exe {
#living in a 64 bit universe
Get-ClusterNode -Cluster clustername
}
Labels:
Code,
Orchestrator,
PowerShell
Tuesday, April 8, 2014
Microsoft Azure Automation preview!
This is just great! Automation on-premise is what we already know and on which we are currently are automatizing our processes. Yet, as we are busy doing just that, Microsoft is working on automation in the Azure cloud! Earlier this week they made a public preview of Azure Automation available.
Read this blog from Keith Mayer to follow a step-by-step approach getting started with Azure Automation. Furthermore, in the future they will publish information about using other products like Chef with Windows Azure.
Quote from Keith's blog:
More info on Microsoft Azure Automation: http://azure.microsoft.com/en-us/documentation/services/automation/
Have fun! I know I will...
Read this blog from Keith Mayer to follow a step-by-step approach getting started with Azure Automation. Furthermore, in the future they will publish information about using other products like Chef with Windows Azure.
Quote from Keith's blog:
Note: this week, we also announced support for Puppet and Chef for automated provisioning and configuration management of Microsoft Azure cloud resources. If you're currently using these tools as part of your DevOps strategy, be sure to look for upcoming articles that focus on these alternatives for cloud automation.Link to article: http://blogs.technet.com/b/keithmayer/archive/2014/04/04/step-by-step-getting-started-with-windows-azure-automation.aspx
More info on Microsoft Azure Automation: http://azure.microsoft.com/en-us/documentation/services/automation/
Have fun! I know I will...
Labels:
Authoring,
Automation,
Azure,
Azure Automation,
Cloud,
Orchestrator,
SMA
Subscribe to:
Posts (Atom)
