0

Right now my json arm template parameter file looks like following where i am passing individual octopus variable value and it gets assigned into array inside template.

"parameters": {

"HighPriorityQueues": {

  "value": [
    "#{HighPriorityQueue1}",
    "#{HighPriorityQueue2}",
    "#{HighPriorityQueue3}"
  ]
}

}

Octopus Variable

Name: HighPriorityQueue1 Value: events

Name: HighPriorityQueue2 Value: workflow

Name: HighPriorityQueue3 Value: scheduling

I am looking for solution where i can pass entire array from octopus so i don't have to make any change in template in future if there is any new value in array. I should be able to update octopus array variable and simply redeploy to add new azure resource.

I tried following way to define octopus variable but it doesn't work

Name: parameters:HighPriorityQueues

Value: ["events", "workflow", "scheduling"]

Does anyone know how to pass array from octopus? I would really appreciate if you can help me here.

Thanks

1 Answer 1

0

I found workaround, I passed string variable from octopus with value "events,workflow,scheduling"

Inside arm template i used split function to generate array

"HighPriorityQueuesArray": "[split(parameters('HighPriorityQueues'), ',')]"

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.