mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 03:41:45 +00:00
Replace Beta OS/arch labels with the GA ones
Beta OS/arch labels have been deprecated since 1.14. This change replaces these labels with the GA ones.
This commit is contained in:
parent
a70e574955
commit
bcd975aa65
@ -63,7 +63,7 @@ spec:
|
|||||||
emptyDir: {}
|
emptyDir: {}
|
||||||
serviceAccountName: kubernetes-dashboard
|
serviceAccountName: kubernetes-dashboard
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
"beta.kubernetes.io/os": linux
|
"kubernetes.io/os": linux
|
||||||
tolerations:
|
tolerations:
|
||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
|
@ -106,5 +106,5 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
serviceAccountName: kube-dns-autoscaler
|
serviceAccountName: kube-dns-autoscaler
|
||||||
|
@ -115,7 +115,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
containers:
|
containers:
|
||||||
- name: coredns
|
- name: coredns
|
||||||
image: k8s.gcr.io/coredns:1.6.5
|
image: k8s.gcr.io/coredns:1.6.5
|
||||||
|
@ -115,7 +115,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
containers:
|
containers:
|
||||||
- name: coredns
|
- name: coredns
|
||||||
image: k8s.gcr.io/coredns:1.6.5
|
image: k8s.gcr.io/coredns:1.6.5
|
||||||
|
@ -115,7 +115,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
containers:
|
containers:
|
||||||
- name: coredns
|
- name: coredns
|
||||||
image: k8s.gcr.io/coredns:1.6.5
|
image: k8s.gcr.io/coredns:1.6.5
|
||||||
|
@ -94,7 +94,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
volumes:
|
volumes:
|
||||||
- name: kube-dns-config
|
- name: kube-dns-config
|
||||||
configMap:
|
configMap:
|
||||||
|
@ -94,7 +94,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
volumes:
|
volumes:
|
||||||
- name: kube-dns-config
|
- name: kube-dns-config
|
||||||
configMap:
|
configMap:
|
||||||
|
@ -94,7 +94,7 @@ spec:
|
|||||||
- key: "CriticalAddonsOnly"
|
- key: "CriticalAddonsOnly"
|
||||||
operator: "Exists"
|
operator: "Exists"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
volumes:
|
volumes:
|
||||||
- name: kube-dns-config
|
- name: kube-dns-config
|
||||||
configMap:
|
configMap:
|
||||||
|
@ -98,7 +98,7 @@ spec:
|
|||||||
fieldPath: metadata.namespace
|
fieldPath: metadata.namespace
|
||||||
# END_PROMETHEUS_TO_SD
|
# END_PROMETHEUS_TO_SD
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
terminationGracePeriodSeconds: 60
|
terminationGracePeriodSeconds: 60
|
||||||
tolerations:
|
tolerations:
|
||||||
- operator: "Exists"
|
- operator: "Exists"
|
||||||
|
@ -25,7 +25,7 @@ spec:
|
|||||||
priorityClassName: system-node-critical
|
priorityClassName: system-node-critical
|
||||||
hostNetwork: true
|
hostNetwork: true
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
node.kubernetes.io/kube-proxy-ds-ready: "true"
|
node.kubernetes.io/kube-proxy-ds-ready: "true"
|
||||||
tolerations:
|
tolerations:
|
||||||
- operator: "Exists"
|
- operator: "Exists"
|
||||||
|
@ -84,5 +84,5 @@ spec:
|
|||||||
# END_PROMETHEUS_TO_SD
|
# END_PROMETHEUS_TO_SD
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
cloud.google.com/metadata-proxy-ready: "true"
|
cloud.google.com/metadata-proxy-ready: "true"
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
terminationGracePeriodSeconds: 30
|
terminationGracePeriodSeconds: 30
|
||||||
|
@ -45,13 +45,13 @@ output_file=/tmp/k8s-smoke-test.out
|
|||||||
|
|
||||||
function check_windows_nodes_are_ready {
|
function check_windows_nodes_are_ready {
|
||||||
# kubectl filtering is the worst.
|
# kubectl filtering is the worst.
|
||||||
statuses=$(${kubectl} get nodes -l beta.kubernetes.io/os=windows \
|
statuses=$(${kubectl} get nodes -l kubernetes.io/os=windows \
|
||||||
-o jsonpath='{.items[*].status.conditions[?(@.type=="Ready")].status}')
|
-o jsonpath='{.items[*].status.conditions[?(@.type=="Ready")].status}')
|
||||||
for status in $statuses; do
|
for status in $statuses; do
|
||||||
if [[ $status == "False" ]]; then
|
if [[ $status == "False" ]]; then
|
||||||
echo "ERROR: some Windows node has status != Ready"
|
echo "ERROR: some Windows node has status != Ready"
|
||||||
echo "kubectl get nodes -l beta.kubernetes.io/os=windows"
|
echo "kubectl get nodes -l kubernetes.io/os=windows"
|
||||||
${kubectl} get nodes -l beta.kubernetes.io/os=windows
|
${kubectl} get nodes -l kubernetes.io/os=windows
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -61,7 +61,7 @@ function check_windows_nodes_are_ready {
|
|||||||
function untaint_windows_nodes {
|
function untaint_windows_nodes {
|
||||||
# Untaint the windows nodes to allow test workloads without tolerations to be
|
# Untaint the windows nodes to allow test workloads without tolerations to be
|
||||||
# scheduled onto them.
|
# scheduled onto them.
|
||||||
WINDOWS_NODES=$(${kubectl} get nodes -l beta.kubernetes.io/os=windows -o name)
|
WINDOWS_NODES=$(${kubectl} get nodes -l kubernetes.io/os=windows -o name)
|
||||||
for node in $WINDOWS_NODES; do
|
for node in $WINDOWS_NODES; do
|
||||||
${kubectl} taint node "$node" node.kubernetes.io/os:NoSchedule-
|
${kubectl} taint node "$node" node.kubernetes.io/os:NoSchedule-
|
||||||
done
|
done
|
||||||
@ -106,7 +106,7 @@ spec:
|
|||||||
- name: nginx
|
- name: nginx
|
||||||
image: nginx:1.7.9
|
image: nginx:1.7.9
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
if ! ${kubectl} create -f $linux_webserver_deployment.yaml; then
|
if ! ${kubectl} create -f $linux_webserver_deployment.yaml; then
|
||||||
@ -183,7 +183,7 @@ spec:
|
|||||||
image: ubuntu
|
image: ubuntu
|
||||||
command: ["sleep", "123456"]
|
command: ["sleep", "123456"]
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
if ! ${kubectl} create -f $linux_command_deployment.yaml; then
|
if ! ${kubectl} create -f $linux_command_deployment.yaml; then
|
||||||
@ -280,7 +280,7 @@ spec:
|
|||||||
args:
|
args:
|
||||||
- serve-hostname
|
- serve-hostname
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: windows
|
kubernetes.io/os: windows
|
||||||
tolerations:
|
tolerations:
|
||||||
- effect: NoSchedule
|
- effect: NoSchedule
|
||||||
key: node.kubernetes.io/os
|
key: node.kubernetes.io/os
|
||||||
@ -360,7 +360,7 @@ spec:
|
|||||||
- name: pause-win
|
- name: pause-win
|
||||||
image: gcr.io/gke-release/pause-win:1.1.0
|
image: gcr.io/gke-release/pause-win:1.1.0
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: windows
|
kubernetes.io/os: windows
|
||||||
tolerations:
|
tolerations:
|
||||||
- effect: NoSchedule
|
- effect: NoSchedule
|
||||||
key: node.kubernetes.io/os
|
key: node.kubernetes.io/os
|
||||||
|
@ -241,7 +241,7 @@ spec:
|
|||||||
- key: {{ .ControlPlaneTaintKey }}
|
- key: {{ .ControlPlaneTaintKey }}
|
||||||
effect: NoSchedule
|
effect: NoSchedule
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
containers:
|
containers:
|
||||||
- name: coredns
|
- name: coredns
|
||||||
image: {{ .Image }}
|
image: {{ .Image }}
|
||||||
|
@ -113,6 +113,6 @@ spec:
|
|||||||
operator: Exists
|
operator: Exists
|
||||||
- operator: Exists
|
- operator: Exists
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
`
|
`
|
||||||
)
|
)
|
||||||
|
@ -7,10 +7,10 @@ metadata:
|
|||||||
volumes.kubernetes.io/controller-managed-attach-detach: "true"
|
volumes.kubernetes.io/controller-managed-attach-detach: "true"
|
||||||
creationTimestamp: "2019-07-09T16:17:29Z"
|
creationTimestamp: "2019-07-09T16:17:29Z"
|
||||||
labels:
|
labels:
|
||||||
beta.kubernetes.io/arch: amd64
|
kubernetes.io/arch: amd64
|
||||||
beta.kubernetes.io/fluentd-ds-ready: "true"
|
beta.kubernetes.io/fluentd-ds-ready: "true"
|
||||||
beta.kubernetes.io/instance-type: n1-standard-4
|
beta.kubernetes.io/instance-type: n1-standard-4
|
||||||
beta.kubernetes.io/os: linux
|
kubernetes.io/os: linux
|
||||||
cloud.google.com/gke-nodepool: default-pool
|
cloud.google.com/gke-nodepool: default-pool
|
||||||
cloud.google.com/gke-os-distribution: cos
|
cloud.google.com/gke-os-distribution: cos
|
||||||
failure-domain.beta.kubernetes.io/region: us-central1
|
failure-domain.beta.kubernetes.io/region: us-central1
|
||||||
|
@ -1319,7 +1319,7 @@ func (g *gcePdDriver) PrepareTest(f *framework.Framework) (*testsuites.PerTestCo
|
|||||||
if framework.NodeOSDistroIs("windows") {
|
if framework.NodeOSDistroIs("windows") {
|
||||||
config.ClientNodeSelection = e2epod.NodeSelection{
|
config.ClientNodeSelection = e2epod.NodeSelection{
|
||||||
Selector: map[string]string{
|
Selector: map[string]string{
|
||||||
"beta.kubernetes.io/os": "windows",
|
"kubernetes.io/os": "windows",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1716,7 +1716,7 @@ func (a *awsDriver) PrepareTest(f *framework.Framework) (*testsuites.PerTestConf
|
|||||||
if framework.NodeOSDistroIs("windows") {
|
if framework.NodeOSDistroIs("windows") {
|
||||||
config.ClientNodeSelection = e2epod.NodeSelection{
|
config.ClientNodeSelection = e2epod.NodeSelection{
|
||||||
Selector: map[string]string{
|
Selector: map[string]string{
|
||||||
"beta.kubernetes.io/os": "windows",
|
"kubernetes.io/os": "windows",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -236,7 +236,7 @@ func newDensityTestPods(numPods int, volume bool, imageName, podType string) []*
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
NodeSelector: map[string]string{
|
NodeSelector: map[string]string{
|
||||||
"beta.kubernetes.io/os": "windows",
|
"kubernetes.io/os": "windows",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -117,7 +117,7 @@ func createTestPod(f *framework.Framework, image string, os string) *v1.Pod {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
NodeSelector: map[string]string{
|
NodeSelector: map[string]string{
|
||||||
"beta.kubernetes.io/os": os,
|
"kubernetes.io/os": os,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -168,7 +168,7 @@ func newMemLimitTestPods(numPods int, imageName, podType string, memoryLimit str
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
NodeSelector: map[string]string{
|
NodeSelector: map[string]string{
|
||||||
"beta.kubernetes.io/os": "windows",
|
"kubernetes.io/os": "windows",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@ -181,7 +181,7 @@ func newMemLimitTestPods(numPods int, imageName, podType string, memoryLimit str
|
|||||||
|
|
||||||
// getNodeMemory populates a nodeMemory struct with information from the first
|
// getNodeMemory populates a nodeMemory struct with information from the first
|
||||||
func getNodeMemory(f *framework.Framework) nodeMemory {
|
func getNodeMemory(f *framework.Framework) nodeMemory {
|
||||||
selector := labels.Set{"beta.kubernetes.io/os": "windows"}.AsSelector()
|
selector := labels.Set{"kubernetes.io/os": "windows"}.AsSelector()
|
||||||
nodeList, err := f.ClientSet.CoreV1().Nodes().List(context.TODO(), metav1.ListOptions{
|
nodeList, err := f.ClientSet.CoreV1().Nodes().List(context.TODO(), metav1.ListOptions{
|
||||||
LabelSelector: selector.String(),
|
LabelSelector: selector.String(),
|
||||||
})
|
})
|
||||||
@ -232,7 +232,7 @@ func getNodeMemory(f *framework.Framework) nodeMemory {
|
|||||||
|
|
||||||
// getTotalAllocatableMemory gets the sum of all agent node's allocatable memory
|
// getTotalAllocatableMemory gets the sum of all agent node's allocatable memory
|
||||||
func getTotalAllocatableMemory(f *framework.Framework) *resource.Quantity {
|
func getTotalAllocatableMemory(f *framework.Framework) *resource.Quantity {
|
||||||
selector := labels.Set{"beta.kubernetes.io/os": "windows"}.AsSelector()
|
selector := labels.Set{"kubernetes.io/os": "windows"}.AsSelector()
|
||||||
nodeList, err := f.ClientSet.CoreV1().Nodes().List(context.TODO(), metav1.ListOptions{
|
nodeList, err := f.ClientSet.CoreV1().Nodes().List(context.TODO(), metav1.ListOptions{
|
||||||
LabelSelector: selector.String(),
|
LabelSelector: selector.String(),
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user