login vsi company logo login vsi company logo 250x40
header-01.jpg
  • Home
  • Blog
  • Login AM
  • Creating Custom Scripts within Login AM by Using Custom Variables

Warning

JUser: :_load: Unable to load user with ID: 22029

Creating Custom Scripts within Login AM by Using Custom Variables

Creating Custom Scripts within Login AM by Using Custom Variables

The power of Login AM is the dynamic design. When I create a component I am able to fill in the settings on the top level of the component. These values can be used in Linked Values throughout the complete component from a Dynconf to a Citrix Published application.

Toplevel Component:

toplevel component

What often is forgotten is that the name and value is used as a system variable during execution of the component. This is very handy because this gives me the possibility to use these ‘custom’ variables inside a custom script.

In this example I am going to create a path from the variables SOURCEDIR and REVISION.

The easiest way to combine the SOURCEDIR and the REVISION is to create a PowerShell variable.

$APPV_SourcePath

Then we need to call the system variables in the powershell script. This can be done by using the following command: $env:<VariableName>

In my example it will look like this:

$env:SOURCEDIR
$env:REVISION

Now we need to combine all parts.

$APPV_SourcePath = $env:SOURCEDIR + '\'+ $env:REVISION

The command write-host plus the variable is a nice way to check what the outcome is during scripting. The result will be display in your PowerShell window.

Write-host $APPV_SourcePath

Some useful command for showing all system variables:

Get-ChildItem env:

I hope this information helps you in creating custom scripts within Login AM.

About the author

Tags: How-to, Login AM

What our customers are saying

Andrew Mills - Nutanix

“Predictability is a key piece to VDI. It’s one of reasons that VDI has scared people away, but Login VSI solves that. If you’re going to do it, do it right. Login VSI really gives that rubber stamp on doing it right.”

Andrew Mills, VDI Alliances Manager at Nutanix


Akio Kawaguchi - Networld

"Login VSI is the only tool for benchmarking VDI with high level accuracy. We use Login VSI to verify the performance of our internal VDI system and to verify the performance of VDI systems that we integrate for our customers."

Akio Kawaguchi, Deputy General Manager of International Alliance Sector at Networld Corporation


Michael Bernas - Workers' Compensation Board Alberta

“We've used Login VSI for the past 3 years as part of our Disaster Recovery Exercise. It's not only helped us in validating the functionality of our Citrix XenApp farm, but it's also been an invaluable tool in proving the number of concurrent connections into the environments. It’s allowed us to take our theoretical numbers and put actual real life data behind them.”

Michael Bernas, Workers' Compensation Board of Alberta

Login VSI, Inc.

300 Tradecenter

Suite 3460
Woburn, MA 01801

Phone: +1 844 828 3693

Login VSI B.V.

De Entree 85
1101 BH Amsterdam
The Netherlands

Phone: +31 20 705 1200