Skip to content

Commit 3446059

Browse files
committed
Remove dead code from 'networking' asset
The code for getting the MachineNetworkCIDR from the survey was only every used by the kubevirt platform, and it has been dead since that platform was removed. Delete the networking asset, which no longer does anything, to prevent it causing confusion.
1 parent 8dc309c commit 3446059

File tree

3 files changed

+0
-56
lines changed

3 files changed

+0
-56
lines changed

pkg/asset/installconfig/installconfig.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ func (a *InstallConfig) Dependencies() []asset.Asset {
5656
&sshPublicKey{},
5757
&baseDomain{},
5858
&clusterName{},
59-
&networking{},
6059
&pullSecret{},
6160
&platform{},
6261
}
@@ -67,14 +66,12 @@ func (a *InstallConfig) Generate(parents asset.Parents) error {
6766
sshPublicKey := &sshPublicKey{}
6867
baseDomain := &baseDomain{}
6968
clusterName := &clusterName{}
70-
networking := &networking{}
7169
pullSecret := &pullSecret{}
7270
platform := &platform{}
7371
parents.Get(
7472
sshPublicKey,
7573
baseDomain,
7674
clusterName,
77-
networking,
7875
pullSecret,
7976
platform,
8077
)
@@ -89,9 +86,6 @@ func (a *InstallConfig) Generate(parents asset.Parents) error {
8986
SSHKey: sshPublicKey.Key,
9087
BaseDomain: baseDomain.BaseDomain,
9188
PullSecret: pullSecret.PullSecret,
92-
Networking: &types.Networking{
93-
MachineNetwork: networking.machineNetwork,
94-
},
9589
}
9690

9791
a.Config.AlibabaCloud = platform.AlibabaCloud

pkg/asset/installconfig/installconfig_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,13 @@ func TestInstallConfigGenerate_FillsInDefaults(t *testing.T) {
2727
Platform: types.Platform{None: &none.Platform{}},
2828
}
2929
installConfig := &InstallConfig{}
30-
networking := &networking{}
3130
parents := asset.Parents{}
3231
parents.Add(
3332
sshPublicKey,
3433
baseDomain,
3534
clusterName,
3635
pullSecret,
3736
platform,
38-
networking,
3937
)
4038
if err := installConfig.Generate(parents); err != nil {
4139
t.Errorf("unexpected error generating install config: %v", err)

pkg/asset/installconfig/networking.go

Lines changed: 0 additions & 48 deletions
This file was deleted.

0 commit comments

Comments
 (0)