Class: K8y::REST::Auth::Basic

Inherits:
AuthBase
  • Object
show all
Defined in:
lib/k8y/rest/auth/basic.rb

Instance Method Summary collapse

Constructor Details

#initialize(username:, password:) ⇒ Basic

Returns a new instance of Basic.



9
10
11
12
13
# File 'lib/k8y/rest/auth/basic.rb', line 9

def initialize(username:, password:)
  super()
  @username = username
  @password = password
end

Instance Method Details

#configure_connection(connection) ⇒ Object



15
16
17
# File 'lib/k8y/rest/auth/basic.rb', line 15

def configure_connection(connection)
  connection.request(:authorization, :basic, username, password)
end