clonk 2.2.0 → 2.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/clonk.rb +0 -14
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4fe9ab2c1013cc5cc0f98d366a026a8f2d119799993989b9716cb68e71e6e230
4
- data.tar.gz: 9b24bbd75517bf041c2ff1d6caa26ffc627729d7908d51a34dc949dfc5cd4806
3
+ metadata.gz: 625c5440be7ee9819f305cf8a5ba0acdfe78904b9427e3ec8b855150a1538830
4
+ data.tar.gz: 063d62e67116ebb5662bf12466a97a0096375b88c94b42eda488298c43dbd99e
5
5
  SHA512:
6
- metadata.gz: 70a3ad427d92b3c95b0fdf4e7d42fabd2f1f7cd8ba962e0e966846dc3adeca1edad7d502d8102744c34d494bd01f6e77c0411643035ef2b5931f77196d2a208d
7
- data.tar.gz: 5cccc2ffe10808c12b64f39af8991fa5cfae47a6eb38a054eeaf84347c4ac8baa70ff57529d361f2839cd7b95866a22ea80d3be6b7ed428ec2b929fa0e63bad0
6
+ metadata.gz: 191c6d065c35b1ad9b4c7c8dba6b7099f61011950748bf920305f5b94e80c72314398393bafa73baf2a6c55d1c4490826b04914ae2e6c83b62c04091356b511a
7
+ data.tar.gz: 22ad4a41f77a146e1b4ad0fb26bdd3e3368d3f91c25da961fd6762502395029932e72f438e4d24ddc17e1f16f77a32dd1ed68cf2abf83e0d19cddda35a3b772a
data/lib/clonk.rb CHANGED
@@ -4,23 +4,9 @@ require 'faraday'
4
4
  require 'faraday_middleware'
5
5
  require 'json'
6
6
 
7
- BASE_URL = CGI.escape(ENV.fetch('SSO_BASE_URL'))
8
-
9
7
  # Keycloak/Red Hat SSO API wrapper
10
8
  module Clonk
11
9
  class << self
12
- ##
13
- # Defines a Faraday::Connection object linked to the SSO instance.
14
-
15
- def connection(token: nil, raise_error: true, json: true)
16
- Faraday.new(url: BASE_URL) do |faraday|
17
- faraday.request(json ? :json : :url_encoded)
18
- faraday.use Faraday::Response::RaiseError if raise_error
19
- faraday.adapter Faraday.default_adapter
20
- faraday.headers['Authorization'] = "Bearer #{token}" if token
21
- end
22
- end
23
-
24
10
  def logout_url(base_url:, realm_id:, redirect_uri:)
25
11
  "#{base_url}/auth/realms/#{realm_id}/protocol/openid-connect/logout?redirect_uri=#{CGI.escape(redirect_uri)}"
26
12
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: clonk
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.0
4
+ version: 2.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Simon Fish
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-12-17 00:00:00.000000000 Z
11
+ date: 2019-01-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday