It's been about a month since I last posted. Well, I've been a little busy. I've been starting the interview process for a few companies. Since this upcoming Fall semester is my last, it is imperative that I have a software engineering job lined up for January 2016. And my week is spent full-time as a tech engineer working in the automation department at some company where I create PowerShell scripts leveraging FreeMarker that are utilized within CSC's Agility platform.
So...... to the point of this blog. I've been working on a script lately that validates the properties of an instance and then compares it to the properties listed in Agility using a Java API called FreeMarker. I just want to display an example for extracting properties from VMs in Agility and then assigning it to a variable in PowerShell.
*NOTE* Scripts leveraging FreeMarker can only be run in Agility with the extensions button enabled when adding/creating the script in Agility. They will not execute properly in PowerShell ISE, etc.. The FreeMarker aspect of the script will only be viewed as a multi-lined comment in traditional PowerShell editor settings.
Here's an example code snippet that extracts a designated VM asset property from an Agility template in agility and assigns it to a PowerShell variable...
<#assign agilityOSProperty = vmAssetProperty(this, "template.domain")>
$agilityOSProperty = '${agilityOSProperty.stringValue}'
$agilityOSProperty = $agilityOSProperty.ToUpper()
link that may be of interest ---> http://freemarker.org/
A young professionals blog on various software engineering, computer science and programming topics.
Subscribe to:
Post Comments (Atom)
Getting 60gb of Json Data into MySql
The other day I had write a 60gb Json file to a MySql database. The data was already clean and deduped, so all that had to be done was to wr...
-
This topic is somewhat a pet peeve of mine.. I tend to get slightly annoyed when people or job descriptions act as if Java is JavaScript, ...
-
Here's a cool video I've found on YouTube that illustrates sorting algorithms with the use of visualization and audio. Pretty cool...
-
SCRUM meetings, three times a week. What's it like? Well imagine running a marathon (26.2 miles), and every 3 miles there was a...
No comments:
Post a Comment