Module: Vault
- Extended by:
- Configurable
- Defined in:
- lib/vault.rb,
lib/vault/api.rb,
lib/vault/client.rb,
lib/vault/errors.rb,
lib/vault/api/sys.rb,
lib/vault/request.rb,
lib/vault/version.rb,
lib/vault/api/help.rb,
lib/vault/defaults.rb,
lib/vault/response.rb,
lib/vault/api/secret.rb,
lib/vault/api/logical.rb,
lib/vault/api/sys/auth.rb,
lib/vault/api/sys/init.rb,
lib/vault/api/sys/seal.rb,
lib/vault/configurable.rb,
lib/vault/api/sys/audit.rb,
lib/vault/api/sys/lease.rb,
lib/vault/api/sys/mount.rb,
lib/vault/api/auth_token.rb,
lib/vault/api/sys/leader.rb,
lib/vault/api/sys/policy.rb
Defined Under Namespace
Modules: API, Configurable, Defaults, Response Classes: Audit, Auth, AuthToken, Client, HTTPConnectionError, HTTPError, Help, InitResponse, InitStatus, LeaderStatus, Logical, MissingTokenError, Mount, Policy, Request, SealStatus, Secret, SecretAuth, Sys, VaultError
Constant Summary collapse
- VERSION =
"0.1.2"
Class Method Summary collapse
-
.client ⇒ Vault::Client
API client object based off the configured options in Configurable.
-
.method_missing(m, *args, &block) ⇒ Object
Delegate all methods to the client object, essentially making the module object behave like a Client.
-
.respond_to_missing?(m, include_private = false) ⇒ Boolean
Delegating
respond_toto the Client.
Methods included from Configurable
configure, keys, options, reset!
Class Method Details
.client ⇒ Vault::Client
API client object based off the configured options in Configurable.
16 17 18 19 20 21 |
# File 'lib/vault.rb', line 16 def self.client if !defined?(@client) || !@client.() @client = Vault::Client.new() end @client end |
.method_missing(m, *args, &block) ⇒ Object
Delegate all methods to the client object, essentially making the module object behave like a Client.
25 26 27 28 29 30 31 |
# File 'lib/vault.rb', line 25 def self.method_missing(m, *args, &block) if client.respond_to?(m) client.send(m, *args, &block) else super end end |
.respond_to_missing?(m, include_private = false) ⇒ Boolean
Delegating respond_to to the Client.
34 35 36 |
# File 'lib/vault.rb', line 34 def self.respond_to_missing?(m, include_private = false) client.respond_to?(m) || super end |