cfoundry 0.3.37 → 0.3.38
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/cfoundry/baseclient.rb +13 -8
- data/lib/cfoundry/v2/app.rb +1 -4
- data/lib/cfoundry/v2/model.rb +3 -1
- data/lib/cfoundry/version.rb +1 -1
- metadata +3 -3
data/lib/cfoundry/baseclient.rb
CHANGED
@@ -199,17 +199,10 @@ module CFoundry
|
|
199
199
|
|
200
200
|
data = log_data(time, request, response)
|
201
201
|
|
202
|
-
if @log.is_a?(Array)
|
203
|
-
@log << data
|
204
|
-
return
|
205
|
-
end
|
206
|
-
|
207
202
|
case @log
|
208
|
-
when Array
|
209
|
-
@log << data
|
210
|
-
return
|
211
203
|
when IO
|
212
204
|
log_line(@log, data)
|
205
|
+
return
|
213
206
|
when String
|
214
207
|
if File.exists?(@log)
|
215
208
|
log = File.readlines(@log).last(LOG_LENGTH - 1)
|
@@ -221,6 +214,18 @@ module CFoundry
|
|
221
214
|
log.each { |l| io.print l } if log
|
222
215
|
log_line(io, data)
|
223
216
|
end
|
217
|
+
|
218
|
+
return
|
219
|
+
end
|
220
|
+
|
221
|
+
if @log.respond_to?(:call)
|
222
|
+
@log.call(data)
|
223
|
+
return
|
224
|
+
end
|
225
|
+
|
226
|
+
if @log.respond_to?(:<<)
|
227
|
+
@log << data
|
228
|
+
return
|
224
229
|
end
|
225
230
|
end
|
226
231
|
|
data/lib/cfoundry/v2/app.rb
CHANGED
@@ -29,6 +29,7 @@ module CFoundry::V2
|
|
29
29
|
attribute :disk_quota, :integer, :default => 256
|
30
30
|
attribute :state, :integer, :default => "STOPPED"
|
31
31
|
attribute :command, :string, :default => nil
|
32
|
+
attribute :console, :boolean, :default => false
|
32
33
|
to_many :service_bindings
|
33
34
|
to_many :routes
|
34
35
|
|
@@ -69,10 +70,6 @@ module CFoundry::V2
|
|
69
70
|
nil
|
70
71
|
end
|
71
72
|
|
72
|
-
def console # TODO v2
|
73
|
-
nil
|
74
|
-
end
|
75
|
-
|
76
73
|
def uris
|
77
74
|
routes.collect do |r|
|
78
75
|
"#{r.host}.#{r.domain.name}"
|
data/lib/cfoundry/v2/model.rb
CHANGED
data/lib/cfoundry/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cfoundry
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 95
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 38
|
10
|
+
version: 0.3.38
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Alex Suraci
|