Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Oct 24, 2023. It is now read-only.
/aks-enginePublic archive

Commit904b3ff

Browse files
authored
Add new Linux VHDs (#5041)
1 parent5c2febf commit904b3ff

File tree

15 files changed

+1673
-15
lines changed

15 files changed

+1673
-15
lines changed

‎.pipelines/e2e-job-template.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
MSI_USER_ASSIGNED_ID:'$(MSI_USER_ASSIGNED_ID_AKS_ENGINE_E2E)'
3636
CONTAINER_RUNTIME:${{ parameters.containerRuntime }}
3737
BLOCK_SSH:${{ parameters.runSSHTests }}
38+
DISTRO:${{ parameters.distro }}
3839

3940
steps:
4041
-template:e2e-step-template.yaml

‎.pipelines/pr-e2e.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,3 +132,14 @@ jobs:
132132
enableKMSEncryption:false
133133
containerRuntime:'containerd'
134134
runSSHTests:true
135+
136+
-template:e2e-job-template.yaml
137+
parameters:
138+
name:'k8s_1_24_2004_e2e'
139+
k8sRelease:'1.24'
140+
apimodel:'examples/e2e-tests/kubernetes/release/default/definition-no-vnet.json'
141+
createVNET:false
142+
enableKMSEncryption:false
143+
containerRuntime:'containerd'
144+
distro:'aks-ubuntu-20.04'
145+
runSSHTests:true

‎pkg/api/azenvtypes.go

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,15 @@ var (
148148
ImageOffer:"aks",
149149
ImageSku:"aks-engine-ubuntu-1804-202112",
150150
ImagePublisher:"microsoft-aks",
151-
ImageVersion:"2022.12.12",
151+
ImageVersion:"2023.01.10",
152+
}
153+
154+
// AKSUbuntu2004OSImageConfig is the AKS Engine image based on Ubuntu 20.04-LTS.
155+
AKSUbuntu2004OSImageConfig=AzureOSImageConfig{
156+
ImageOffer:"aks",
157+
ImageSku:"aks-engine-ubuntu-2004-202301",
158+
ImagePublisher:"microsoft-aks",
159+
ImageVersion:"2023.01.10",
152160
}
153161

154162
// AKSWindowsServer2019OSImageConfig is the aks-engine image based on Windows Server 2019
@@ -205,6 +213,7 @@ var (
205213
AKS1604Deprecated:AKSUbuntu1604OSImageConfig,// for back-compat
206214
AKSUbuntu1804:AKSUbuntu1804OSImageConfig,
207215
AKS1804Deprecated:AKSUbuntu1804OSImageConfig,// for back-compat
216+
AKSUbuntu2004:AKSUbuntu2004OSImageConfig,
208217
ACC1604:ACC1604OSImageConfig,
209218
},
210219
}
@@ -248,6 +257,7 @@ var (
248257
AKS1604Deprecated:AKSUbuntu1604OSImageConfig,// for back-compat
249258
AKSUbuntu1804:AKSUbuntu1804OSImageConfig,
250259
AKS1804Deprecated:AKSUbuntu1804OSImageConfig,// for back-compat
260+
AKSUbuntu2004:AKSUbuntu2004OSImageConfig,
251261
},
252262
}
253263

@@ -290,6 +300,7 @@ var (
290300
AKS1604Deprecated:AKSUbuntu1604OSImageConfig,// for back-compat
291301
AKSUbuntu1804:AKSUbuntu1804OSImageConfig,
292302
AKS1804Deprecated:AKSUbuntu1804OSImageConfig,// for back-compat
303+
AKSUbuntu2004:AKSUbuntu2004OSImageConfig,
293304
},
294305
}
295306

‎pkg/api/const.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ const (
2828
AKSDockerEngineDistro="aks-docker-engine"// deprecated docker-engine distro.
2929
AKSUbuntu1604Distro="aks-ubuntu-16.04"
3030
AKSUbuntu1804Distro="aks-ubuntu-18.04"
31+
AKSUbuntu2004Distro="aks-ubuntu-20.04"
3132
ACC1604Distro="acc-16.04"
3233
)
3334

‎pkg/api/defaults-kubelet_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -760,7 +760,7 @@ func TestProtectKernelDefaults(t *testing.T) {
760760
// Validate that --protect-kernel-defaults is "true" by default for relevant distros
761761
for_,distro:=rangeDistroValues {
762762
switchdistro {
763-
caseAKSUbuntu1604,AKSUbuntu1804:
763+
caseAKSUbuntu1604,AKSUbuntu1804,AKSUbuntu2004:
764764
cs=CreateMockContainerService("testcluster","",3,2,false)
765765
cs.Properties.MasterProfile.Distro=distro
766766
cs.Properties.AgentPoolProfiles[0].Distro=distro
@@ -839,7 +839,7 @@ func TestProtectKernelDefaults(t *testing.T) {
839839
// Validate that --protect-kernel-defaults is overridable
840840
for_,distro:=rangeDistroValues {
841841
switchdistro {
842-
caseUbuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804:
842+
caseUbuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804,AKSUbuntu2004:
843843
cs=CreateMockContainerService("testcluster","",3,2,false)
844844
cs.Properties.MasterProfile.Distro="ubuntu"
845845
cs.Properties.AgentPoolProfiles[0].Distro="ubuntu"

‎pkg/api/defaults.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ import (
2525
)
2626

2727
// DistroValues is a list of currently supported distros
28-
varDistroValues= []Distro{"",Ubuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Flatcar,AKSUbuntu1604,AKSUbuntu1804,Ubuntu1804Gen2,ACC1604}
28+
varDistroValues= []Distro{"",Ubuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Flatcar,AKSUbuntu1604,AKSUbuntu1804,Ubuntu1804Gen2,AKSUbuntu2004,ACC1604}
2929

3030
// PropertiesDefaultsParams is the parameters when we set the properties defaults for ContainerService.
3131
typePropertiesDefaultsParamsstruct {

‎pkg/api/types.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,7 +1286,7 @@ func (m *MasterProfile) IsStorageAccount() bool {
12861286

12871287
// IsVHDDistro returns true if the distro uses VHD SKUs
12881288
func (m*MasterProfile)IsVHDDistro()bool {
1289-
returnm.Distro==AKSUbuntu1604||m.Distro==AKSUbuntu1804
1289+
returnm.Distro==AKSUbuntu1604||m.Distro==AKSUbuntu1804||m.Distro==AKSUbuntu2004
12901290
}
12911291

12921292
// IsAuditDEnabled returns true if the master profile is configured for auditd
@@ -1361,7 +1361,7 @@ func (m *MasterProfile) IsUbuntu1804() bool {
13611361
// IsUbuntu2004 returns true if the master profile distro is based on Ubuntu 20.04
13621362
func (m*MasterProfile)IsUbuntu2004()bool {
13631363
switchm.Distro {
1364-
caseUbuntu2004,Ubuntu2004Gen2:
1364+
caseAKSUbuntu2004,Ubuntu2004,Ubuntu2004Gen2:
13651365
returntrue
13661366
default:
13671367
returnfalse
@@ -1430,7 +1430,7 @@ func (a *AgentPoolProfile) IsFlatcar() bool {
14301430

14311431
// IsVHDDistro returns true if the distro uses VHD SKUs
14321432
func (a*AgentPoolProfile)IsVHDDistro()bool {
1433-
returna.Distro==AKSUbuntu1604||a.Distro==AKSUbuntu1804
1433+
returna.Distro==AKSUbuntu1604||a.Distro==AKSUbuntu1804||a.Distro==AKSUbuntu2004
14341434
}
14351435

14361436
// IsAuditDEnabled returns true if the master profile is configured for auditd
@@ -1513,7 +1513,7 @@ func (a *AgentPoolProfile) IsUbuntu1804() bool {
15131513
func (a*AgentPoolProfile)IsUbuntu2004()bool {
15141514
ifa.OSType!=Windows {
15151515
switcha.Distro {
1516-
caseUbuntu2004,Ubuntu2004Gen2:
1516+
caseAKSUbuntu2004,Ubuntu2004,Ubuntu2004Gen2:
15171517
returntrue
15181518
default:
15191519
returnfalse

‎pkg/api/vlabs/const.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ const (
3333
AKSDockerEngineDistro="aks-docker-engine"// deprecated docker-engine distro.
3434
AKSUbuntu1604Distro="aks-ubuntu-16.04"
3535
AKSUbuntu1804Distro="aks-ubuntu-18.04"
36+
AKSUbuntu2004Distro="aks-ubuntu-20.04"
3637
ACC1604Distro="acc-16.04"
3738
)
3839

@@ -100,7 +101,7 @@ var (
100101
ContainerRuntimeValues= [...]string{"",Docker,Containerd}
101102

102103
// DistroValues holds the valid values for OS distros
103-
DistroValues= []Distro{"",Ubuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Ubuntu1804Gen2,Flatcar,AKSUbuntu1604,AKSUbuntu1804,ACC1604}
104+
DistroValues= []Distro{"",Ubuntu,Ubuntu2004,Ubuntu2004Gen2,Ubuntu1804,Ubuntu1804Gen2,Flatcar,AKSUbuntu1604,AKSUbuntu1804,AKSUbuntu2004,ACC1604}
104105

105106
// DependenciesLocationValues holds the valid values for dependencies location
106107
DependenciesLocationValues= []DependenciesLocation{"",AzureCustomCloudDependenciesLocationPublic,AzureCustomCloudDependenciesLocationChina,AzureCustomCloudDependenciesLocationGerman,AzureCustomCloudDependenciesLocationUSGovernment}

‎pkg/api/vlabs/types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -750,7 +750,7 @@ func (m *MasterProfile) IsUbuntu1804() bool {
750750
// IsUbuntu2004 returns true if the master profile distro is based on Ubuntu 20.04
751751
func (m*MasterProfile)IsUbuntu2004()bool {
752752
switchm.Distro {
753-
caseUbuntu2004,Ubuntu2004Gen2:
753+
caseAKSUbuntu2004,Ubuntu2004,Ubuntu2004Gen2:
754754
returntrue
755755
default:
756756
returnfalse
@@ -938,7 +938,7 @@ func (a *AgentPoolProfile) IsUbuntu1804() bool {
938938
func (a*AgentPoolProfile)IsUbuntu2004()bool {
939939
ifa.OSType!=Windows {
940940
switcha.Distro {
941-
caseUbuntu2004,Ubuntu2004Gen2:
941+
caseAKSUbuntu2004,Ubuntu2004,Ubuntu2004Gen2:
942942
returntrue
943943
default:
944944
returnfalse

‎pkg/api/vlabs/validate_test.go

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,11 @@ func Test_OrchestratorProfile_Validate(t *testing.T) {
250250
Count:10,
251251
Distro:AKSUbuntu1804,
252252
},
253+
{
254+
Name:"ubuntu2004pool",
255+
Count:10,
256+
Distro:AKSUbuntu2004,
257+
},
253258
},
254259
},
255260
},
@@ -4460,7 +4465,7 @@ func TestAgentPoolProfile_ValidateAuditDEnabled(t *testing.T) {
44604465
iferr:=cs.Properties.validateAgentPoolProfiles(false);err.Error()!=expectedMsg {
44614466
t.Errorf("expected error with message : %s, but got %s",expectedMsg,err.Error())
44624467
}
4463-
caseUbuntu,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804,ACC1604:
4468+
caseUbuntu,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804,AKSUbuntu2004,ACC1604:
44644469
iferr:=cs.Properties.validateAgentPoolProfiles(false);err!=nil {
44654470
t.Errorf("AuditDEnabled should work with distro %s, got error %s",distro,err.Error())
44664471
}
@@ -4483,7 +4488,7 @@ func TestMasterProfile_ValidateAuditDEnabled(t *testing.T) {
44834488
iferr:=cs.Properties.validateMasterProfile(false);err.Error()!=expectedMsg {
44844489
t.Errorf("expected error with message : %s, but got %s",expectedMsg,err.Error())
44854490
}
4486-
caseUbuntu,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804,ACC1604:
4491+
caseUbuntu,Ubuntu1804,Ubuntu1804Gen2,AKSUbuntu1604,AKSUbuntu1804,AKSUbuntu2004,ACC1604:
44874492
iferr:=cs.Properties.validateMasterProfile(false);err!=nil {
44884493
t.Errorf("AuditDEnabled should work with distro %s, got error %s",distro,err.Error())
44894494
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp