@@ -16,8 +16,9 @@ import (
1616 "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v7"
1717)
1818
19- func EmptyBootstrapConfigMutator (_ * Cluster , configuration * datamodel.NodeBootstrappingConfiguration ) {}
20- func EmptyVMConfigMutator (vmss * armcompute.VirtualMachineScaleSet ) {}
19+ func EmptyBootstrapConfigMutator (_ * Cluster , configuration * datamodel.NodeBootstrappingConfiguration ) {
20+ }
21+ func EmptyVMConfigMutator (vmss * armcompute.VirtualMachineScaleSet ) {}
2122
2223func DualStackConfigMutator (_ * Cluster , configuration * datamodel.NodeBootstrappingConfiguration ) {
2324 properties := configuration .ContainerService .Properties
@@ -145,117 +146,6 @@ func Test_Windows2022Gen2AzureOverlayNetworkDualStack(t *testing.T) {
145146 })
146147}
147148
148- func Test_Windows23H2AzureNetwork (t * testing.T ) {
149- RunScenario (t , & Scenario {
150- Description : "Windows Server 23H2 with Azure Network" ,
151- Config : Config {
152- Cluster : ClusterAzureNetwork ,
153- VHD : config .VHDWindows23H2 ,
154- VMConfigMutator : EmptyVMConfigMutator ,
155- BootstrapConfigMutator : EmptyBootstrapConfigMutator ,
156- Validator : func (ctx context.Context , s * Scenario ) {
157- ValidateWindowsVersionFromWindowsSettings (ctx , s , "23H2" )
158- ValidateWindowsProductName (ctx , s , "Windows Server 2022 Datacenter" )
159- ValidateWindowsDisplayVersion (ctx , s , "23H2" )
160- ValidateFileHasContent (ctx , s , "/k/kubeletstart.ps1" , "--container-runtime=remote" )
161- ValidateWindowsProcessHasCliArguments (ctx , s , "kubelet.exe" , []string {"--rotate-certificates=true" , "--client-ca-file=c:\\ k\\ ca.crt" })
162- ValidateCiliumIsNotRunningWindows (ctx , s )
163- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
164- ValidateCollectWindowsLogsScript (ctx , s )
165- },
166- },
167- })
168- }
169-
170- func Test_Windows23H2AzureOverlayNetworkDualStack (t * testing.T ) {
171- t .Skip ("Dual stack tests are not working yet" )
172- RunScenario (t , & Scenario {
173- Description : "Windows Server 23H2 with Azure Overlay Network Dual Stack" ,
174- Config : Config {
175- Cluster : ClusterAzureOverlayNetworkDualStack ,
176- VHD : config .VHDWindows23H2 ,
177- VMConfigMutator : DualStackVMConfigMutator ,
178- BootstrapConfigMutator : DualStackConfigMutator ,
179- Validator : func (ctx context.Context , s * Scenario ) {
180- ValidateWindowsVersionFromWindowsSettings (ctx , s , "23H2" )
181- ValidateWindowsProductName (ctx , s , "Windows Server 2022 Datacenter" )
182- ValidateWindowsDisplayVersion (ctx , s , "23H2" )
183- ValidateFileHasContent (ctx , s , "/k/kubeletstart.ps1" , "--container-runtime=remote" )
184- ValidateWindowsProcessHasCliArguments (ctx , s , "kubelet.exe" , []string {"--rotate-certificates=true" , "--client-ca-file=c:\\ k\\ ca.crt" })
185- ValidateCiliumIsNotRunningWindows (ctx , s )
186- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
187- ValidateCollectWindowsLogsScript (ctx , s )
188- },
189- },
190- })
191- }
192-
193- func Test_Windows23H2Gen2AzureNetwork (t * testing.T ) {
194- RunScenario (t , & Scenario {
195- Description : "Windows Server 23H2 with Azure Network - hyperv gen2" ,
196- Config : Config {
197- Cluster : ClusterAzureNetwork ,
198- VHD : config .VHDWindows23H2Gen2 ,
199- VMConfigMutator : EmptyVMConfigMutator ,
200- BootstrapConfigMutator : EmptyBootstrapConfigMutator ,
201- Validator : func (ctx context.Context , s * Scenario ) {
202- ValidateWindowsVersionFromWindowsSettings (ctx , s , "23H2-gen2" )
203- ValidateWindowsProductName (ctx , s , "Windows Server 2022 Datacenter" )
204- ValidateWindowsDisplayVersion (ctx , s , "23H2" )
205- ValidateFileHasContent (ctx , s , "/k/kubeletstart.ps1" , "--container-runtime=remote" )
206- ValidateWindowsProcessHasCliArguments (ctx , s , "kubelet.exe" , []string {"--rotate-certificates=true" , "--client-ca-file=c:\\ k\\ ca.crt" })
207- ValidateCiliumIsNotRunningWindows (ctx , s )
208- ValidateFileHasContent (ctx , s , "/AzureData/CustomDataSetupScript.log" , "CSEScriptsPackageUrl used for provision is https://packages.aks.azure.com/aks/windows/cse/aks-windows-cse-scripts-current.zip" )
209- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
210- ValidateCollectWindowsLogsScript (ctx , s )
211- },
212- },
213- })
214- }
215-
216- func Test_Windows23H2Gen2AzureOverlayDualStack (t * testing.T ) {
217- t .Skip ("Dual stack tests are not working yet" )
218- RunScenario (t , & Scenario {
219- Description : "Windows Server 23H2 with Azure Overlay Network Dual Stack - hyperv gen2" ,
220- Config : Config {
221- Cluster : ClusterAzureOverlayNetworkDualStack ,
222- VHD : config .VHDWindows23H2Gen2 ,
223- VMConfigMutator : DualStackVMConfigMutator ,
224- BootstrapConfigMutator : DualStackConfigMutator ,
225- Validator : func (ctx context.Context , s * Scenario ) {
226- ValidateWindowsVersionFromWindowsSettings (ctx , s , "23H2-gen2" )
227- ValidateWindowsProductName (ctx , s , "Windows Server 2022 Datacenter" )
228- ValidateWindowsDisplayVersion (ctx , s , "23H2" )
229- ValidateFileHasContent (ctx , s , "/k/kubeletstart.ps1" , "--container-runtime=remote" )
230- ValidateWindowsProcessHasCliArguments (ctx , s , "kubelet.exe" , []string {"--rotate-certificates=true" , "--client-ca-file=c:\\ k\\ ca.crt" })
231- ValidateCiliumIsNotRunningWindows (ctx , s )
232- ValidateFileHasContent (ctx , s , "/AzureData/CustomDataSetupScript.log" , "CSEScriptsPackageUrl used for provision is https://packages.aks.azure.com/aks/windows/cse/aks-windows-cse-scripts-current.zip" )
233- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
234- ValidateCollectWindowsLogsScript (ctx , s )
235- },
236- },
237- })
238- }
239-
240- func Test_Windows23H2Gen2CachingRegression (t * testing.T ) {
241- RunScenario (t , & Scenario {
242- Description : "Windows 23H2 VHD built before local cache enabled should still work - overwrite the CSE scripts package URL" ,
243- Config : Config {
244- Cluster : ClusterAzureNetwork ,
245- VHD : config .VHDWindows23H2Gen2 ,
246- VMConfigMutator : EmptyVMConfigMutator ,
247- BootstrapConfigMutator : func (_ * Cluster , nbc * datamodel.NodeBootstrappingConfiguration ) {
248- nbc .ContainerService .Properties .WindowsProfile .CseScriptsPackageURL = "https://packages.aks.azure.com/aks/windows/cse/aks-windows-cse-scripts-v0.0.52.zip"
249- // Secure TLS Bootstrapping isn't supported on this CSE script package version
250- nbc .SecureTLSBootstrappingConfig .Enabled = false
251- },
252- Validator : func (ctx context.Context , s * Scenario ) {
253- ValidateFileHasContent (ctx , s , "/AzureData/CustomDataSetupScript.log" , "CSEScriptsPackageUrl used for provision is https://packages.aks.azure.com/aks/windows/cse/aks-windows-cse-scripts-v0.0.52.zip" )
254- },
255- },
256- })
257- }
258-
259149func Test_Windows2022CachingRegression (t * testing.T ) {
260150 RunScenario (t , & Scenario {
261151 Description : "Windows 2022 VHD built before local cache enabled should still work - overwrite the CSE scripts package URL" ,
@@ -465,53 +355,6 @@ func Test_Windows2022Gen2_k8s_133(t *testing.T) {
465355 },
466356 })
467357}
468- func Test_Windows23H2_Cilium2 (t * testing.T ) {
469- t .Skip ("skipping test for Cilium on Windows 23H2, as it is not supported in production AKS yet" )
470- RunScenario (t , & Scenario {
471- Description : "Windows Server 2022 with Containerd" ,
472- Config : Config {
473- Cluster : ClusterCiliumNetwork ,
474- VHD : config .VHDWindows23H2Gen2 ,
475- VMConfigMutator : EmptyVMConfigMutator ,
476- BootstrapConfigMutator : func (_ * Cluster , configuration * datamodel.NodeBootstrappingConfiguration ) {
477- // cilium is only supported in 1.30 or greater.
478- configuration .ContainerService .Properties .OrchestratorProfile .OrchestratorVersion = "1.30.9"
479- configuration .ContainerService .Properties .OrchestratorProfile .KubernetesConfig .EbpfDataplane = datamodel .EbpfDataplane_cilium
480- },
481- Validator : func (ctx context.Context , s * Scenario ) {
482- ValidateFileHasContent (ctx , s , "/k/kubeletstart.ps1" , "--container-runtime=remote" )
483- ValidateWindowsProcessHasCliArguments (ctx , s , "kubelet.exe" , []string {"--rotate-certificates=true" , "--client-ca-file=c:\\ k\\ ca.crt" })
484- ValidateCiliumIsRunningWindows (ctx , s )
485- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
486- ValidateCollectWindowsLogsScript (ctx , s )
487- },
488- },
489- })
490- }
491-
492- func Test_Windows23H2Gen2_WindowsCiliumNetworking (t * testing.T ) {
493- RunScenario (t , & Scenario {
494- Description : "Windows Server 23H2 Gen2 with Windows Cilium Networking (WCN) enabled" ,
495- Config : Config {
496- Cluster : ClusterAzureNetwork ,
497- VHD : config .VHDWindows23H2Gen2 ,
498- VMConfigMutator : EmptyVMConfigMutator ,
499- BootstrapConfigMutator : func (_ * Cluster , configuration * datamodel.NodeBootstrappingConfiguration ) {
500- if configuration .AgentPoolProfile .AgentPoolWindowsProfile == nil {
501- configuration .AgentPoolProfile .AgentPoolWindowsProfile = & datamodel.AgentPoolWindowsProfile {}
502- }
503- configuration .AgentPoolProfile .AgentPoolWindowsProfile .NextGenNetworkingEnabled = to .Ptr (true )
504- configuration .AgentPoolProfile .AgentPoolWindowsProfile .NextGenNetworkingConfig = to .Ptr ("" )
505- },
506- Validator : func (ctx context.Context , s * Scenario ) {
507- ValidateWindowsCiliumIsRunning (ctx , s )
508- ValidateWindowsSystemServicesRestartConfiguration (ctx , s )
509- ValidateCollectWindowsLogsScript (ctx , s )
510- },
511- },
512- })
513- }
514-
515358func Test_Windows2022_McrChinaCloud_Windows (t * testing.T ) {
516359 RunScenario (t , & Scenario {
517360 Tags : Tags {
0 commit comments