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

Commit

Permalink
Adding test for and fixing daemonsets that should not run on Windows (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
PatrickLang authored and jackfrancis committed Jul 4, 2018
1 parent 3d7ac0e commit 09351bb
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 1 deletion.
2 changes: 2 additions & 0 deletions parts/k8s/addons/azure-cni-networkmonitor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ spec:
tolerations:
- key: CriticalAddonsOnly
operator: Exists
nodeSelector:
beta.kubernetes.io/os: linux
containers:
- name: azure-cnms
image: <azureCNINetworkMonitorImage>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ spec:
tolerations:
- key: CriticalAddonsOnly
operator: Exists
nodeSelector:
beta.kubernetes.io/os: linux
containers:
- name: azure-npm
image: containernetworking/azure-npm:v0.0.3
Expand Down Expand Up @@ -98,4 +100,4 @@ spec:
hostPath:
path: /run/xtables.lock
type: File
serviceAccountName: azure-npm
serviceAccountName: azure-npm
2 changes: 2 additions & 0 deletions parts/k8s/addons/kubernetesmasteraddons-calico-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,8 @@ spec:
scheduler.alpha.kubernetes.io/critical-pod: ''
spec:
hostNetwork: true
nodeSelector:
beta.kubernetes.io/os: linux
tolerations:
- key: CriticalAddonsOnly
operator: Exists
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ spec:
hostNetwork: true
nodeSelector:
beta.kubernetes.io/arch: amd64
beta.kubernetes.io/os: linux
tolerations:
- key: node-role.kubernetes.io/master
operator: Equal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ spec:
annotations:
scheduler.alpha.kubernetes.io/critical-pod: ''
spec:
nodeSelector:
beta.kubernetes.io/os: linux
containers:
- image: <kubernetesReschedulerSpec>
name: rescheduler
Expand Down
14 changes: 14 additions & 0 deletions test/e2e/kubernetes/kubernetes_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -777,6 +777,20 @@ var _ = Describe("Azure Container Cluster using the Kubernetes Orchestrator", fu
}
})

It("Should not have any unready or crashing pods right after deployment", func() {
if eng.HasWindowsAgents() {
By("Checking ready status of each pod in kube-system")
pods, err := pod.GetAll("kube-system")
Expect(err).NotTo(HaveOccurred())
Expect(len(pods.Pods)).ToNot(BeZero())
for _, currentPod := range pods.Pods {
log.Printf("Checking %s", currentPod.Metadata.Name)
Expect(currentPod.Status.ContainerStatuses[0].Ready).To(BeTrue())
Expect(currentPod.Status.ContainerStatuses[0].RestartCount).To(BeNumerically("<", 3))
}
}
})

// Windows Bug 16598869
/*
It("should be able to reach hostport in an iis webserver", func() {
Expand Down

0 comments on commit 09351bb

Please sign in to comment.