forked from sonic-net/sonic-buildimage
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sonic-nvgre-tunnel.yang
114 lines (78 loc) · 2.49 KB
/
sonic-nvgre-tunnel.yang
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
module sonic-nvgre-tunnel {
yang-version 1.1;
namespace "http://github.com/Azure/sonic-nvgre-tunnel";
prefix nvgre;
import ietf-inet-types {
prefix inet;
}
import sonic-vlan {
prefix vlan;
}
organization
"SONiC";
contact
"SONiC";
description
"NVGRE Tunnel YANG Module for SONiC OS";
revision 2021-10-31 {
description
"First Revision";
}
container sonic-nvgre-tunnel {
container NVGRE_TUNNEL {
description "NVGRE_TUNNEL part of config_db.json";
list NVGRE_TUNNEL_LIST {
key "tunnel_name";
leaf tunnel_name {
description "NVGRE Tunnel name";
type string {
length 1..255;
}
}
leaf src_ip {
description "Source IP address";
mandatory true;
type inet:ip-address;
}
}
/* end of NVGRE_TUNNEL_LIST */
}
/* end of container NVGRE_TUNNEL */
container NVGRE_TUNNEL_MAP {
description "NVGRE_TUNNEL_MAP part of config_db.json";
list NVGRE_TUNNEL_MAP_LIST {
key "tunnel_name tunnel_map_name";
leaf tunnel_name {
description "NVGRE Tunnel name";
type leafref {
path /nvgre:sonic-nvgre-tunnel/nvgre:NVGRE_TUNNEL/nvgre:NVGRE_TUNNEL_LIST/nvgre:tunnel_name;
}
}
leaf tunnel_map_name {
description "NVGRE Tunnel map name";
type string {
length 1..255;
}
}
leaf vlan_id {
description "VLAN identifier";
mandatory true;
type uint16 {
range 1..4094;
}
}
leaf vsid {
description "Virtual Subnet Identifier";
mandatory true;
type uint32 {
range 0..16777214;
}
}
}
/* end of NVGRE_TUNNEL_MAP_LIST */
}
/* end of container NVGRE_TUNNEL_MAP */
}
/* end of container sonic-nvgre-tunnel */
}
/* end of module sonic-nvgre-tunnel */