How to define project variable as an array?
OrangeBean
Posts: 8
Hi,
I'm wondering if anyone out there can answer my question in Sabj.? Search on the forum and Google did not help.
Basically Deploy.ps1 of the package expects an array as a parameter. How can I declare an array project variable in Deployment Manager?
$WebServers = @('server1','server2')
I'm wondering if anyone out there can answer my question in Sabj.? Search on the forum and Google did not help.
Basically Deploy.ps1 of the package expects an array as a parameter. How can I declare an array project variable in Deployment Manager?
$WebServers = @('server1','server2')
Comments
That said: Deploy.ps1 will be run on each RGDM target server. So your example doesn't seem like it's the right way to solve your problem.
Yes. You are right. I did the fix yesterday pretty much like you described:
- pass parameter as a string: server1, server2
- in the Deploy.ps1:
param([string]$WebSrvs = $WebServers)
...
$WebSrvs.Split(",")| % {$_.Trim(" ","'","""")} | % { doStuff $_ }