Class: Colombo::SshKey
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#ssh_pub_key ⇒ Object
Returns the value of attribute ssh_pub_key.
Instance Method Summary collapse
Methods inherited from Resource
Constructor Details
This class inherits a constructor from Colombo::Resource
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
6 7 8 |
# File 'lib/colombo/ssh_key.rb', line 6 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/colombo/ssh_key.rb', line 6 def name @name end |
#ssh_pub_key ⇒ Object
Returns the value of attribute ssh_pub_key.
6 7 8 |
# File 'lib/colombo/ssh_key.rb', line 6 def ssh_pub_key @ssh_pub_key end |
Instance Method Details
#destroy ⇒ Object
8 9 10 11 12 13 |
# File 'lib/colombo/ssh_key.rb', line 8 def destroy @client.request(:get, "/ssh_keys/#{self.id}/destroy/") do |response| return true end return false end |
#update(options = {}) ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/colombo/ssh_key.rb', line 24 def update(={}) params = { :ssh_pub_key => [:ssh_pub_key] } response = @client.request(:get, "/ssh_keys/#{self.id}/edit/", params) do |response| return true end return false end |