cfoundry 0.3.18 → 0.3.19
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.
- data/lib/cfoundry/uaaclient.rb +1 -3
- data/lib/cfoundry/v1/app.rb +7 -3
- data/lib/cfoundry/version.rb +1 -1
- metadata +4 -4
data/lib/cfoundry/uaaclient.rb
CHANGED
@@ -2,14 +2,13 @@ require "cfoundry/baseclient"
|
|
2
2
|
|
3
3
|
module CFoundry
|
4
4
|
class UAAClient < BaseClient
|
5
|
-
attr_accessor :target, :client_id, :
|
5
|
+
attr_accessor :target, :client_id, :redirect_uri, :token, :trace
|
6
6
|
|
7
7
|
def initialize(
|
8
8
|
target = "https://uaa.cloudfoundry.com",
|
9
9
|
client_id = "vmc")
|
10
10
|
@target = target
|
11
11
|
@client_id = client_id
|
12
|
-
@scope = ["read"]
|
13
12
|
@redirect_uri = "http://uaa.cloudfoundry.com/redirect/vmc"
|
14
13
|
end
|
15
14
|
|
@@ -20,7 +19,6 @@ module CFoundry
|
|
20
19
|
def authorize(credentials)
|
21
20
|
query = {
|
22
21
|
:client_id => @client_id,
|
23
|
-
:scope => Array(@scope).join(" "),
|
24
22
|
:response_type => "token",
|
25
23
|
:redirect_uri => @redirect_uri
|
26
24
|
}
|
data/lib/cfoundry/v1/app.rb
CHANGED
@@ -268,7 +268,11 @@ module CFoundry::V1
|
|
268
268
|
end
|
269
269
|
|
270
270
|
def env=(hash)
|
271
|
-
|
271
|
+
unless hash.is_a?(Array)
|
272
|
+
hash = hash.collect { |k, v| "#{k}=#{v}" }
|
273
|
+
end
|
274
|
+
|
275
|
+
self.env_array = hash
|
272
276
|
end
|
273
277
|
|
274
278
|
def services
|
@@ -402,9 +406,9 @@ module CFoundry::V1
|
|
402
406
|
def put(what, where, path)
|
403
407
|
if path.size == 1
|
404
408
|
where[path.last] = what
|
405
|
-
elsif name = path.
|
409
|
+
elsif name = path.first
|
406
410
|
where[name] ||= {}
|
407
|
-
put(what, where[name], path)
|
411
|
+
put(what, where[name], path[1..-1])
|
408
412
|
end
|
409
413
|
|
410
414
|
nil
|
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: 53
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 19
|
10
|
+
version: 0.3.19
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Alex Suraci
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2012-
|
18
|
+
date: 2012-08-06 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: rest-client
|