Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/ci/build/rules.rb')
-rw-r--r--lib/gitlab/ci/build/rules.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/gitlab/ci/build/rules.rb b/lib/gitlab/ci/build/rules.rb
index 8b503290e6e..999f41ff46f 100644
--- a/lib/gitlab/ci/build/rules.rb
+++ b/lib/gitlab/ci/build/rules.rb
@@ -6,7 +6,9 @@ module Gitlab
class Rules
include ::Gitlab::Utils::StrongMemoize
- Result = Struct.new(:when, :start_in, :allow_failure, :variables, :needs, :errors, keyword_init: true) do
+ Result = Struct.new(
+ :when, :start_in, :allow_failure, :variables, :needs, :errors, :auto_cancel, keyword_init: true
+ ) do
def build_attributes
needs_job = needs&.dig(:job)
{
@@ -37,7 +39,8 @@ module Gitlab
start_in: matched_rule.attributes[:start_in],
allow_failure: matched_rule.attributes[:allow_failure],
variables: matched_rule.attributes[:variables],
- needs: matched_rule.attributes[:needs]
+ needs: matched_rule.attributes[:needs],
+ auto_cancel: matched_rule.attributes[:auto_cancel]
)
else
Result.new(when: 'never')