Blogs

Scripting How-To: Iterating a Configuration Change Inside a for-each Loop

By Erdem posted 03-30-2016 14:24

  

You can write an event script  to perform a configuration change by looping through the routing instances of the router and change some attributes of the static routes. To do so, use the following script:

 

var $configuration = {

    <configuration> {

         <top-level-tag> {

                  for-each ($something) {

                         <some-other-tag> {

                                  ..

                           }

                 }

        }

    }

}

 

var $results := { call jcs:load-configuration($connection, $configuration); }

 

 


#How-To