summaryrefslogtreecommitdiff
path: root/app/services/ci
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2017-05-24 15:13:51 +0200
committerKamil Trzcinski <ayufan@ayufan.eu>2017-05-31 14:17:49 +0200
commit161af17c1b69e7e00aefcd4f540a55755259ceda (patch)
tree6a2c94a350a2fa53e05f07927df543ed3ba1a7bc /app/services/ci
parent19ee16a0f85dd4bacddbd066237e62a1bbb7113a (diff)
downloadgitlab-ce-161af17c1b69e7e00aefcd4f540a55755259ceda.tar.gz
Introduce source to pipeline entitytrigger-source
Diffstat (limited to 'app/services/ci')
-rw-r--r--app/services/ci/create_pipeline_service.rb3
-rw-r--r--app/services/ci/create_trigger_request_service.rb2
2 files changed, 3 insertions, 2 deletions
diff --git a/app/services/ci/create_pipeline_service.rb b/app/services/ci/create_pipeline_service.rb
index a98b7167765..8227a78a650 100644
--- a/app/services/ci/create_pipeline_service.rb
+++ b/app/services/ci/create_pipeline_service.rb
@@ -2,8 +2,9 @@ module Ci
class CreatePipelineService < BaseService
attr_reader :pipeline
- def execute(ignore_skip_ci: false, save_on_errors: true, trigger_request: nil, schedule: nil)
+ def execute(source, ignore_skip_ci: false, save_on_errors: true, trigger_request: nil, schedule: nil)
@pipeline = Ci::Pipeline.new(
+ source: source,
project: project,
ref: ref,
sha: sha,
diff --git a/app/services/ci/create_trigger_request_service.rb b/app/services/ci/create_trigger_request_service.rb
index 8362f01ddb8..beb27a5a597 100644
--- a/app/services/ci/create_trigger_request_service.rb
+++ b/app/services/ci/create_trigger_request_service.rb
@@ -4,7 +4,7 @@ module Ci
trigger_request = trigger.trigger_requests.create(variables: variables)
pipeline = Ci::CreatePipelineService.new(project, trigger.owner, ref: ref).
- execute(ignore_skip_ci: true, trigger_request: trigger_request)
+ execute(:trigger, ignore_skip_ci: true, trigger_request: trigger_request)
trigger_request if pipeline.persisted?
end