Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
8d8b4759
Commit
8d8b4759
authored
May 24, 2018
by
Sandeep Rajan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update manifest
fix test
parent
10b8665a
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
44 additions
and
20 deletions
+44
-20
coredns.yaml.base
cluster/addons/dns/coredns.yaml.base
+7
-1
coredns.yaml.in
cluster/addons/dns/coredns.yaml.in
+7
-1
coredns.yaml.sed
cluster/addons/dns/coredns.yaml.sed
+7
-1
manifests.go
cmd/kubeadm/app/phases/addons/dns/manifests.go
+6
-0
versions.go
cmd/kubeadm/app/phases/addons/dns/versions.go
+3
-3
compute_test.go
cmd/kubeadm/app/phases/upgrade/compute_test.go
+14
-14
No files found.
cluster/addons/dns/coredns.yaml.base
View file @
8d8b4759
...
@@ -66,6 +66,7 @@ data:
...
@@ -66,6 +66,7 @@ data:
prometheus :9153
prometheus :9153
proxy . /etc/resolv.conf
proxy . /etc/resolv.conf
cache 30
cache 30
reload
}
}
---
---
apiVersion: extensions/v1beta1
apiVersion: extensions/v1beta1
...
@@ -103,7 +104,7 @@ spec:
...
@@ -103,7 +104,7 @@ spec:
operator: "Exists"
operator: "Exists"
containers:
containers:
- name: coredns
- name: coredns
image: coredns/coredns:1.
0.6
image: coredns/coredns:1.
1.3
imagePullPolicy: IfNotPresent
imagePullPolicy: IfNotPresent
resources:
resources:
limits:
limits:
...
@@ -122,6 +123,9 @@ spec:
...
@@ -122,6 +123,9 @@ spec:
- containerPort: 53
- containerPort: 53
name: dns-tcp
name: dns-tcp
protocol: TCP
protocol: TCP
- containerPort: 9153
name: metrics
protocol: TCP
livenessProbe:
livenessProbe:
httpGet:
httpGet:
path: /health
path: /health
...
@@ -145,6 +149,8 @@ kind: Service
...
@@ -145,6 +149,8 @@ kind: Service
metadata:
metadata:
name: kube-dns
name: kube-dns
namespace: kube-system
namespace: kube-system
annotations:
prometheus.io/scrape: "true"
labels:
labels:
k8s-app: kube-dns
k8s-app: kube-dns
kubernetes.io/cluster-service: "true"
kubernetes.io/cluster-service: "true"
...
...
cluster/addons/dns/coredns.yaml.in
View file @
8d8b4759
...
@@ -66,6 +66,7 @@ data:
...
@@ -66,6 +66,7 @@ data:
prometheus :9153
prometheus :9153
proxy . /etc/resolv.conf
proxy . /etc/resolv.conf
cache 30
cache 30
reload
}
}
---
---
apiVersion: extensions/v1beta1
apiVersion: extensions/v1beta1
...
@@ -103,7 +104,7 @@ spec:
...
@@ -103,7 +104,7 @@ spec:
operator: "Exists"
operator: "Exists"
containers:
containers:
- name: coredns
- name: coredns
image: coredns/coredns:1.
0.6
image: coredns/coredns:1.
1.3
imagePullPolicy: IfNotPresent
imagePullPolicy: IfNotPresent
resources:
resources:
limits:
limits:
...
@@ -122,6 +123,9 @@ spec:
...
@@ -122,6 +123,9 @@ spec:
- containerPort: 53
- containerPort: 53
name: dns-tcp
name: dns-tcp
protocol: TCP
protocol: TCP
- containerPort: 9153
name: metrics
protocol: TCP
livenessProbe:
livenessProbe:
httpGet:
httpGet:
path: /health
path: /health
...
@@ -145,6 +149,8 @@ kind: Service
...
@@ -145,6 +149,8 @@ kind: Service
metadata:
metadata:
name: kube-dns
name: kube-dns
namespace: kube-system
namespace: kube-system
annotations:
prometheus.io/scrape: "true"
labels:
labels:
k8s-app: kube-dns
k8s-app: kube-dns
kubernetes.io/cluster-service: "true"
kubernetes.io/cluster-service: "true"
...
...
cluster/addons/dns/coredns.yaml.sed
View file @
8d8b4759
...
@@ -66,6 +66,7 @@ data:
...
@@ -66,6 +66,7 @@ data:
prometheus :9153
prometheus :9153
prox
y
.
/et
c
/resolv.conf
prox
y
.
/et
c
/resolv.conf
c
ache 30
c
ache 30
re
l
o
a
d
}
}
---
---
a
piVersion: extensions/v1beta1
a
piVersion: extensions/v1beta1
...
@@ -103,7 +104,7 @@ spec:
...
@@ -103,7 +104,7 @@ spec:
o
p
er
a
tor: "Exists"
o
p
er
a
tor: "Exists"
c
ontainers:
c
ontainers:
-
na
me: coredns
-
na
me: coredns
i
mage: coredns/coredns:1.
0.6
i
mage: coredns/coredns:1.
1.3
i
magePullPolicy: IfNotPresent
i
magePullPolicy: IfNotPresent
re
s
o
urces:
re
s
o
urces:
limits:
limits:
...
@@ -122,6 +123,9 @@ spec:
...
@@ -122,6 +123,9 @@ spec:
- containerPort: 53
- containerPort: 53
na
me: dns-tcp
na
me: dns-tcp
p
roto
c
ol: TCP
p
roto
c
ol: TCP
-
c
ontainerPort: 9153
na
me: metrics
p
roto
c
ol: TCP
li
venessProbe:
li
venessProbe:
h
tt
pG
et
:
h
tt
pG
et
:
path:
/
h
e
a
lth
path:
/
h
e
a
lth
...
@@ -145,6 +149,8 @@ kind: Service
...
@@ -145,6 +149,8 @@ kind: Service
metadata:
metadata:
name: kube-dns
name: kube-dns
namespace: kube-system
namespace: kube-system
annotations:
prometheus
.
io/scrape: "true"
labels:
labels:
k8s-app: kube-dns
k8s-app: kube-dns
kubernetes
.
io/cluster-service: "true"
kubernetes
.
io/cluster-service: "true"
...
...
cmd/kubeadm/app/phases/addons/dns/manifests.go
View file @
8d8b4759
...
@@ -196,6 +196,8 @@ metadata:
...
@@ -196,6 +196,8 @@ metadata:
kubernetes.io/name: "KubeDNS"
kubernetes.io/name: "KubeDNS"
name: kube-dns
name: kube-dns
namespace: kube-system
namespace: kube-system
annotations:
prometheus.io/scrape: "true"
# Without this resourceVersion value, an update of the Service between versions will yield:
# Without this resourceVersion value, an update of the Service between versions will yield:
# Service "kube-dns" is invalid: metadata.resourceVersion: Invalid value: "": must be specified for an update
# Service "kube-dns" is invalid: metadata.resourceVersion: Invalid value: "": must be specified for an update
resourceVersion: "0"
resourceVersion: "0"
...
@@ -264,6 +266,9 @@ spec:
...
@@ -264,6 +266,9 @@ spec:
- containerPort: 53
- containerPort: 53
name: dns-tcp
name: dns-tcp
protocol: TCP
protocol: TCP
- containerPort: 9153
name: metrics
protocol: TCP
livenessProbe:
livenessProbe:
httpGet:
httpGet:
path: /health
path: /health
...
@@ -303,6 +308,7 @@ data:
...
@@ -303,6 +308,7 @@ data:
prometheus :9153
prometheus :9153
proxy . {{ .UpstreamNameserver }}
proxy . {{ .UpstreamNameserver }}
cache 30
cache 30
reload
}{{ .StubDomain }}
}{{ .StubDomain }}
`
`
// CoreDNSClusterRole is the CoreDNS ClusterRole manifest
// CoreDNSClusterRole is the CoreDNS ClusterRole manifest
...
...
cmd/kubeadm/app/phases/addons/dns/versions.go
View file @
8d8b4759
...
@@ -23,13 +23,13 @@ import (
...
@@ -23,13 +23,13 @@ import (
const
(
const
(
kubeDNSVersion
=
"1.14.10"
kubeDNSVersion
=
"1.14.10"
coreDNSVersion
=
"1.
0.6
"
coreDNSVersion
=
"1.
1.3
"
)
)
// GetDNSVersion returns the right kube-dns version for a specific k8s version
// GetDNSVersion returns the right kube-dns version for a specific k8s version
func
GetDNSVersion
(
kubeVersion
*
version
.
Version
,
dns
string
)
string
{
func
GetDNSVersion
(
kubeVersion
*
version
.
Version
,
dns
string
)
string
{
// v1.9.0+ uses kube-dns 1.14.10
// v1.9.0+ uses kube-dns 1.14.10
, if feature gate "CoreDNS" is disabled.
// v1.9.0+ uses CoreDNS 1.
0.6 if feature gate "CoreDNS" is enabled
.
// v1.9.0+ uses CoreDNS 1.
1.3
.
// In the future when the version is bumped at HEAD; add conditional logic to return the right versions
// In the future when the version is bumped at HEAD; add conditional logic to return the right versions
// Also, the version might be bumped for different k8s releases on the same branch
// Also, the version might be bumped for different k8s releases on the same branch
...
...
cmd/kubeadm/app/phases/upgrade/compute_test.go
View file @
8d8b4759
...
@@ -168,7 +168,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -168,7 +168,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.10.3"
,
KubeVersion
:
"v1.10.3"
,
KubeadmVersion
:
"v1.10.3"
,
KubeadmVersion
:
"v1.10.3"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.1.12"
,
EtcdVersion
:
"3.1.12"
,
},
},
},
},
...
@@ -207,7 +207,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -207,7 +207,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.10.3"
,
KubeVersion
:
"v1.10.3"
,
KubeadmVersion
:
"v1.10.3"
,
KubeadmVersion
:
"v1.10.3"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.1.12"
,
EtcdVersion
:
"3.1.12"
,
},
},
},
},
...
@@ -246,7 +246,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -246,7 +246,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0"
,
KubeVersion
:
"v1.11.0"
,
KubeadmVersion
:
"v1.11.0"
,
KubeadmVersion
:
"v1.11.0"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -285,7 +285,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -285,7 +285,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.10.5"
,
KubeVersion
:
"v1.10.5"
,
KubeadmVersion
:
"v1.10.5"
,
// Note: The kubeadm version mustn't be "downgraded" here
KubeadmVersion
:
"v1.10.5"
,
// Note: The kubeadm version mustn't be "downgraded" here
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.1.12"
,
EtcdVersion
:
"3.1.12"
,
},
},
},
},
...
@@ -305,7 +305,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -305,7 +305,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.1"
,
KubeVersion
:
"v1.11.1"
,
KubeadmVersion
:
"v1.11.1"
,
KubeadmVersion
:
"v1.11.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -364,7 +364,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -364,7 +364,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0-alpha.2"
,
KubeVersion
:
"v1.11.0-alpha.2"
,
KubeadmVersion
:
"v1.11.0-alpha.2"
,
KubeadmVersion
:
"v1.11.0-alpha.2"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -404,7 +404,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -404,7 +404,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0-alpha.2"
,
KubeVersion
:
"v1.11.0-alpha.2"
,
KubeadmVersion
:
"v1.11.0-alpha.2"
,
KubeadmVersion
:
"v1.11.0-alpha.2"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -445,7 +445,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -445,7 +445,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0-beta.1"
,
KubeVersion
:
"v1.11.0-beta.1"
,
KubeadmVersion
:
"v1.11.0-beta.1"
,
KubeadmVersion
:
"v1.11.0-beta.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -486,7 +486,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -486,7 +486,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0-rc.1"
,
KubeVersion
:
"v1.11.0-rc.1"
,
KubeadmVersion
:
"v1.11.0-rc.1"
,
KubeadmVersion
:
"v1.11.0-rc.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -527,7 +527,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -527,7 +527,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.6-rc.1"
,
KubeVersion
:
"v1.11.6-rc.1"
,
KubeadmVersion
:
"v1.11.6-rc.1"
,
KubeadmVersion
:
"v1.11.6-rc.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -568,7 +568,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -568,7 +568,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.11.0-rc.1"
,
KubeVersion
:
"v1.11.0-rc.1"
,
KubeadmVersion
:
"v1.11.0-rc.1"
,
KubeadmVersion
:
"v1.11.0-rc.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -588,7 +588,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -588,7 +588,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.12.0-alpha.2"
,
KubeVersion
:
"v1.12.0-alpha.2"
,
KubeadmVersion
:
"v1.12.0-alpha.2"
,
KubeadmVersion
:
"v1.12.0-alpha.2"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -641,7 +641,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -641,7 +641,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.12.1"
,
KubeVersion
:
"v1.12.1"
,
KubeadmVersion
:
"v1.12.1"
,
KubeadmVersion
:
"v1.12.1"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
@@ -678,7 +678,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
...
@@ -678,7 +678,7 @@ func TestGetAvailableUpgrades(t *testing.T) {
KubeVersion
:
"v1.12.0"
,
KubeVersion
:
"v1.12.0"
,
KubeadmVersion
:
"v1.12.0"
,
KubeadmVersion
:
"v1.12.0"
,
DNSType
:
"coredns"
,
DNSType
:
"coredns"
,
DNSVersion
:
"1.
0.6
"
,
DNSVersion
:
"1.
1.3
"
,
EtcdVersion
:
"3.2.18"
,
EtcdVersion
:
"3.2.18"
,
},
},
},
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment