Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2017
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. / # cat /etc/calico/confd/templates/bird_ipam.cfg.template
  2. # Generated by confd
  3. filter calico_pools {
  4. loop_allow();
  5. if ( net ~ 192.168.100.100/32 ) then {
  6. accept;
  7. }
  8. calico_aggr();
  9. {{range ls "/pool"}}{{$data := json (getv (printf "/pool/%s" .))}}
  10. if ( net ~ {{$data.cidr}} ) then {
  11. accept;
  12. }
  13. {{end}}
  14. reject;
  15. }
  16.  
  17.  
  18.  
  19. generates
  20.  
  21. / # cat /etc/calico/confd/config/bird_ipam.cfg
  22. # Generated by confd
  23. filter calico_pools {
  24. loop_allow();
  25. if ( net ~ 192.168.100.100/32 ) then {
  26. accept;
  27. }
  28. calico_aggr();
  29.  
  30. if ( net ~ 192.168.4.0/22 ) then {
  31. accept;
  32. }
  33.  
  34. reject;
  35. }
  36.  
  37.  
  38. which is the filter applied outbound to the ebgp peer
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement