2018-12-13 13:39:08 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-03-17 18:26:18 +05:30
|
|
|
module Gitlab
|
|
|
|
module Ci
|
|
|
|
module Pipeline
|
|
|
|
module Chain
|
|
|
|
class Build < Chain::Base
|
|
|
|
def perform!
|
|
|
|
@pipeline.assign_attributes(
|
|
|
|
source: @command.source,
|
|
|
|
project: @command.project,
|
|
|
|
ref: @command.ref,
|
|
|
|
sha: @command.sha,
|
|
|
|
before_sha: @command.before_sha,
|
2019-07-07 11:18:12 +05:30
|
|
|
source_sha: @command.source_sha,
|
|
|
|
target_sha: @command.target_sha,
|
2018-03-17 18:26:18 +05:30
|
|
|
tag: @command.tag_exists?,
|
|
|
|
trigger_requests: Array(@command.trigger_request),
|
|
|
|
user: @command.current_user,
|
|
|
|
pipeline_schedule: @command.schedule,
|
2019-02-15 15:39:39 +05:30
|
|
|
merge_request: @command.merge_request,
|
2018-10-15 14:42:47 +05:30
|
|
|
variables_attributes: Array(@command.variables_attributes)
|
2018-03-17 18:26:18 +05:30
|
|
|
)
|
|
|
|
|
|
|
|
@pipeline.set_config_source
|
|
|
|
end
|
|
|
|
|
|
|
|
def break?
|
|
|
|
false
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|