summaryrefslogtreecommitdiff
path: root/lib/ci
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2016-09-07 16:14:37 +0000
committerRémy Coutable <remy@rymai.me>2016-09-07 16:14:37 +0000
commit4ce348c7f927205d084f0afd5221125505d8045f (patch)
tree926956827f7bdb21cd46249f4a8a9cc040d2b406 /lib/ci
parentfb82d25df8f1ba4e0cfdfbc52cb1cc20725f9f0c (diff)
parent2436631dea9264045d8694705a95d90c30b4057d (diff)
downloadgitlab-ce-4ce348c7f927205d084f0afd5221125505d8045f.tar.gz
Merge branch 'refactor/ci-config-add-logical-validation' into 'master'
Pass dependencies to CI configuration nodes ## What does this MR do? This MR makes it possible to pass dependencies to CI configuration nodes. ## What are the relevant issue numbers? See #15060 ## Does this MR meet the acceptance criteria? - Tests - [x] Added for this feature/bug - [x] All builds are passing See merge request !6009
Diffstat (limited to 'lib/ci')
-rw-r--r--lib/ci/gitlab_ci_yaml_processor.rb15
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/ci/gitlab_ci_yaml_processor.rb b/lib/ci/gitlab_ci_yaml_processor.rb
index e8c86349339..caa815f720f 100644
--- a/lib/ci/gitlab_ci_yaml_processor.rb
+++ b/lib/ci/gitlab_ci_yaml_processor.rb
@@ -55,12 +55,7 @@ module Ci
{
stage_idx: @stages.index(job[:stage]),
stage: job[:stage],
- ##
- # Refactoring note:
- # - before script behaves differently than after script
- # - after script returns an array of commands
- # - before script should be a concatenated command
- commands: [job[:before_script] || @before_script, job[:script]].flatten.compact.join("\n"),
+ commands: job[:commands],
tag_list: job[:tags] || [],
name: job[:name].to_s,
allow_failure: job[:allow_failure] || false,
@@ -68,12 +63,12 @@ module Ci
environment: job[:environment],
yaml_variables: yaml_variables(name),
options: {
- image: job[:image] || @image,
- services: job[:services] || @services,
+ image: job[:image],
+ services: job[:services],
artifacts: job[:artifacts],
- cache: job[:cache] || @cache,
+ cache: job[:cache],
dependencies: job[:dependencies],
- after_script: job[:after_script] || @after_script,
+ after_script: job[:after_script],
}.compact
}
end