diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2018-03-21 09:53:26 +0100 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2018-03-21 09:53:26 +0100 |
commit | ad61a1815400e8c9fce1758618379874d93868e6 (patch) | |
tree | 03edb021d49920207bd8f8e9bcf5a8459d9cbd65 /lib/gitlab/ci/pipeline/seed/build.rb | |
parent | ab0cd2a8bf54209e5e1b9594752d5158d3cf5faa (diff) | |
download | gitlab-ce-ad61a1815400e8c9fce1758618379874d93868e6.tar.gz |
Support building all pipeline resource before saving
Diffstat (limited to 'lib/gitlab/ci/pipeline/seed/build.rb')
-rw-r--r-- | lib/gitlab/ci/pipeline/seed/build.rb | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/lib/gitlab/ci/pipeline/seed/build.rb b/lib/gitlab/ci/pipeline/seed/build.rb index f5dbb3a1c40..f49dbb2f0ba 100644 --- a/lib/gitlab/ci/pipeline/seed/build.rb +++ b/lib/gitlab/ci/pipeline/seed/build.rb @@ -15,11 +15,18 @@ module Gitlab end def attributes - @attributes.merge(project: @pipeline.project, - ref: @pipeline.ref, - tag: @pipeline.tag, - trigger_request: @pipeline.legacy_trigger, - protected: @pipeline.protected_ref?) + @attributes.merge( + pipeline: @pipeline, + project: @pipeline.project, + ref: @pipeline.ref, + tag: @pipeline.tag, + trigger_request: @pipeline.legacy_trigger, + protected: @pipeline.protected_ref? + ) + end + + def to_resource + ::Ci::Build.new(attributes) end end end |