onena 0.1.1 → 0.1.2
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/ChangeLog.md +4 -0
- data/README.md +4 -0
- data/lib/onena/client.rb +3 -2
- data/lib/onena/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8a51ae6d676719536c0813eb6fa21be73f5bacb0
|
|
4
|
+
data.tar.gz: e77647ac1b57179349779a30983fc82602ca2318
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 987a92b06e9c4f115c34809e6ebfc16521992a217d97a2303fed46731322c5d68e9beed6dc1bf7350f06355ad1a17f81b002e3513407d7c4ccdea5c796a0cb48
|
|
7
|
+
data.tar.gz: 0ab4a48448b7a3c19ae78b59221be5f50435687e8e24926e780592dbc327732b69f797aef29a6e9d5a60aa96ae7ba87760b7ef51fcb43452ba2a37aefcefa824
|
data/ChangeLog.md
CHANGED
data/README.md
CHANGED
|
@@ -26,6 +26,10 @@ API Key as `FLOAT_API_KEY`, or pass the keys as arguments. You may also set
|
|
|
26
26
|
`TOCK_API_ENDPOINT` to override the default endpoint,
|
|
27
27
|
`https://tock.18f.gov/api/`.
|
|
28
28
|
|
|
29
|
+
Note that the cookie generated by `oauth2_proxy` is used as the API key for
|
|
30
|
+
Tock, and that no API key is required when accessing the [vagrant development
|
|
31
|
+
instance](https://github.com/18F/tock#getting-started).
|
|
32
|
+
|
|
29
33
|
```shell
|
|
30
34
|
$ export TOCK_API_ENDPOINT=http://192.168.33.10/api
|
|
31
35
|
$ export TOCK_API_KEY=...
|
data/lib/onena/client.rb
CHANGED
|
@@ -107,8 +107,9 @@ module Onena
|
|
|
107
107
|
|
|
108
108
|
def tock_request(url)
|
|
109
109
|
Curl.get(url) do |http|
|
|
110
|
-
#
|
|
111
|
-
#
|
|
110
|
+
# Authentication is done against production endpoint,
|
|
111
|
+
# https://tock.18f.gov/api/, by copying the cookie generated by
|
|
112
|
+
# oauth2_proxy
|
|
112
113
|
http.headers['Cookie'] = '_oauth2_proxy=' + @tock_api_key unless @tock_api_key.nil?
|
|
113
114
|
end
|
|
114
115
|
end
|
data/lib/onena/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: onena
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Christian G. Warden
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-02-
|
|
11
|
+
date: 2016-02-29 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: codeclimate-test-reporter
|
|
@@ -202,7 +202,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
202
202
|
version: '0'
|
|
203
203
|
requirements: []
|
|
204
204
|
rubyforge_project:
|
|
205
|
-
rubygems_version: 2.
|
|
205
|
+
rubygems_version: 2.2.2
|
|
206
206
|
signing_key:
|
|
207
207
|
specification_version: 4
|
|
208
208
|
summary: Identify possible duplicates between Tock and Float
|