mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-03 09:22:44 +00:00
Merge pull request #2446 from erictune/secure_port_on
Treat unset KUBERNETES_PROVIDER as gce.
This commit is contained in:
commit
218c5fb93c
@ -172,14 +172,13 @@ func TestPodUpdate(c *client.Client) bool {
|
|||||||
// TestKubeletSendsEvent checks that kubelets and scheduler send events about pods scheduling and running.
|
// TestKubeletSendsEvent checks that kubelets and scheduler send events about pods scheduling and running.
|
||||||
func TestKubeletSendsEvent(c *client.Client) bool {
|
func TestKubeletSendsEvent(c *client.Client) bool {
|
||||||
provider := os.Getenv("KUBERNETES_PROVIDER")
|
provider := os.Getenv("KUBERNETES_PROVIDER")
|
||||||
if provider == "" {
|
|
||||||
glog.Errorf("unable to detect cloud type.")
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if provider != "gce" {
|
if provider != "gce" {
|
||||||
glog.Infof("skipping TestKubeletSendsEvent on cloud provider %s", provider)
|
glog.Infof("skipping TestKubeletSendsEvent on cloud provider %s", provider)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
if provider == "" {
|
||||||
|
glog.Info("KUBERNETES_PROVIDER is unset assuming \"gce\"")
|
||||||
|
}
|
||||||
|
|
||||||
podClient := c.Pods(api.NamespaceDefault)
|
podClient := c.Pods(api.NamespaceDefault)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user