1+ {
2+ "DEVICE_METADATA": {
3+ "localhost": {
4+ "cluster": "t1-smartswitch-01"
5+ }
6+ },
7+ "VIP_TABLE" : {
8+ "{{ vip }}" : {}
9+ },
10+ "DPU": {
11+ {% - for dpu_index in range (0, dpu_num ) %}
12+ "dpu{{ dpu_index }}": {
13+ "dpu_id": "{{ dpu_index }}",
14+ "gnmi_port": "50052",
15+ "local_port": "8080",
16+ "midplane_ipv4": "169.254.200.{{ dpu_index + 1 }}",
17+ "orchagent_zmq_port": "8100",
18+ {% - if dpu_index == dpu_under_test_index %}
19+ "pa_ipv4": "{{ mock_pa_ipv4 }}",
20+ "local_nexthop_ip": "{{ mock_pa_ipv4 }}",
21+ {% - else %}
22+ "pa_ipv4": "18.{{ dpu_index }}.202.1",
23+ "local_nexthop_ip": "18.{{ dpu_index }}.202.1",
24+ {% - endif %}
25+ "state": "up",
26+ "vdpu_id": "vdpu0_{{ dpu_index }}",
27+ "vip_ipv4": "10.1.0.5"
28+ }{% if not loop .last %} ,{% endif %}
29+ {% - endfor %}
30+ },
31+ "REMOTE_DPU": {
32+ {% - for dpu_index in range (0, dpu_num ) %}
33+ "dpu{{ dpu_index + dpu_num }}": {
34+ "dpu_id": "{{ dpu_index + dpu_num }}",
35+ "npu_ipv4": "{{ peer_loopback0_ip }}",
36+ "pa_ipv4": "18.{{ dpu_index }}.202.1",
37+ "type": "cluster"
38+ }{% if not loop .last %} ,{% endif %}
39+ {% - endfor %}
40+ },
41+ "VDPU": {
42+ {% - for dpu_index in range (0, dpu_num ) %}
43+ "vdpu0_{{ dpu_index }}": {
44+ "main_dpu_ids": "dpu{{ dpu_index }}"
45+ },
46+ {% - endfor %}
47+ {% - for dpu_index in range (0, dpu_num ) %}
48+ "vdpu1_{{ dpu_index }}": {
49+ "main_dpu_ids": "dpu{{ dpu_index + dpu_num }}"
50+ }{% if not loop .last %} ,{% endif %}
51+ {% - endfor %}
52+ },
53+ "VXLAN_TUNNEL": {
54+ "tunnel_v4": {
55+ "src_ip": "{{ loopback0_ip }}"
56+ }
57+ },
58+ "VNET": {
59+ "{{ vnet_name }}": {
60+ "vxlan_tunnel": "tunnel_v4",
61+ "vni": "{{ vni }}",
62+ "peer_list": ""
63+ }
64+ },
65+ "PORTCHANNEL_INTERFACE" : {
66+ "{{ vnet_interface }}" : {
67+ "vnet_name" : "{{ vnet_name }}"
68+ }
69+ }
70+ }
0 commit comments