Ask Your Question
0

how to loop a nested for _each loop.

asked 2018-11-14 14:32:56 -0500

anonymous user

Anonymous

I have 3 for_each nested loops for rules. How can I have the loop set.

resources:
  SECURITY_GROUP:
    type: OS::Neutron::SecurityGroup
    properties:
      name: { get_param: GNAME }
         repeat:
           for_each:
             <%list1%>: {get_param: list1s }
           template:
             repeat:
               for_each:
                 <%list2%>: {get_param: list2s }
               template:
                 rules:
                   port: <%list1%>
                   remote_ip_prefix: <%list2%>

This is giving an Error. If I keept rules before the first repeat it gives error that it is not a map

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
0

answered 2018-11-15 03:49:57 -0500

Hey! I think you did not break your Nested Loop so it's shows error. I share a for_each nested loop body, please follow this structure I think solve your problem. For any types of errors as well as https://www.msofficetechnicalsupportnumbers.com/blog/tag/fix-xbox-one-s-error-code-0x80072ee7/ (error code 0x80072ee7) just take help from error link.

Bool break_flag = False; foreach{ foreach{ if(your condition ==true) { break_flag = true; break; } } if(break_flag== true) { break; } }

Note: For more details at: https://codereview.stackexchange.com/questions/70419/combining-two-arrays-using-nested-foreach-loops (https://codereview.stackexchange.com/...)

edit flag offensive delete link more
0

answered 2018-11-16 03:12:37 -0500

if I use this key in another list record action ( required) then I can't use the data returned as I can't use a nested for each loop. For Epson printer updated or some errors like https://www.printererrorrepair.com/blog/easy-apply-methods-fixing-epson-error-code-0x97/ (Epson error code 0x97) and 009x the contact epson team.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2018-11-14 14:32:56 -0500

Seen: 34 times

Last updated: Nov 14 '18