diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-18 11:18:50 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-18 11:18:50 +0000 |
commit | 8c7f4e9d5f36cff46365a7f8c4b9c21578c1e781 (patch) | |
tree | a77e7fe7a93de11213032ed4ab1f33a3db51b738 /lib/gitlab/ci/build/step.rb | |
parent | 00b35af3db1abfe813a778f643dad221aad51fca (diff) | |
download | gitlab-ce-8c7f4e9d5f36cff46365a7f8c4b9c21578c1e781.tar.gz |
Add latest changes from gitlab-org/gitlab@13-1-stable-ee
Diffstat (limited to 'lib/gitlab/ci/build/step.rb')
-rw-r--r-- | lib/gitlab/ci/build/step.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/gitlab/ci/build/step.rb b/lib/gitlab/ci/build/step.rb index 48111ae5717..f8550b50905 100644 --- a/lib/gitlab/ci/build/step.rb +++ b/lib/gitlab/ci/build/step.rb @@ -20,6 +20,19 @@ module Gitlab end end + def from_release(job) + return unless Gitlab::Ci::Features.release_generation_enabled? + + release = job.options[:release] + return unless release + + self.new(:release).tap do |step| + step.script = Gitlab::Ci::Build::Releaser.new(config: job.options[:release]).script + step.timeout = job.metadata_timeout + step.when = WHEN_ON_SUCCESS + end + end + def from_after_script(job) after_script = job.options[:after_script] return unless after_script |