]> git.proxmox.com Git - mirror_frr.git/blob - yang/frr-bgp-route-map.yang
Merge pull request #9516 from qlyoung/fix-alpine-docker-images
[mirror_frr.git] / yang / frr-bgp-route-map.yang
1 module frr-bgp-route-map {
2 yang-version 1.1;
3 namespace "http://frrouting.org/yang/bgp-route-map";
4 prefix frr-bgp-route-map;
5
6 import ietf-inet-types {
7 prefix inet;
8 }
9
10 import frr-route-map {
11 prefix frr-route-map;
12 }
13
14 import frr-filter {
15 prefix filter;
16 }
17
18 import frr-bgp-filter {
19 prefix bgp-filter;
20 }
21
22 import ietf-routing-types {
23 prefix rt-types;
24 }
25
26 organization
27 "Free Range Routing";
28 contact
29 "FRR Users List: <mailto:frog@lists.frrouting.org>
30 FRR Development List: <mailto:dev@lists.frrouting.org>";
31 description
32 "This module defines bgp route map settings";
33
34 revision 2020-01-02 {
35 description
36 "Initial revision";
37 }
38
39 identity match-alias {
40 base frr-route-map:rmap-match-type;
41 description
42 "Match BGP community alias name";
43 }
44
45 identity match-local-preference {
46 base frr-route-map:rmap-match-type;
47 description
48 "Match local-preference of routes";
49 }
50
51 identity match-script {
52 base frr-route-map:rmap-match-type;
53 description
54 "Match script of routes";
55 }
56
57 identity match-origin {
58 base frr-route-map:rmap-match-type;
59 description
60 "Match BGP route origin code";
61 }
62
63 identity rpki {
64 base frr-route-map:rmap-match-type;
65 description
66 "Control rpki specific settings";
67 }
68
69 identity probability {
70 base frr-route-map:rmap-match-type;
71 description
72 "Match portion of routes defined by percentage value";
73 }
74
75 identity source-vrf {
76 base frr-route-map:rmap-match-type;
77 description
78 "Match source vrf of routes";
79 }
80
81 identity peer {
82 base frr-route-map:rmap-match-type;
83 description
84 "Match peer address";
85 }
86
87 identity mac-address-list {
88 base frr-route-map:rmap-match-type;
89 description
90 "Match MAC address access-list";
91 }
92
93 identity ip-route-source {
94 base frr-route-map:rmap-match-type;
95 description
96 "Match advertising source address of route";
97 }
98
99 identity ip-route-source-prefix-list {
100 base frr-route-map:rmap-match-type;
101 description
102 "Match advertising source address of route";
103 }
104
105 identity evpn-route-type {
106 base frr-route-map:rmap-match-type;
107 description
108 "Match EVPN route type";
109 }
110
111 identity evpn-default-route {
112 base frr-route-map:rmap-match-type;
113 description
114 "Match EVPN default Type-5 route";
115 }
116
117 identity evpn-vni {
118 base frr-route-map:rmap-match-type;
119 description
120 "Match EVPN VNI";
121 }
122
123 identity evpn-rd {
124 base frr-route-map:rmap-match-type;
125 description
126 "Match EVPN route distinguisher";
127 }
128
129 identity match-community {
130 base frr-route-map:rmap-match-type;
131 description
132 "Match BGP community list";
133 }
134
135 identity match-large-community {
136 base frr-route-map:rmap-match-type;
137 description
138 "Match BGP large-community list";
139 }
140
141 identity match-extcommunity {
142 base frr-route-map:rmap-match-type;
143 description
144 "Match BGP extcommunity list";
145 }
146
147 identity as-path-list {
148 base frr-route-map:rmap-match-type;
149 description
150 "Match BGP AS path list";
151 }
152
153 identity ipv4-nexthop {
154 base frr-route-map:rmap-match-type;
155 description
156 "Match IPv4 next hop address";
157 }
158
159 identity ipv6-nexthop {
160 base frr-route-map:rmap-match-type;
161 description
162 "Match IPv6 next hop address";
163 }
164
165 identity distance {
166 base frr-route-map:rmap-set-type;
167 description
168 "Set BGP administrative distance to use";
169 }
170
171 identity set-extcommunity-none {
172 base frr-route-map:rmap-set-type;
173 description
174 "Set BGP extended community attribute";
175 }
176
177 identity set-extcommunity-rt {
178 base frr-route-map:rmap-set-type;
179 description
180 "Set BGP extended community attribute";
181 }
182
183 identity set-extcommunity-soo {
184 base frr-route-map:rmap-set-type;
185 description
186 "Set BGP extended community attribute";
187 }
188
189 identity set-extcommunity-lb {
190 base frr-route-map:rmap-set-type;
191 description
192 "Set BGP extended community attribute";
193 }
194
195 identity set-ipv4-nexthop {
196 base frr-route-map:rmap-set-type;
197 description
198 "Set the IPv4 next-hop to peer-address/unchanged";
199 }
200
201 identity ipv4-vpn-address {
202 base frr-route-map:rmap-set-type;
203 description
204 "Set IPv4 VPN next-hop address";
205 }
206
207 identity ipv6-nexthop-global {
208 base frr-route-map:rmap-set-type;
209 description
210 "Set IPv6 next-hop global address";
211 }
212
213 identity ipv6-prefer-global {
214 base frr-route-map:rmap-set-type;
215 description
216 "Set IPv6 next-hop to prefer global address";
217 }
218
219 identity ipv6-peer-address {
220 base frr-route-map:rmap-set-type;
221 description
222 "Set IPv6 next-hop peer address";
223 }
224
225 identity ipv6-vpn-address {
226 base frr-route-map:rmap-set-type;
227 description
228 "Set IPv6 VPN next-hop address";
229 }
230
231 identity label-index {
232 base frr-route-map:rmap-set-type;
233 description
234 "Set the label index to associate with the prefixs";
235 }
236
237 identity set-local-preference {
238 base frr-route-map:rmap-set-type;
239 description
240 "Set the BGP local preference path attribute";
241 }
242
243 identity set-origin {
244 base frr-route-map:rmap-set-type;
245 description
246 "Set BGP route origin code";
247 }
248
249 identity weight {
250 base frr-route-map:rmap-set-type;
251 description
252 "Set the BGP weight attribute";
253 }
254
255 identity originator-id {
256 base frr-route-map:rmap-set-type;
257 description
258 "Set the BGP originator ID attribute";
259 }
260
261 identity table {
262 base frr-route-map:rmap-set-type;
263 description
264 "Export route to non-main kernel table";
265 }
266
267 identity atomic-aggregate {
268 base frr-route-map:rmap-set-type;
269 description
270 "Set BGP atomic-aggregate attribute";
271 }
272
273 identity as-path-prepend {
274 base frr-route-map:rmap-set-type;
275 description
276 "Set the BGP AS-path attribute";
277 }
278
279 identity as-path-exclude {
280 base frr-route-map:rmap-set-type;
281 description
282 "Set the BGP AS-path attribute";
283 }
284
285 identity set-community {
286 base frr-route-map:rmap-set-type;
287 description
288 "Set the BGP community attribute";
289 }
290
291 identity set-large-community {
292 base frr-route-map:rmap-set-type;
293 description
294 "Set the BGP large-community attribute";
295 }
296
297 identity aggregator {
298 base frr-route-map:rmap-set-type;
299 description
300 "Set the BGP aggregator attribute";
301 }
302
303 identity comm-list-delete {
304 base frr-route-map:rmap-set-type;
305 description
306 "Set BGP community list (for deletion)";
307 }
308
309 identity large-comm-list-delete {
310 base frr-route-map:rmap-set-type;
311 description
312 "Set BGP large community list (for deletion)";
313 }
314
315 identity set-evpn-gateway-ip-ipv4 {
316 base frr-route-map:rmap-set-type;
317 description
318 "Set EVPN gateway IP overlay index IPv4";
319 }
320
321 identity set-evpn-gateway-ip-ipv6 {
322 base frr-route-map:rmap-set-type;
323 description
324 "Set EVPN gateway IP overlay index IPv6";
325 }
326
327 grouping extcommunity-non-transitive-types {
328 leaf two-octet-as-specific {
329 type boolean;
330 description
331 "Non-Transitive Two-Octet AS-Specific Extended Community";
332 }
333 }
334
335 typedef extcommunity-lb-type {
336 type enumeration {
337 enum "explicit-bandwidth" {
338 value 0;
339 description
340 "Bandwidth value in Mbps";
341 }
342 enum "cumulative-bandwidth" {
343 value 1;
344 description
345 "Cumulative bandwidth of all multipaths (outbound-only)";
346 }
347 enum "computed-bandwidth" {
348 value 2;
349 description
350 "Internally computed bandwidth based on number of multipaths (outbound-only)";
351 }
352 }
353 description
354 "ext-community link bandwidth types.";
355 }
356
357 augment "/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:rmap-match-condition/frr-route-map:match-condition" {
358 case local-preference {
359 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-local-preference')";
360 leaf local-preference {
361 type uint32 {
362 range "0..4294967295";
363 }
364 }
365 }
366
367 case alias {
368 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-alias')";
369 leaf alias {
370 type string;
371 }
372 }
373
374 case script {
375 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-script')";
376 leaf script {
377 type string;
378 }
379 }
380
381 case origin {
382 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-origin')";
383 leaf origin {
384 type enumeration {
385 enum "egp" {
386 value 0;
387 description
388 "Remote EGP";
389 }
390 enum "igp" {
391 value 1;
392 description
393 "Local IGP";
394 }
395 enum "incomplete" {
396 value 2;
397 description
398 "Unknown heritage";
399 }
400 }
401 }
402 }
403
404 case rpki {
405 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:rpki')";
406 leaf rpki {
407 type enumeration {
408 enum "invalid" {
409 value 0;
410 description
411 "Invalid prefix";
412 }
413 enum "notfound" {
414 value 1;
415 description
416 "Prefix not found";
417 }
418 enum "valid" {
419 value 2;
420 description
421 "Valid prefix";
422 }
423 }
424 }
425 }
426
427 case probability {
428 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:probability')";
429 leaf probability {
430 type uint8 {
431 range "0..100";
432 }
433 }
434 }
435
436 case source-vrf {
437 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:source-vrf')";
438 leaf source-vrf {
439 type string;
440 }
441 }
442
443 case peer {
444 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:peer')";
445 choice peer {
446 description
447 "Value of the peer";
448 case peer-ipv4-address {
449 description
450 "IP address of peer";
451 leaf peer-ipv4-address {
452 type inet:ipv4-address;
453 }
454 }
455
456 case peer-interface {
457 description
458 "Interface name of peer";
459 leaf peer-interface {
460 type string;
461 }
462 }
463
464 case peer-ipv6-address {
465 description
466 "IPv6 address of peer";
467 leaf peer-ipv6-address {
468 type inet:ipv6-address;
469 }
470 }
471
472 case peer-local {
473 description
474 "Static or Redistributed routes";
475 leaf peer-local {
476 type boolean;
477 }
478 }
479 }
480 }
481
482 case access-list-name {
483 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:mac-address-list') or "
484 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:as-path-list') or "
485 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ip-route-source') or "
486 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ip-route-source-prefix-list')";
487 description
488 "Access-list name";
489 leaf list-name {
490 type filter:access-list-name;
491 }
492 }
493
494 case evpn-default-route {
495 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-default-route')";
496 description
497 "Match default EVPN type-5 route";
498 leaf evpn-default-route {
499 type empty;
500 }
501 }
502
503 case evpn-vni {
504 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-vni')";
505 description
506 "Match eVPN VNI";
507 leaf evpn-vni {
508 type uint32 {
509 range "1..16777215";
510 }
511 }
512 }
513
514 case evpn-route-type {
515 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-route-type')";
516 description
517 "Match eVPN route-type";
518 leaf evpn-route-type {
519 type enumeration {
520 enum "macip" {
521 value 0;
522 description
523 "Mac-IP route";
524 }
525 enum "multicast" {
526 value 1;
527 description
528 "IMET route";
529 }
530 enum "prefix" {
531 value 2;
532 description
533 "Prefix route";
534 }
535 }
536 }
537 }
538
539 case evpn-rd {
540 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-rd')";
541 description
542 "Match eVPN route-distinguisher";
543 leaf route-distinguisher {
544 type rt-types:route-distinguisher;
545 }
546 }
547
548 case comm-list-name {
549 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-community') or "
550 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-large-community') or "
551 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-extcommunity')";
552 container comm-list {
553 leaf comm-list-name {
554 type bgp-filter:bgp-list-name;
555 }
556
557 leaf comm-list-name-exact-match {
558 type boolean;
559 description
560 "Do exact matching of communities";
561 }
562 }
563 }
564
565 case ipv4-address {
566 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ipv4-nexthop')";
567 leaf ipv4-address {
568 type inet:ipv4-address;
569 description
570 "IPv4 address";
571 }
572 }
573
574 case ipv6-address {
575 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ipv6-nexthop')";
576 leaf ipv6-address {
577 type inet:ipv6-address;
578 description
579 "IPv6 address";
580 }
581 }
582 }
583
584 augment "/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:rmap-set-action/frr-route-map:set-action" {
585 case distance {
586 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:distance')";
587 leaf distance {
588 type uint8 {
589 range "0..255";
590 }
591 }
592 }
593
594 case extcommunity-none {
595 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-none')";
596 description
597 "Value of the BGP extended community attribute";
598 leaf extcommunity-none {
599 type boolean;
600 description "No extended community attribute";
601 }
602 }
603
604 case extcommunity-rt {
605 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-rt')";
606 description
607 "Value of the ext-community";
608 leaf extcommunity-rt {
609 type string;
610 description
611 "Set BGP ext-community route-target attribute";
612 }
613 }
614
615 case extcommunity-soo {
616 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-soo')";
617 description
618 "Value of the ext-community";
619 leaf extcommunity-soo {
620 type string;
621 description
622 "Set BGP ext-community site-of-origin attribute";
623 }
624 }
625
626 case extcommunity-lb {
627 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-lb')";
628 container extcommunity-lb {
629 description
630 "Value of the ext-community.";
631 leaf lb-type {
632 type frr-bgp-route-map:extcommunity-lb-type;
633 }
634
635 leaf bandwidth {
636 when "../lb-type = 'explicit-bandwidth'";
637 type uint16 {
638 range "1..25600";
639 }
640 description
641 "Bandwidth value in Mbps";
642 }
643 uses extcommunity-non-transitive-types;
644 }
645 }
646
647 case ipv4-address {
648 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv4-vpn-address')";
649 description
650 "Set the IPv4 address";
651 leaf ipv4-address {
652 type inet:ipv4-address;
653 }
654 }
655
656 case ipv4-nexthop {
657 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-ipv4-nexthop')";
658 leaf ipv4-nexthop {
659 type string;
660 }
661 }
662
663 case ipv6-address {
664 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-nexthop-global') or "
665 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-vpn-address')";
666 description
667 "Set the IPv6 address";
668 leaf ipv6-address {
669 type inet:ipv6-address;
670 }
671 }
672
673 case preference {
674 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-prefer-global') or "
675 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-peer-address')";
676 leaf preference {
677 type boolean;
678 }
679 }
680
681 case label-index {
682 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:label-index')";
683 leaf label-index {
684 type uint32 {
685 range "0..1048560";
686 }
687 }
688 }
689
690 case local-pref {
691 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-local-preference')";
692 leaf local-pref {
693 type string;
694 }
695 }
696
697 case weight {
698 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:weight')";
699 leaf weight {
700 type uint32 {
701 range "0..4294967295";
702 }
703 }
704 }
705
706 case origin {
707 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-origin')";
708 leaf origin {
709 type enumeration {
710 enum "egp" {
711 value 0;
712 description
713 "Remote EGP";
714 }
715 enum "igp" {
716 value 1;
717 description
718 "Local IGP";
719 }
720 enum "incomplete" {
721 value 2;
722 description
723 "Unknown heritage";
724 }
725 }
726 }
727 }
728
729 case originator-id {
730 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:originator-id')";
731 leaf originator-id {
732 type inet:ipv4-address;
733 }
734 }
735
736 case table {
737 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:table')";
738 leaf table {
739 type uint32 {
740 range "1..4294967295";
741 }
742 }
743 }
744
745 case atomic-aggregate {
746 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:atomic-aggregate')";
747 leaf atomic-aggregate {
748 type empty;
749 }
750 }
751
752 case as-path-prepend {
753 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:as-path-prepend')";
754 choice as-path-prepend {
755 description
756 "Value of the BGP AS-path attribute";
757 case prepend-as {
758 description
759 "Prepend the mentioned AS-path";
760 leaf prepend-as-path {
761 type string;
762 }
763 }
764
765 case last-as {
766 description
767 "Prepend the last ASN in the AS-path";
768 leaf last-as {
769 type uint8 {
770 range "1..10";
771 }
772 }
773 }
774 }
775 }
776
777 case as-path-exclude {
778 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:as-path-exclude')";
779 leaf exclude-as-path {
780 type string;
781 description
782 "Exclude the mentioned AS-path";
783 }
784 }
785
786 case community {
787 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-community')";
788 choice community {
789 description
790 "Value of the BGP community attribute";
791 case none {
792 description
793 "No community attribute";
794 leaf community-none {
795 type boolean;
796 }
797 }
798
799 case community-string {
800 description
801 "Community string";
802 leaf community-string {
803 type string;
804 }
805 }
806 }
807 }
808
809 case large-community {
810 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-large-community')";
811 choice large-community {
812 description
813 "Value of the BGP large-community attribute";
814 case none {
815 description
816 "No large-community attribute";
817 leaf large-community-none {
818 type boolean;
819 }
820 }
821
822 case large-community-string {
823 description
824 "Large-Community string";
825 leaf large-community-string {
826 type string;
827 }
828 }
829 }
830 }
831
832 case aggregator {
833 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:aggregator')";
834 container aggregator {
835 leaf aggregator-asn {
836 type uint32 {
837 range "1..4294967295";
838 }
839 description
840 "ASN of the aggregator";
841 }
842
843 leaf aggregator-address {
844 when "../aggregator-asn > 0 or "
845 + "../aggregator-asn <= 4294967295";
846 type inet:ipv4-address;
847 description
848 "IPv4 address of the aggregator";
849 }
850 }
851 }
852
853 case comm-list-name {
854 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:comm-list-delete') or "
855 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:large-comm-list-delete')";
856 leaf comm-list-name {
857 type bgp-filter:bgp-list-name;
858 }
859 }
860 case evpn-gateway-ip-ipv4 {
861 when
862 "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action,
863 'frr-bgp-route-map:set-evpn-gateway-ip-ipv4')";
864 description
865 "Set EVPN gateway IP overlay index IPv4";
866 leaf evpn-gateway-ip-ipv4 {
867 type inet:ipv4-address;
868 }
869 }
870 case evpn-gateway-ip-ipv6 {
871 when
872 "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action,
873 'frr-bgp-route-map:set-evpn-gateway-ip-ipv6')";
874 description
875 "Set EVPN gateway IP overlay index IPv6";
876 leaf evpn-gateway-ip-ipv6 {
877 type inet:ipv6-address;
878 }
879 }
880 }
881 }