class Fog::Hetznercloud::Compute::SshKeys

Public Instance Methods

all(filters = {}) click to toggle source
# File lib/fog/hetznercloud/models/compute/ssh_keys.rb, line 7
def all(filters = {})
  ssh_keys = service.list_ssh_keys(filters).body['ssh_keys'] || []
  load(ssh_keys)
end
get(identity) click to toggle source
# File lib/fog/hetznercloud/models/compute/ssh_keys.rb, line 12
def get(identity)
  if (ssh_key = service.get_ssh_key(identity).body['ssh_key'])
    new(ssh_key)
  end
rescue Fog::Hetznercloud::Compute::UnknownResourceError
  nil
end