vmfloaty/lib/vmfloaty/auth.rb
Brian Cain 296f9abb1d (#1) Update vmfloaty to use new vmpooler api
This commit also uses commander for arg parsing.

This commit is a WIP.
2015-09-05 16:17:45 -07:00

20 lines
434 B
Ruby

require 'faraday'
require 'vmfloaty/http'
class Auth
def self.get_token(user, url, password)
conn = Http.get_conn(url)
#resp = conn.post do |req|
# req.url '/v1/token'
# req.headers['Content-Type'] = 'application/json'
# req.user = user
# end
# if ok: true, return token
puts 'Got token'
end
def self.delete_token(user, token)
conn = Http.get_conn(url)
end
end