From b75e8de59669eaec0f17caf77186447014528d8b Mon Sep 17 00:00:00 2001 From: Jakub Al-Khalili Date: Fri, 22 Nov 2019 15:40:00 +0100 Subject: [PATCH] Quick fix ports in jenkins.go This bug makes it impossible to use NodePort instead of port. --- pkg/controller/jenkins/client/jenkins.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/controller/jenkins/client/jenkins.go b/pkg/controller/jenkins/client/jenkins.go index 802850d8..c8ae39d1 100644 --- a/pkg/controller/jenkins/client/jenkins.go +++ b/pkg/controller/jenkins/client/jenkins.go @@ -99,7 +99,7 @@ func (j JenkinsAPIConnectionSettings) BuildJenkinsAPIUrl(serviceName string, ser // Validate validates jenkins API connection settings func (j JenkinsAPIConnectionSettings) Validate() error { - if j.Port >= 0 && j.UseNodePort { + if j.Port > 0 && j.UseNodePort { return errors.New("can't use service port and nodePort both. Please use port or nodePort") }