Skip to content

Commit 06acc8d

Browse files
authored
Merge pull request #5279 from qinqon/udn-fix-join-subnet-typo
udn: Fix NAD template for join subnets field
2 parents 2017ede + 4fa8bf0 commit 06acc8d

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

go-controller/pkg/clustermanager/userdefinednetwork/template/net-attach-def-template.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ func renderCNINetworkConfig(networkName, nadName string, spec SpecGetter) (map[s
192192
cniNetConf["mtu"] = mtu
193193
}
194194
if len(netConfSpec.JoinSubnet) > 0 {
195-
cniNetConf["joinSubnets"] = netConfSpec.JoinSubnet
195+
cniNetConf["joinSubnet"] = netConfSpec.JoinSubnet
196196
}
197197
if len(netConfSpec.Subnets) > 0 {
198198
cniNetConf["subnets"] = netConfSpec.Subnets

go-controller/pkg/clustermanager/userdefinednetwork/template/net-attach-def-template_test.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
326326
"netAttachDefName": "mynamespace/test-net",
327327
"role": "primary",
328328
"topology": "layer3",
329-
"joinSubnets": "100.65.0.0/16,fd99::/64",
329+
"joinSubnet": "100.65.0.0/16,fd99::/64",
330330
"subnets": "192.168.100.0/16,2001:dbb::/60",
331331
"mtu": 1500
332332
}`,
@@ -350,7 +350,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
350350
"netAttachDefName": "mynamespace/test-net",
351351
"role": "primary",
352352
"topology": "layer2",
353-
"joinSubnets": "100.65.0.0/16,fd99::/64",
353+
"joinSubnet": "100.65.0.0/16,fd99::/64",
354354
"subnets": "192.168.100.0/24,2001:dbb::/64",
355355
"mtu": 1500,
356356
"allowPersistentIPs": true
@@ -376,7 +376,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
376376
"netAttachDefName": "mynamespace/test-net",
377377
"role": "primary",
378378
"topology": "layer2",
379-
"joinSubnets": "100.62.0.0/24,fd92::/64",
379+
"joinSubnet": "100.62.0.0/24,fd92::/64",
380380
"subnets": "192.168.100.0/24,2001:dbb::/64",
381381
"mtu": 1500,
382382
"allowPersistentIPs": true
@@ -461,7 +461,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
461461
"netAttachDefName": "mynamespace/test-net",
462462
"role": "primary",
463463
"topology": "layer3",
464-
"joinSubnets": "100.65.0.0/16,fd99::/64",
464+
"joinSubnet": "100.65.0.0/16,fd99::/64",
465465
"subnets": "192.168.100.0/16,2001:dbb::/60",
466466
"mtu": 1500
467467
}`,
@@ -485,7 +485,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
485485
"netAttachDefName": "mynamespace/test-net",
486486
"role": "primary",
487487
"topology": "layer2",
488-
"joinSubnets": "100.65.0.0/16,fd99::/64",
488+
"joinSubnet": "100.65.0.0/16,fd99::/64",
489489
"subnets": "192.168.100.0/24,2001:dbb::/64",
490490
"mtu": 1500,
491491
"allowPersistentIPs": true
@@ -511,7 +511,7 @@ var _ = Describe("NetAttachDefTemplate", func() {
511511
"netAttachDefName": "mynamespace/test-net",
512512
"role": "primary",
513513
"topology": "layer2",
514-
"joinSubnets": "100.62.0.0/24,fd92::/64",
514+
"joinSubnet": "100.62.0.0/24,fd92::/64",
515515
"subnets": "192.168.100.0/24,2001:dbb::/64",
516516
"mtu": 1500,
517517
"allowPersistentIPs": true

0 commit comments

Comments
 (0)