diff options
| -rw-r--r-- | app/models/project_services/bamboo_service.rb | 6 | ||||
| -rw-r--r-- | app/models/project_services/teamcity_service.rb | 8 |
2 files changed, 1 insertions, 13 deletions
diff --git a/app/models/project_services/bamboo_service.rb b/app/models/project_services/bamboo_service.rb index 7442f797ca9..b5c76e4d4fe 100644 --- a/app/models/project_services/bamboo_service.rb +++ b/app/models/project_services/bamboo_service.rb @@ -1,6 +1,4 @@ class BambooService < CiService - include HTTParty - prop_accessor :bamboo_url, :build_key, :username, :password validates :bamboo_url, presence: true, url: true, if: :activated? @@ -107,10 +105,6 @@ class BambooService < CiService private def build_url(path) - # URI.join only works correctly, if the bamboo_url has - # - at least one or more trailing '/' - # - the appended parts are not prefixed with '/' - # otherwise a bamboo_url 'http://foo.bar/bamboo' will break URI.join("#{bamboo_url}/", path).to_s end diff --git a/app/models/project_services/teamcity_service.rb b/app/models/project_services/teamcity_service.rb index 42fe8e63cc7..a4a967c9bc9 100644 --- a/app/models/project_services/teamcity_service.rb +++ b/app/models/project_services/teamcity_service.rb @@ -1,6 +1,4 @@ class TeamcityService < CiService - include HTTParty - prop_accessor :teamcity_url, :build_type, :username, :password validates :teamcity_url, presence: true, url: true, if: :activated? @@ -112,7 +110,7 @@ class TeamcityService < CiService branch = Gitlab::Git.ref_name(data[:ref]) - self.class.post( + HTTParty.post( build_url('httpAuth/app/rest/buildQueue'), body: "<build branchName=\"#{branch}\">"\ "<buildType id=\"#{build_type}\"/>"\ @@ -125,10 +123,6 @@ class TeamcityService < CiService private def build_url(path) - # URI.join only works correctly, if the teamcity_url has - # - at least one or more trailing '/' - # - the appended parts are not prefixed with '/' - # otherwise a teamcity_url 'http://foo.bar/teamcity' will break URI.join("#{teamcity_url}/", path).to_s end |
