Only support SSL dynamic mode

This commit is contained in:
Manuel Alejandro de Brito Fontes 2019-08-13 17:14:55 -04:00
parent 333d9fd48d
commit 80bd481abb
No known key found for this signature in database
GPG key ID: 786136016A8BA02A
40 changed files with 415 additions and 709 deletions

View file

@ -165,6 +165,23 @@ func (f *Framework) GetNginxIP() string {
return s.Spec.ClusterIP
}
// GetNginxPodIP returns the IP addres/es of the running pods
func (f *Framework) GetNginxPodIP() []string {
e, err := f.KubeClientSet.
CoreV1().
Endpoints(f.Namespace).
Get("ingress-nginx", metav1.GetOptions{})
Expect(err).NotTo(HaveOccurred(), "unexpected error obtaning NGINX IP address")
eips := make([]string, 0)
for _, s := range e.Subsets {
for _, a := range s.Addresses {
eips = append(eips, a.IP)
}
}
return eips
}
// GetURL returns the URL should be used to make a request to NGINX
func (f *Framework) GetURL(scheme RequestScheme) string {
ip := f.GetNginxIP()