marathon-template 0.0.4 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/marathon-template/deploy.rb +7 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b21896fde507b47f8f44d96dd5b1441df94a8f51
|
4
|
+
data.tar.gz: 848374a49709d44dc9ec88f541b2d3ae79b7a415
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22350c213b1f8b52c74eff1f8d49506ff7cce88b1198f5247a4d08e9e6fcce5d3b1019649341621b2edad2139c65cc92608d77bac524525a943c7c507c261ca0
|
7
|
+
data.tar.gz: 13f6a7dd95e52f13cb5e5a4111f7e85cb1e4706801caea275105d945095bbc7863ac46981cf10b08ae83e3041b64e7ad4acfb97c3f2dce1da52ff5f0f2320bce
|
@@ -108,7 +108,7 @@ module Marathon_template
|
|
108
108
|
servers = get_servers(app_name)
|
109
109
|
LOG.info "#{app_name}: #{servers}"
|
110
110
|
servers.each do |host, port|
|
111
|
-
f.write "\tserver #{app_name} #{host}:#{port.first} #{options}\n"
|
111
|
+
f.write "\tserver #{app_name} #{host.split('_').first}:#{port.first} #{options}\n"
|
112
112
|
end
|
113
113
|
elsif values.kind_of?(Array)
|
114
114
|
values.each do |value|
|
@@ -141,7 +141,12 @@ module Marathon_template
|
|
141
141
|
json = JSON.parse(response.body)
|
142
142
|
tasks = json['app']['tasks']
|
143
143
|
tasks.each_with_index do |task, i|
|
144
|
-
|
144
|
+
LOG.info "Found host #{task['host']} and port #{task['ports']}"
|
145
|
+
return_hash["#{task['host']}_#{i}"] = task['ports']
|
146
|
+
# if task['ports'].length == 1
|
147
|
+
#+ LOG.info "Found host #{task['host']} and port #{task['ports']}"
|
148
|
+
# return_hash[i] = { task['host'] => task['port'] }
|
149
|
+
# return_array << "#{task['host']}:#{task['ports'][1]}"
|
145
150
|
end
|
146
151
|
else
|
147
152
|
if response.code == '404'
|