Class: ProxyAPI::Pulp

Inherits:
Resource
  • Object
show all
Defined in:
lib/proxy_api/pulp.rb

Instance Method Summary collapse

Constructor Details

#initialize(args) ⇒ Pulp

Returns a new instance of Pulp.



3
4
5
6
# File 'lib/proxy_api/pulp.rb', line 3

def initialize(args)
  @url = args[:url] + "/pulp/status"
  super args
end

Instance Method Details

#capsule_puppet_pathObject



15
16
17
18
19
20
# File 'lib/proxy_api/pulp.rb', line 15

def capsule_puppet_path
  @url += "/puppet"
  @capsule_puppet_path ||= parse(get)
rescue => e
  raise ::ProxyAPI::ProxyException.new(url, e, N_("Unable to detect puppet path"))
end

#pulp_storageObject



8
9
10
11
12
13
# File 'lib/proxy_api/pulp.rb', line 8

def pulp_storage
  @url += "/disk_usage"
  @pulp_storage ||= parse(get)
rescue => e
  raise ::ProxyAPI::ProxyException.new(url, e, N_("Unable to detect pulp storage"))
end