Skip to content
This repository was archived by the owner on Jan 11, 2023. It is now read-only.

Commit 8f6a259

Browse files
authored
add k8s v1.7.15 support (#2490)
1 parent e22b3fc commit 8f6a259

File tree

6 files changed

+27
-21
lines changed

6 files changed

+27
-21
lines changed

pkg/acsengine/k8s_versions.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ var KubeConfigs = map[string]map[string]string{
159159
common.KubernetesVersion1Dot8Dot2: getK8sVersionComponents("1.8.2", map[string]string{"windowszip": "v1.8.2-2int.zip"}),
160160
common.KubernetesVersion1Dot8Dot1: getK8sVersionComponents("1.8.1", map[string]string{"windowszip": "v1.8.1-2int.zip"}),
161161
common.KubernetesVersion1Dot8Dot0: getK8sVersionComponents("1.8.0", map[string]string{"windowszip": "v1.8.0-2int.zip"}),
162+
common.KubernetesVersion1Dot7Dot15: getK8sVersionComponents("1.7.15", map[string]string{"windowszip": "v1.7.15-1int.zip"}),
162163
common.KubernetesVersion1Dot7Dot14: getK8sVersionComponents("1.7.14", map[string]string{"windowszip": "v1.7.14-1int.zip"}),
163164
common.KubernetesVersion1Dot7Dot13: getK8sVersionComponents("1.7.13", map[string]string{"windowszip": "v1.7.13-1int.zip"}),
164165
common.KubernetesVersion1Dot7Dot12: getK8sVersionComponents("1.7.12", map[string]string{"windowszip": "v1.7.12-2int.zip"}),

pkg/api/common/const.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,8 @@ const (
109109
KubernetesVersion1Dot7Dot13 string = "1.7.13"
110110
// KubernetesVersion1Dot7Dot14 is the major.minor.patch string for the 1.7.14 version of kubernetes
111111
KubernetesVersion1Dot7Dot14 string = "1.7.14"
112+
// KubernetesVersion1Dot7Dot15 is the major.minor.patch string for the 1.7.15 version of kubernetes
113+
KubernetesVersion1Dot7Dot15 string = "1.7.15"
112114
// KubernetesVersion1Dot6Dot6 is the major.minor.patch string for the 1.6.6 version of kubernetes
113115
KubernetesVersion1Dot6Dot6 string = "1.6.6"
114116
// KubernetesVersion1Dot6Dot9 is the major.minor.patch string for the 1.6.9 version of kubernetes
@@ -141,6 +143,7 @@ var AllKubernetesSupportedVersions = map[string]bool{
141143
KubernetesVersion1Dot7Dot12: true,
142144
KubernetesVersion1Dot7Dot13: true,
143145
KubernetesVersion1Dot7Dot14: true,
146+
KubernetesVersion1Dot7Dot15: true,
144147
KubernetesVersion1Dot8Dot0: true,
145148
KubernetesVersion1Dot8Dot1: true,
146149
KubernetesVersion1Dot8Dot2: true,
@@ -188,6 +191,7 @@ var AllKubernetesWindowsSupportedVersions = map[string]bool{
188191
KubernetesVersion1Dot7Dot12: true,
189192
KubernetesVersion1Dot7Dot13: true,
190193
KubernetesVersion1Dot7Dot14: true,
194+
KubernetesVersion1Dot7Dot15: true,
191195
KubernetesVersion1Dot8Dot0: true,
192196
KubernetesVersion1Dot8Dot1: true,
193197
KubernetesVersion1Dot8Dot2: true,

pkg/api/common/helper_test.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ func Test_GetValidPatchVersion(t *testing.T) {
1414
}
1515

1616
version = GetValidPatchVersion(Kubernetes, "1.7.3")
17-
if version != KubernetesVersion1Dot7Dot14 {
18-
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot14)
17+
if version != KubernetesVersion1Dot7Dot15 {
18+
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot15)
1919
}
2020

2121
version = GetValidPatchVersion(Kubernetes, "1.8.7")
@@ -46,8 +46,8 @@ func TestGetLatestPatchVersion(t *testing.T) {
4646
}
4747

4848
version = GetLatestPatchVersion("1.7", GetAllSupportedKubernetesVersions())
49-
if version != KubernetesVersion1Dot7Dot14 {
50-
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot14)
49+
if version != KubernetesVersion1Dot7Dot15 {
50+
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot15)
5151
}
5252

5353
version = GetLatestPatchVersion("1.8", GetAllSupportedKubernetesVersions())
@@ -94,18 +94,18 @@ func Test_RationalizeReleaseAndVersion(t *testing.T) {
9494
}
9595

9696
version = RationalizeReleaseAndVersion(Kubernetes, "1.7", "", false)
97-
if version != KubernetesVersion1Dot7Dot14 {
98-
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot14)
97+
if version != KubernetesVersion1Dot7Dot15 {
98+
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot15)
9999
}
100100

101101
version = RationalizeReleaseAndVersion(Kubernetes, "", "1.7.14", false)
102102
if version != KubernetesVersion1Dot7Dot14 {
103103
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot14)
104104
}
105105

106-
version = RationalizeReleaseAndVersion(Kubernetes, "1.7", "1.7.14", false)
107-
if version != KubernetesVersion1Dot7Dot14 {
108-
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot14)
106+
version = RationalizeReleaseAndVersion(Kubernetes, "1.7", "1.7.15", false)
107+
if version != KubernetesVersion1Dot7Dot15 {
108+
t.Errorf("It is not Kubernetes version %s", KubernetesVersion1Dot7Dot15)
109109
}
110110

111111
version = RationalizeReleaseAndVersion(Kubernetes, "", "1.6.7", false)

pkg/api/orchestrators_test.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ func TestOrchestratorUpgradeInfo(t *testing.T) {
5757
}
5858
orch, e := GetOrchestratorVersionProfile(csOrch)
5959
Expect(e).To(BeNil())
60-
// 1.6.9, 1.6.11, 1.6.12, 1.6.13, 1.7.0, 1.7.1, 1.7.2, 1.7.4, 1.7.5, 1.7.7, 1.7.9, 1.7.10, 1.7.12, 1.7.13, 1.7.14
61-
Expect(len(orch.Upgrades)).To(Equal(15))
60+
// 1.6.9, 1.6.11, 1.6.12, 1.6.13, 1.7.0, 1.7.1, 1.7.2, 1.7.4, 1.7.5, 1.7.7, 1.7.9, 1.7.10, 1.7.12, 1.7.13, 1.7.14, 1.7.15
61+
Expect(len(orch.Upgrades)).To(Equal(16))
6262

6363
// 1.7.0 is upgradable to 1.7.x and 1.8.x
6464
csOrch = &OrchestratorProfile{
@@ -67,13 +67,13 @@ func TestOrchestratorUpgradeInfo(t *testing.T) {
6767
}
6868
orch, e = GetOrchestratorVersionProfile(csOrch)
6969
Expect(e).To(BeNil())
70-
// 1.7.1, 1.7.2, 1.7.4, 1.7.5, 1.7.7, 1.7.9, 1.7.10, 1.7.12, 1.7.13, 1.7.14, 1.8.0, 1.8.1, 1.8.2, 1.8.4, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.8.10
71-
Expect(len(orch.Upgrades)).To(Equal(19))
70+
// 1.7.1, 1.7.2, 1.7.4, 1.7.5, 1.7.7, 1.7.9, 1.7.10, 1.7.12, 1.7.13, 1.7.14, 1.7.15, 1.8.0, 1.8.1, 1.8.2, 1.8.4, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.8.10
71+
Expect(len(orch.Upgrades)).To(Equal(20))
7272

73-
// 1.7.14 is upgradable to 1.8.x
73+
// 1.7.15 is upgradable to 1.8.x
7474
csOrch = &OrchestratorProfile{
7575
OrchestratorType: Kubernetes,
76-
OrchestratorVersion: "1.7.14",
76+
OrchestratorVersion: "1.7.15",
7777
}
7878
orch, e = GetOrchestratorVersionProfile(csOrch)
7979
Expect(e).To(BeNil())
@@ -121,12 +121,12 @@ func TestOrchestratorUpgradeInfo(t *testing.T) {
121121
// v20170930 - all orchestrators
122122
list, e := GetOrchestratorVersionProfileListV20170930("", "")
123123
Expect(e).To(BeNil())
124-
Expect(len(list.Properties.Orchestrators)).To(Equal(38))
124+
Expect(len(list.Properties.Orchestrators)).To(Equal(39))
125125

126126
// v20170930 - kubernetes only
127127
list, e = GetOrchestratorVersionProfileListV20170930(common.Kubernetes, "")
128128
Expect(e).To(BeNil())
129-
Expect(len(list.Properties.Orchestrators)).To(Equal(33))
129+
Expect(len(list.Properties.Orchestrators)).To(Equal(34))
130130
}
131131

132132
func TestKubernetesInfo(t *testing.T) {

pkg/api/vlabs/validate.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -535,6 +535,7 @@ func (a *KubernetesConfig) Validate(k8sVersion string) error {
535535
common.KubernetesVersion1Dot7Dot12: true,
536536
common.KubernetesVersion1Dot7Dot13: true,
537537
common.KubernetesVersion1Dot7Dot14: true,
538+
common.KubernetesVersion1Dot7Dot15: true,
538539
common.KubernetesVersion1Dot6Dot6: true,
539540
common.KubernetesVersion1Dot6Dot9: true,
540541
common.KubernetesVersion1Dot6Dot11: true,

pkg/api/vlabs/validate_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -580,15 +580,15 @@ func TestWindowsVersions(t *testing.T) {
580580
}
581581

582582
p = getK8sDefaultProperties(true)
583-
p.OrchestratorProfile.OrchestratorVersion = "1.7.14"
583+
p.OrchestratorProfile.OrchestratorVersion = "1.7.15"
584584
if err := p.Validate(false); err != nil {
585585
t.Errorf(
586586
"should not error on valid Windows version: %v", err,
587587
)
588588
}
589589

590590
p = getK8sDefaultProperties(true)
591-
p.OrchestratorProfile.OrchestratorVersion = "1.7.15"
591+
p.OrchestratorProfile.OrchestratorVersion = "1.7.16"
592592
if err := p.Validate(false); err == nil {
593593
t.Errorf(
594594
"should error on invalid Windows version",
@@ -678,15 +678,15 @@ func TestLinuxVersions(t *testing.T) {
678678
}
679679

680680
p = getK8sDefaultProperties(false)
681-
p.OrchestratorProfile.OrchestratorVersion = "1.7.14"
681+
p.OrchestratorProfile.OrchestratorVersion = "1.7.15"
682682
if err := p.Validate(false); err != nil {
683683
t.Errorf(
684684
"should not error on valid Linux version: %v", err,
685685
)
686686
}
687687

688688
p = getK8sDefaultProperties(false)
689-
p.OrchestratorProfile.OrchestratorVersion = "1.7.15"
689+
p.OrchestratorProfile.OrchestratorVersion = "1.7.16"
690690
if err := p.Validate(false); err == nil {
691691
t.Errorf(
692692
"should error on invalid Linux version",

0 commit comments

Comments
 (0)