task-orchestrator 0.0.20 → 0.0.23
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/orchestrator/task.rb +4 -1
- data/lib/orchestrator/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aa2d86a3d79e41343eaafc3276a643ffa04ac220
|
4
|
+
data.tar.gz: d5d5bc22f028565c668df489b4697d7c0a535cd7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ac7183fc0991284c588691b139b68dc5f9e7a6a176316ce512791eb9357155a63201b2899415a01b7072cd5cffe41da00c0966a8e1af7e953f643dcb6cf7c7a
|
7
|
+
data.tar.gz: 25bb9862d674a14eb7b0219846c93317207d2eada25cf823b682c35cd1c4abbd3de04c9012d0758a49db45975a33995c19e2b231c12972cd8a55d5dfe6b2216e
|
data/lib/orchestrator/task.rb
CHANGED
@@ -135,6 +135,7 @@ module Orchestrator
|
|
135
135
|
end
|
136
136
|
|
137
137
|
def interpolate_command(command,pattern=/^(ENV|ARG|EXEC)\./)
|
138
|
+
command = command.to_s if command.is_a?(Integer)
|
138
139
|
command.gsub(/:::([^:]*):::/) do
|
139
140
|
match = $1
|
140
141
|
invalid("interpolation type is not valid in this context - :::#{match}:::") if match !~ pattern and match =~ /^(ENV|ARG|EXEC)\./
|
@@ -204,7 +205,9 @@ module Orchestrator
|
|
204
205
|
invalid("default envs must be hash") unless @state['defaults'][type.to_s].is_a?(Hash)
|
205
206
|
@state['defaults'][type.to_s].each do|key,value|
|
206
207
|
value = '' unless value
|
207
|
-
|
208
|
+
if not value.is_a?(String) and not value.is_a?(Integer)
|
209
|
+
invalid("default value for #{type} #{key} is invalid")
|
210
|
+
end
|
208
211
|
@defaults[type].instance_variable_set("@#{key}",interpolate_command(value,/^EXEC\./))
|
209
212
|
end
|
210
213
|
end
|
data/lib/orchestrator/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: task-orchestrator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.23
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Piavlo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-07-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pony
|